Source Code - CD Process
Deploy Artefact to Staging and Production
The function of the CD process is to deploy artefacts that were created by the CI process to the Staging and Production environment.
The codes deployment process leverages Azure DevOps Pipeline - <subscription-name>.SRC.CD
The CD process runs automatically after the CI process has been completed or triggered manually within the Cloudvanti Sitefinity Management Portal.
Cloudvanti Sitefinity provides Deployment slots within the Production environment to help minimize downtime and acts as a precaution should it fail to deploy to the live website. Click CI/CD Sitefinity Concept for more details about Azure Deployment Slots.
Here is the code deployment process:
- The Staging CD Pipeline will automatically be triggered once the code building within the CI Pipeline is completed.
- The artefact created from CI Pipelines will be deployed to the Staging website.
- When the User Testing in the Staging environment is done, user can approve the build to be deployed on Production. The Production CD Pipeline will start automatically.
- In the Production CD Pipeline, the artefact will be deployed to the Deployment slot.
- The primary database will be duplicated to the secondary database. Then the secondary database will be connected to the Deployment slot.
- Once the Deployment slot is ready it will be swapped with the Production slot. See CI/CD Sitefinity Concept for more detail about Deployment Slot.
Manually Promote Code to Staging Environment
Promoting the code is the action of publishing an artefact created from the CI process to the Staging environment. The process will start automatically once the CI Process has completed.
Here is how you can validate the Staging Code Deployment:
- From the Cloudvanti Sitefinity Management Portal menu, select Pipelines. Then select Releases. You can check the state of the CD Process within the list of releases (<subscription-name>.SRC.CD).
- If there is an unexpected complication when initiating the process, clicking the Create Release button in the upper right area will manually trigger the pipeline.
- To check on the Staging CD process, click on the STG part of the stages on the release list.
- A list will appear where user can check the log for errors in the process of Staging CD Pipeline.
- Upon successful deployment, the Sitefinity will run within Cloudvanti's Staging environment. The CD Pipeline will be in pending approval status before it can be deployed to the Production environment. The codes require verification that they can successfully run in Staging before proceeding to the next part of the deployment.
Manually Promote Code To Production Environment
Once all of the testings have been done on the Staging environment, the code is ready to be promoted. This will publish the Artifact created from the CI process to the Production environment.
Here are the steps to validate the Production code for deployment:
- User Approval is needed for deployment within the Staging environment to start the Production Pipeline. A designated user will receive an email where they can approve the process.
- Alternatively, it can also be approved via the Cloudvanti Sitefinity Management Portal.
- Select Pipelines. Then select Releases. Click on the PRD part of the stages from the list of releases (<subscription-name>.SRC.CD)
- Select Pre-deployment approvals and click view approval
- Submit your approval