Continuous Deployment with AX2012 and TeamCity (part 1)


Error message

Deprecated function: implode(): Passing glue string after array is deprecated. Swap the parameters in drupal_get_feeds() (line 394 of D:\home\site\wwwroot\webapp\includes\

Whether you work in a shop where you are the “AX guru” or if you are a part of a team of rockstars, consultants, or VARs combined: the rate at which you can test and deploy customizations heavily impacts your promised Turn-Around-Time to the business.  The more developers you have contributing work, the more complex it can become. Having an organized and automated building process for AX is essential to any dev shop.

I’m a big proponent of Team Foundation Server.  It integrates natively with AX 2012 and is a great way to keep track of enhancement requests and bug fixes.  Unfortunately for our team, we do not have a TFS Build server.  So, to circumvent this I went to Google and found JetBrain’s TeamCity which has a fabulous price of FREE!  Below I’ll detail the experience of setting up a TC install and configuring TFS ( part 1 ), then in a separate post I’ll demonstrate the required modifications to some startup commands to AX ( part 2 ), and lastly I’ll cover how to kick off an automatic build ( part 3 ).

To start, there are some pre-requisites:

*You have a dedicated standalone VM for your AX build instance (AOS, Client, SQLServer)
*You have TFS server hosted on-prem or online
*You have the AX instance properly hooked up to TFS

Step 1) Download the latest version of TeamCity and install using default settings.

Step 2) Run the TeamCity First time startup guide.

Step 3) Choose SQL Server and download the JDBC Drivers.

Step 4) Copy the SQLJDBC4.jar file to C:\ProgramFiles\JetBrains\TeamCity\lib\jdbc directory.  Refresh your web page and verify the drivers were loaded:

Step 5) Create the new database in SQL Management Studio.  You can use any settings you need, the screenshot shows an example install only.

Step 6) Create a SQL user with full dbo permissions as it will need to be able to modify the schema.  We can switch to Windows Authentication later.

Step 7) Use the appropriate settings on the Database Connection Setup page:

Step 8) Create your administrator account.

Step 9) Let’s enable Windows authentication now.  Edit the file in C:\ProgramData\JetBrains\TeamCity\config and set the integrated security option:


The user account that the TeamCity Server service runs under needs to have full db_owner permission to the database you’ve specified. Restart the service and make sure you can still log in.

Step 10) Enable Active Directory authentication.  Edit the auth-config.xml file in C:\ProgramData\JetBrains\TeamCity\config and specify the LDAP type:

You’ll want to edit the ldap-config.xml file as well, using the latest recommended settings from JetBrains.

You now should have a fully running TeamCity Installation! Next up, how to add a few commands to allow AX to be built automatically.