Build Docker images, push to a registry, and deploy via SSH, ECS, ACA, or Kubernetes.
Go to Settings > CI/CD > General pipelines and set CI/CD configuration file to:
https://gitlab-ci-yaml-template.enouvo.com/docker/.gitlab-ci.yml
include: - 'https://gitlab-ci-yaml-template.enouvo.com/docker/.gitlab-ci.yml'
DOCKER_REGISTRY | Registry URL (e.g. gitlab.enouvo.com:5050) |
DOCKER_REGISTRY_USERNAME | Registry username |
DOCKER_REGISTRY_PASSWORD | Registry password |
DOCKER_CONTAINER_PORT | Port your app listens on |
| Variable | Default | Description |
|---|---|---|
DOCKER_CPU_LIMIT | 0.5 | CPU limit for container |
DOCKER_MEMORY_LIMIT | 512m | Memory limit |
DOCKER_FILE_PATH | Dockerfile | Path to Dockerfile |
DOCKER_BUILD_ARGS | Comma-separated build args | |
DOCKER_COMPOSE_ENABLED | false | Use docker-compose build |
Deploys via Docker remote daemon over SSH. Set DOCKER_HOST and TLS certs per environment.
Set DOCKER_DEPLOY_TYPES=k8s and configure:
| Variable | Description |
|---|---|
KUBE_CONFIG | Base64-encoded kubeconfig |
K8S_DEPLOYMENT_HOST | Ingress hostname |
K8S_DEPLOYMENT_CONTAINER_PORT | Container port |
K8S_DEPLOYMENT_REPLICAS | Number of replicas (default: 1) |
K8S_DEPLOYMENT_CONTAINER_VOLUME_MOUNT_PATH | Single NFS volume mount path |
K8S_DEPLOYMENT_CONTAINER_VOLUME_MOUNT_PATHS | Multiple mounts (comma-separated, e.g. /app/data:data,/app/workspace:workspace) |
K8S_DEPLOYMENT_SECURITY_CONTEXT_FS_GROUP | GID for volume ownership |
Set DOCKER_DEPLOY_TYPES=ecs and configure AWS credentials + ECS variables.
Set DOCKER_DEPLOY_TYPES=aca and configure Azure credentials.
Skip specific stages per environment:
SKIP_DEV_BUILD=true SKIP_STAGING_DEPLOY=true SKIP_RELEASE_TEST=true
test → build → scan → deploy → notify