Skip to content

Auto deploy mysql

Overview

There are two MRs that depend on each other. This overview has been copied to both MRs.

!73 (closed) and gitlab-org/charts/auto-deploy-app!77 (closed) add the MySQL Helm chart to Auto DevOps.

Additionally, variables are provided for database USER, PASSWORD, HOST, DB and PORT.

Default variables are provided for database USER, PASSWORD, DB and ENABLED, removing the need to include the following block in https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Auto-DevOps.gitlab-ci.yml:

POSTGRES_USER: user
POSTGRES_PASSWORD: testing-password
POSTGRES_ENABLED: "true"
POSTGRES_DB: $CI_ENVIRONMENT_SLUG

Currently (prior to this MR), there appears to be nothing preventing both a managed (Crossplane) DB and an Auto Deploy (GitLab) DB being deployed for the same application.

The introduction of the new environment variables (exposed to the deployed app) for the Auto Deploy DB would have conflicted with the variables exposed for the managed DB so Auto Deploy DB variables have been prefixed with DATABASE_.

The DATABASE_URL environment variable retains its previous behaviour (returning the PostgreSQL URL), however this can be overridden by setting AUTO_DEVOPS_DATABASE_DEFAULT=mysql.

Resolves:

Requires:

Edited by 🤖 GitLab Bot 🤖

Merge request reports