Deploy one script to Mulitiple Databases

427 views
Skip to first unread message

Dale Janssen

unread,
Jun 26, 2014, 5:06:27 PM6/26/14
to dbup-d...@googlegroups.com
I have been working with DbUp and can see how to deploy a Database update/script to a single Database. But I have a situation where I need to deploy the same script to a dozen or more identical Databases - all named uniquely, some on the same server, some on others, but all accessible via a connection string.

Can you suggest the best way to accomplish this? 

I could put together a web.config transform with a custom .target file, so it is easy to see how to create multiple customized app.configs with different connection strings and then have the console program loop through all app.config files found - but that sure seems like the long way around.

Any other suggestions?

Stephen Krauklis

unread,
Jul 15, 2014, 12:40:19 AM7/15/14
to dbup-d...@googlegroups.com
Dale,

Check out Octopus Deploy. There is an article on the concept here: http://octopusdeploy.com/blog/howto/deploy-a-sql-database

We use this tool with DbUp to deploy database changes to numerous 'environments'.

Stephen

Peter Karaganis

unread,
Jul 15, 2014, 5:28:46 AM7/15/14
to dbup-d...@googlegroups.com
Agreed we use octopus deploy with great success.  If you didn't want to do that you could just create a powershell script to wrap your console app and use a hashtable of your connection strings to loop through them passing each connection string to your dbup app as a command line argument. 
--
You received this message because you are subscribed to the Google Groups "DbUp Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dbup-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
Sent from my iPhone 5. Please excuse spelling errors and brevity.

Eduardo Molteni

unread,
Jul 15, 2014, 9:46:02 AM7/15/14
to dbup-d...@googlegroups.com
Or you could update the DBs as being used (check the DB per request, with caching for performance)

Gregory Murray

unread,
Nov 15, 2016, 12:27:29 PM11/15/16
to DbUp Discuss
On a related note, if I'm deploying to multiple databases in parallel, is DbUp thread safe?  I'm deploying to multiple databases (same schema) on a single server and due to the number of databases, I need to deploy in parallel.  I want to call DpUp as a DLL within one EXE rather than spawning separate executables.
 
Thanks,
Gregory

Anks

unread,
Apr 6, 2020, 12:25:47 PM4/6/20
to DbUp Discuss
Hey Gregory,

Are you able to do this i also have the same requirement. Could you please suggest on this.

thanks,
Sonia

Anks

unread,
Apr 6, 2020, 12:29:54 PM4/6/20
to DbUp Discuss
Hey Peter ,

Here in your below post console app is   DBUp console you were talking about ?
Can you please share your thoughts as i have a situation where i want to run DBup for multiple Db's so i have written as ps script .

Regards,
Sonia 


On Tuesday, July 15, 2014 at 2:58:46 PM UTC+5:30, Peter Karaganis wrote:
Agreed we use octopus deploy with great success.  If you didn't want to do that you could just create a powershell script to wrap your console app and use a hashtable of your connection strings to loop through them passing each connection string to your dbup app as a command line argument. 

On Monday, July 14, 2014, Stephen Krauklis <stephen...@gmail.com> wrote:
Dale,

Check out Octopus Deploy. There is an article on the concept here: http://octopusdeploy.com/blog/howto/deploy-a-sql-database

We use this tool with DbUp to deploy database changes to numerous 'environments'.

Stephen

On Friday, June 27, 2014 7:06:27 AM UTC+10, Dale Janssen wrote:
I have been working with DbUp and can see how to deploy a Database update/script to a single Database. But I have a situation where I need to deploy the same script to a dozen or more identical Databases - all named uniquely, some on the same server, some on others, but all accessible via a connection string.

Can you suggest the best way to accomplish this? 

I could put together a web.config transform with a custom .target file, so it is easy to see how to create multiple customized app.configs with different connection strings and then have the console program loop through all app.config files found - but that sure seems like the long way around.

Any other suggestions?

--
You received this message because you are subscribed to the Google Groups "DbUp Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dbup-discuss+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages