I’ve read a lot about blue/green deployments recently.
But how is the switch done between your old and new websites? More importantly, how can I do it easily without complicated proxies and fail-over technologies?
One method that occurred to me is to lower your dns time to live (TTL), change the dns name record to point to the new software, if the new software disrupts service, change it back and your website is back online.
After setting up the project build in TeamCity (on MS Winows), I wanted to allow access from the browser. This is done over https and requires tomcat to be configured. This is simple but the documentation is confusing.
1. Create a certificate using the keytool command.
%JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA
The passphrase for the certificate and the containde should be the same due to a TomCat limitation.
2 Add the followng section to the server.xml file located in C:\TeamCity\conf
scheme="https" secure="true" SSLEnabled="true"
You can test the configuration by browsing to https://localhost:8443 from the teamcity server.