Gateway on Azure Container App
Azure Container Apps (ACA) provides a serverless, managed platform for the Keeper Gateway, offering native High Availability (HA) and built-in secret encryption.
Last updated
pam gateway new -n "<Gateway Name>" -a <Application Name or UID> -c b64az containerapp env create \
--name <ENVIRONMENT_NAME> \
--resource-group <RESOURCE_GROUP> \
--location <LOCATION> \
--infrastructure-subnet-resource-id /subscriptions/<SUBSCRIPTION_ID>/resourceGroups/<VNET_RESOURCE_GROUP>/providers/Microsoft.Network/virtualNetworks/<VNET_NAME>/subnets/<SUBNET_NAME>az containerapp create \
--name <APP_NAME> \
--resource-group <RESOURCE_GROUP> \
--environment <ENVIRONMENT_NAME> \
--image keeper/gateway:latest \
--cpu 2.0 --memory 8Gi \
--min-replicas 2 \
--max-replicas 5 \
--registry-server index.docker.io \
--registry-username <DOCKER_HUB_USER> \
--registry-password <DOCKER_HUB_PASSWORD_OR_PAT> \
--secrets "gateway-config-secret=<YOUR_BASE64_CONFIG>" \
--env-vars "ACCEPT_EULA=Y" "GATEWAY_CONFIG=secretref:gateway-config-secret"az keyvault secret set --vault-name <VAULT_NAME> --name "DOCKER-TOKEN" --value "<YOUR_DOCKER_HUB_PAT>"
az keyvault secret set --vault-name <VAULT_NAME> --name "GATEWAY-CONFIG" --value "<YOUR_BASE64_CONFIG>"az containerapp create \
--name <APP_NAME> \
--resource-group <RESOURCE_GROUP> \
--environment <ENVIRONMENT_NAME> \
--image keeper/gateway:latest \
--cpu 2.0 --memory 8Gi \
--system-assigned \
--registry-server index.docker.io \
--registry-username <DOCKER_HUB_USER> \
--registry-password <Enter your Docker PAT, which starts with dckr_pat_...>
--env-vars "ACCEPT_EULA=Y"PRINCIPAL_ID=$(az containerapp show -n <APP_NAME> -g <RESOURCE_GROUP> --query identity.principalId -o tsv)
az role assignment create --assignee $PRINCIPAL_ID --role "Key Vault Secrets User" --scope /subscriptions/<SUB_ID>/resourceGroups/<RESOURCE_GROUP_ID>/providers/Microsoft.KeyVault/vaults/<VAULT_NAME>az containerapp secret set -n <APP_NAME> -g <RESOURCE_GROUP> \
--secrets "docker-password-kv=keyvaultref:https://<VAULT_NAME>.vault.azure.net/secrets/DOCKER-TOKEN,identityref:system" \
"gateway-config-kv=keyvaultref:https://<VAULT_NAME>.vault.azure.net/secrets/GATEWAY-CONFIG,identityref:system"az containerapp registry set
-n <APP_NAME> \
-g <RESOURCE_GROUP> \
--server index.docker.io \
--username <DOCKER_HUB_USER> \
--password "secretref:gateway-config-kv"template:
containers:
- name: <APP_NAME>
image: keeper/gateway:latest
env:
- name: GATEWAY_CONFIG
secretRef: gateway-config-kv # Use name from Option A or B
volumeMounts:
- mountPath: /dev/shm
volumeName: shm-volume
volumes:
- name: shm-volume
storageType: EmptyDir