From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Morris, Jason
Sent: Thursday, January 08, 2004 7:07 PM
To: [EMAIL PROTECTED]
Subject: RE: [Nant-users] Newbie question on using nant to push to production
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Landes Eric (RBNA/CIT4.2)
Sent: Thursday, January 08, 2004 10:49 AM
To: [EMAIL PROTECTED]
Subject: RE: [Nant-users] Newbie question on using nant to push to production
-----Original Message-----
From: Morris, Jason [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 08, 2004 12:23 PM
To: [EMAIL PROTECTED]
Subject: RE: [Nant-users] Newbie question on using nant to push to productionThis is exactly what my group does to push several ASP.NET (C# code behinds) web application between four different environments, dev, integration, pre-production, and production. Please no questions about the need for four environments! :)For each environment I have two targets set up. For example, in the development environment, we have:<target name="env-dev" depends="" description="Sets up the variables for a CAPability development build" ><property name="createDebugSymbols" value="true" /><property name="doClean" value="true" /><property name="web.server" value="OCSCCSDDEV02" />
<property name="web.server.share" value="\\${web.server}\caproot$" />
<property name="web.server.portal.dir" value="${web.server.share}\capability" />
<property name="web.server.portal.bin.dir" value="${web.server.portal.dir}\bin" />
<property name="web.server.portal.modules.dir" value="${web.server.portal.dir}\DesktopModules" />
<property name="web.server.services.dir" value="${web.server.share}\WebServices" /><property name="db.server" value="OCSCCSDDEV02" />
<property name="db.database" value="capability" />
<property name="db.userName" value="capability" />
<property name="db.password" value="capability" />
<property name="db.sa.password" value="**********" />
<property name="db.restore.path" value="d:\SqlDataFiles" /><property name="config.env" value="Development" />
<property name="url" value="http://dev-capability.intel.com" /><property name="isRestoreDb" value="true" /><property name="isLocal" value="false" />
<property name="isDevelopment" value="true" />
<property name="isIntegration" value="false" />
<property name="isPreProd" value="false" />
<property name="isProduction" value="false" /></target><target name="deploy" depends="env-dev, build-version" description="Deploys CAPability to the Development environment">
<property name="build.name" value="${project.name}-${build.version}" />
<property name="build.dir" value="${draco.build.dir}\${build.name}" />
<property name="draco.output.dir" value="${draco.build.dir}\output" />
<property name="db.scripts.dir" value="${build.dir}/dbScripts" />
<call target="info" />
<call target="build" />
<call target="analysis" /><echo message="" />
<echo message="Deploying ${project.name} (${build.name}) to development environment!" />
<echo message="" /><echo message="Restoring and updating ${project.name}'s development DB from latest backup of production..." />
<call target="update-db" />
<echo message="Updating ${project.name}'s web server..." />
<call target="clean-webserver" if="${doClean}" />
<call target="update-webserver" />
<call target="update-web-cachemonitor" /><cvstag root="${cvs.capability.root}" dest="." revision="v_${cvs.build.version}"/>
<call target="update-latest-dir" />
</target>In the "env-dev" target contians all my properties for that particular environment, server names, output paths etc. and then the "deploy" target calls all the other targets to build the dlls, restore the database and run alter scripts against it, and then copy all ascx, aspx, dll, etc out to the server.When I want to move my code to that environment, I just initiate the "deploy" target. Actually, we do this all through Draco.NET. We have a Draco.NET build called "Project.Deploy" that we invoke using the Draco.NET client on demand from a developer.We have had a lot of success with this and have proliferated this method through out the group. This might not be the best way, but it works for us.We even follow this method for nightly and release builds of dlls and libraries that don't necessarily get deployed anywhere, but get consumed by other projects.I hope this helps.Jason
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Landes Eric (RBNA/CIT4.2)
Sent: Thursday, January 08, 2004 9:22 AM
To: [EMAIL PROTECTED]
Subject: [Nant-users] Newbie question on using nant to push to productionJust wanted to see if I'm on the right track here. Do others use nant (in combination with something like Cruise Control.net or Draco.net) to push builds to a production environment? I'm wanting to automate our builds hoepfully from development to test to production, and it looks like I could use these tools to get there. Of course from Test to Production would have to be controlled some type of flag to automate the deployment of the current version.
I want to make sure that there's no pitfalls to this approach. I'd appreciate anyones comments, links or experiences with this. We're an in-house dev shop, with .net web apps. TIA
*******************************************
Eric Landes
Robert Bosch Corporation - Automotive Group
*******************************************
Computer Information Technology Office - Engineering Applications
401 N. Bendix Drive - South Bend, IN 46628
Phone: 574-237-2290
Fax: 574-237-3105