Development (local) and production (cloud) using GitHub Actions.
AWS_ACCESS_KEY_ID
.AWS_SECRET_ACCESS_KEY
.set up a workflow yourself
and click it.env
:Key | Description | Sample value |
---|---|---|
AWS_REGION | Region of your AWS ECS cluster. | us-west-2 |
CONTAINER_NAME | Set this to the name of the container in the containerDefinitions section of your task definition. | mage-data-production-container |
ECR_REPOSITORY | The name of the AWS ECR repository you created to store your Docker images. | mage-data |
ECS_CLUSTER | The name of your AWS ECS cluster. | mage-production-cluster |
ECS_SERVICE | The name of your AWS ECS service. | mage-production-ecs-service |
ECS_TASK_DEFINITION | Go to your AWS ECS task definition for the above service. Click on the JSON tab on the task definition detail page. Copy the JSON string content and save it to a file in your root folder containing your Mage project. Use the path to that file as the value in this field. | some_path/ecs-task-definition.json |
GCP_CREDENTIALS
.
json { "type": "service_account", "project_id": "mage-123456", "private_key_id": "...", "private_key": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n", "client_email": "mage@mage-123456.iam.gserviceaccount.com", "client_id": "...", "auth_uri": "https://accounts.google.com/o/oauth2/auth", "token_uri": "https://oauth2.googleapis.com/token", "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/mage%40mage-123456.iam.gserviceaccount.com" }
set up a workflow yourself
and click it.
env
:
Key | Description | Sample value |
---|---|---|
GAR_LOCATION | Region that Mage is already deployed in. | us-east1 |
GOOGLE_CLOUD_RUN_SERVICE_NAME | The name of your Google Cloud Run service. Go to the Google Cloud Run dashboard to find it. | mage-data |
IMAGE | The name of the Docker image you pushed to the above GCP Artifact Registry. | mageai |
PROJECT_ID | Project ID of where you launched Mage using Terraform. | mage-123456 |
REPOSITORY | The name of your GCP Artifact Registry that is storing your Docker image. | mageprod |
Key | Description | |||
---|---|---|---|---|
AZURE_CREDENTIALS | The entire JSON output from the service principal creation step | |||
REGISTRY_LOGIN_SERVER | The login server name of your registry (all lowercase). Example: myregistry.azurecr.io | |||
REGISTRY_USERNAME | The clientId from the JSON output from the service principal creation | |||
REGISTRY_PASSWORD | The clientSecret from the JSON output from the service principal creation | |||
RESOURCE_GROUP | The name of the resource group you used to scope the service principal |
Service ID Principal
method for authentication, but you can check Microsoft’s docs for the OpenID Connect
method.
Alternatively, you can use the az container app up
command in the Deploy to Azure extension in the Azure CLI. This command streamlines creation of the GitHub workflow and deployment steps.