Migrate from the Linux package to the Helm chart
This guide will help you migrate from a package-based GitLab installation to the Helm chart.
Prerequisites
Before the migration, a few prerequisites must be met:
- The package-based GitLab instance must be up and running. Run
gitlab-ctl status
and confirm no services report adown
state. - It is a good practice to verify the integrity of Git repositories prior to the migration.
- A Helm charts based deployment running the same GitLab version as the package-based installation is required.
- You need to set up the object storage which the Helm chart based deployment will use. For production use, we recommend you use an external object storage and have the login credentials to access it ready. If you are using the built-in MinIO service, read the docs on how to grab the login credentials from it.
Migration steps
-
Migrate any existing data from the package-based installation to object storage:
-
Visit the package-based GitLab instance and make sure the migrated data are available. For example check if user, group and project avatars are rendered fine, image and other files added to issues load correctly, etc.
-
Create a backup tarball and exclude all the already migrated directories.
For local backups (default), the backup file is stored under
/var/opt/gitlab/backups
, unless you explicitly changed the location. For remote storage backups, the backup file is stored in the configured bucket. -
Restore from the package-based installation
to the Helm chart, starting with the secrets. You will need to migrate the
values of
/etc/gitlab/gitlab-secrets.json
to the YAML file that will be used by Helm. -
Restart all pods to make sure changes are applied:
kubectl delete pods -lrelease=<helm release name>
- Visit the Helm-based deployment and confirm projects, groups, users, issues etc. that existed in the package-based installation are restored. Also, verify if the uploaded files (avatars, files uploaded to issues, etc.) are loaded fine.