Deployment Error

ilouw's Avatar

ilouw

13 Feb, 2018 04:18 AM

Hi,
I am trying to deploy a redgate Database package to a tentacle.
I am currently getting the error below. I did find a simular post but the post fails to specify how the error was correct or where.
https://help.octopusdeploy.com/discussions/problems/34716-use-of-red-gate-database-deployment
Has anyone else had a simular error?
Any ideas or help will be welcome.
Thank you,
Ivan

Parsing connection string: TESTSERVER\DBDEPLOY
New-Object : Exception calling ".ctor" with "1" argument(s): "Format of the
initialization string does not conform to specification starting at index 0."
At C:\Octopus\Applications\Development\BreakThrough\1.0.1302_2\Octopus.Features
.RedGateDatabase_BeforePostDeploy.ps1:48 char:13
+ $conn = New-Object System.Data.SqlClient.SqlConnectionStringBuilder
$connect ...
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidOperation: (:) [New-Object], MethodInvoca
   tionException
    + FullyQualifiedErrorId : ConstructorInvokedThrowException,Microsoft.Power
   Shell.Commands.NewObjectCommand
Script 'C:\Octopus\Applications\Development\BreakThrough\1.0.1302_2\Octopus.Features.RedGateDatabase_BeforePostDeploy.ps1' returned non-zero exit code: 1
Running rollback conventions...
Script 'C:\Octopus\Applications\Development\BreakThrough\1.0.1302_2\Octopus.Features.RedGateDatabase_BeforePostDeploy.ps1' returned non-zero exit code: 1
The remote script failed with exit code 1
The action Deploy DB Package on DB Deploy failed

  1. Support Staff 1 Posted by Robert Wagner on 14 Feb, 2018 05:58 AM

    Robert Wagner's Avatar

    Hi Ivan,

    Thanks for getting in touch. I suspect the problem is that the connection string given is not a valid connection string. It looks like a server and instance name (TESTSERVER\DBDEPLOY) is being used and the failure is on SqlConnectionStringBuilder.

    The value should be a full connection string, eg Server=myServerAddress;Database=myDataBase;User Id=myUsername; Password=myPassword;. Also see this page for more examples.

    If you are still stuck, could you please send me a screenshot of the step configuration along with the version of Octopus you are using and the Step Name (and whether it is from the library or built in)

    Regards

    Robert W

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac