VSTS Build + Azure Database

meischjmeischj Posts: 3 New member

I'm trying to make a CI/CD pipeline for my database on VSTS and deploy it on an Azure SQL Server. But I'm stuck at the build process.
Here are the tasks I use :
  • Setup a Shadow DB
  • Build solution
  • Copy Publish Artifact

Here are the variables used :


But at the second task (Build solution), I have an issue to connect to the Azure Database :
packages\ReadyRoll.MSBuild.\tools\ReadyRoll.Data.Schema.SSDT.targets(145,5): Error : An error occurred while attempting to verify your deployment scripts: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

The login/password are correct, I checked multiple times.
I tried the Hosted agent as well as a private agent (on my own machine) but I have the same error.

Can you help me with that ?

Thank you,


  • AdamBAdamB Posts: 22 Bronze 4
    edited July 19, 2017 1:40PM
    Hi Jeremy,

    As the connection error is occurring during "attempting to verify your deployment scripts" it looks like the connection is failing to connect to the shadow database rather than the target - consequently, the issue shouldn't be the login/password for Azure as for the shadow database we use the variables ShadowUserName and ShadowPassword, which you haven't set, so it'll use Windows Authentication, which should work as localdb supports Windows Authentication by default.

    Can you please check the build output for the "Setup Shadow DB" task and confirm the SqlLocalDB.exe path is correct and the instance is being created with the name you expected?

    If this doesn't help then please send a copy of the entire build log to [email protected] and we'll take a look.
    Adam Bowden,
    Software Engineer, RedGate Software
  • meischj ,

    I'm curious if you can try something. Can you make a database, on a local instance, and make that your target? I tried this and it worked for me. I am getting a named pipes error with Azure as the target and the shadow as localdb. I'll try to get time to check Azure with a real local instance since I suspect networking issues here.
Sign In or Register to comment.