Production Deployment
This document provides the complete process for deploying OmniSpatial to production environments using Azure DevOps pipelines and GitOps workflows.
Overview
Production deployments follow a two-step process:
- Build Phase: Create a production build using Azure DevOps pipeline
- Deploy Phase: Update the GitOps configuration with the new build tag
GitOps Architecture
The deployment process uses Flux CD for GitOps-based continuous deployment to the production Azure Kubernetes Service (AKS) cluster:
- Target Cluster: Operations AKS Cluster
- GitOps Tool: Flux CD monitors the GitOps repository for configuration changes
- Deployment Method: Automatic deployment when Helm release configuration is updated
Step 1: Create Production Build
Pipeline Execution
- Navigate to the Production Build Pipeline
- Click "Run pipeline"
- Configure the following parameters:
- Branch: Select
main - Environment: Choose
productionwhen prompted with "Which environment to build?"
- Branch: Select
- Start the pipeline execution
Build Completion
Once the pipeline completes successfully, locate the generated build tag number. The build tag follows this format:
image:
tag: production-40672
Note: The number (e.g.,
40672) represents the build number and will be unique for each deployment.
Step 2: Update GitOps Configuration
Helm Release Configuration
Update the production deployment configuration with the new build tag:
- Navigate to the Helm Release Configuration
- Edit the
helm-release.yamlfile - Update the
tagvalue under theimagesection with your new build tag number - Commit the changes
Deployment History
To view previous deployments and track changes:
- File History: Helm Release History
- Purpose: Review deployment timeline and rollback information if needed
Deployment Verification
After updating the GitOps configuration, Flux CD will automatically detect the changes and deploy to the production AKS cluster:
- Flux CD Sync: Monitor Flux CD for automatic synchronization of the configuration changes
- AKS Deployment: Verify the new image tag is deployed successfully to the Operations AKS Cluster
- Health Checks: Perform basic health checks on the production environment
- Pod Status: Check that new pods are running with the updated image tag
Troubleshooting
Common Issues
- Pipeline Failures: Check build logs in the Azure DevOps pipeline
- Deployment Issues: Verify the build tag exists in the container registry
- GitOps Sync Issues: Check Flux CD status and logs in the AKS cluster
- Pod Deployment: Verify pods are pulling the correct image from ACR
Rollback Process
To rollback to a previous version:
- Check the deployment history
- Identify the previous working build tag
- Update the
helm-release.yamlwith the previous tag - Commit the changes to trigger rollback