build · deployment

Workshop – Playing Sitecore 9 auto-deploy with TeamCity on your machine (Part 2)

This post was used for my workshop at the company. However, it might be an initiative of your own approach for automating Sitecore deployments with Teamcity. (Note: the summary is here)

Setup Prerequisites

What are we gonna do in Part 2?

We will fulfill the value of all the configuration parameters so that the automating deployment will be able to run successfully.

  1. log into TeamCity
  2. create the configuration parameters:
    • Administration -> Projects -> Viet Hoang – Simple Development Framework -> CA – CD1 – CD2
    • left navigation: select Parameters  -> Add new parameter
  3. add configuration parameter vhs.source.folder
    • Name: vhs.source.folder
    • Value: .
  4. add configuration parameter vhs.AssemblyVersion
    • Name: vhs.AssemblyVersion
    • Value: 2.1.0
  5. repeat #2 to add configuration parameter vhs.configuration
    • Name: vhs.configuration
    • Value: Release
  6. repeat #2 to add configuration parameter vhs.gitBranch
    • Name: vhs.gitBranch
    • Value: Release-2.1.3
  7. repeat #2 to add configuration parameter vhs.deployIisAppPath_CM
    • Name: vhs.deployIisAppPath_CM
    • Value: the CM website name in IIS
      • adsc9_6
  8. repeat #2 to add configuration parameter vhs.deployIisAppPath_CD1
    • Name: vhs.deployIisAppPath_CD1
    • Value: the CD1 website name in IIS
      • adsc9_4
  9. repeat #2 to add configuration parameter vhs.deployIisAppPath_CD2
    • Name: vhs.deployIisAppPath_CD2
    • Value: the CD2 website name in IIS
      • adsc9_5
  10. repeat #2 to add configuration parameter vhs.msDeployUsername
    • Name: vhs.msDeployUsername
    • Value:
  11. repeat #2 to add configuration parameter vhs.msDeployPassword
    • Name: vhs.msDeployPassword
    • Value:
  12. repeat #2 to add configuration parameter vhs.msDeployServiceUrl_CM
    • Name: vhs.msDeployServiceUrl_CM
    • Value: localhost
  13. repeat #2 to add configuration parameter vhs.msDeployServiceUrl_CD1
    • Name: vhs.msDeployServiceUrl_CD1
    • Value: localhost
  14. repeat #2 to add configuration parameter vhs.msDeployServiceUrl_CD2
    • Name: vhs.msDeployServiceUrl_CD2
    • Value: localhost
  15. repeat #2 to add configuration parameter vhs.errorOnFail
    • Name: vhs.errorOnFail
    • Value: true
  16. repeat #2 to add configuration parameter vhs.forceToPublishWithMsBuild
    • Name: vhs.forceToPublishWithMsBuild
    • Value: true
  17. repeat #2 to add configuration parameter vhs.instance.root
    • Name: vhs.instance.root
    • Value: the full path parent folder of CM/CD1/CD2 website folder
      • Ex: CM website root is “F:\Sitecore Training\viethoang.cm.local” then the value is F:\Sitecore Training
  18. repeat #2 to add configuration parameter vhs.instance.name_CM
    • Name: vhs.instance.name_CM
    • Value: the name of CM website folder
      • Ex: CM website root is “F:\Sitecore Training\viethoang.cm.local” then the value is viethoang.cm.local
  19. repeat #2 to add configuration parameter vhs.instance.name_CD1
    • Name: vhs.instance.name_CD1
    • Value: the name of CD1 website folder
      • Ex: CD1 website root is “F:\Sitecore Training\viethoang.cd1.local” then the value is viethoang.cd1.local
  20. repeat #2 to add configuration parameter vhs.instance.name_CD2
    • Name: vhs.instance.name_CD2
    • Value: the name of CD2 website folder
      • Ex: CD1 website root is “F:\Sitecore Training\viethoang.cd2.local” then the value is viethoang.cd2.local
  21. repeat #2 to add configuration parameter vhs.unicorn.sourceFolder
    • Name: vhs.unicorn.sourceFolder
    • Value: the full path of an available folder which will stores *.yml files
      •  Note: it should be short such as “D:\unicorn_files” in order to avoid “Windows File Paths Longer Than 255 Characters” issue in the very first run of Unicorn Sync
  22. finally we’ve just done for the configuration parameters
    • adsc9_12

What’s next?

Run build Viet Hoang – Simple Development Framework :: CA – CD1 – CD2. Hopefully, you will have no any issues and when the build is done, you would see something like this:

adsc9_7

 

How to verify the automating Sitecore deployments at your machine

Hopefully, you would see something like this:

This slideshow requires JavaScript.

Got issues?

Please send your issues (with screenshots if possible) to viet.hoang.sitecore@gmail.com so that I have a chance to understand your problem and be able to suggest the solution.

Happy Sitecore coding!

2 thoughts on “Workshop – Playing Sitecore 9 auto-deploy with TeamCity on your machine (Part 2)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s