Backing up Gitlab on Linode Object Storage

Traducciones al Español
Estamos traduciendo nuestros guías y tutoriales al Español. Es posible que usted esté viendo una traducción generada automáticamente. Estamos trabajando con traductores profesionales para verificar las traducciones de nuestro sitio web. Este proyecto es un trabajo en curso.
Create a Linode account to try this guide with a $100 credit.
This credit will be applied to any valid services used during your first 60 days.

In This Guide

GitLab is a complete solution for all aspects of your software development. At its core, GitLab serves as your centralized remote Git repository. GitLab also features built-in tools that represent every task in your development workflow, from planning to testing to releasing.

All modern GitLab installations additionally include tooling to create backups on Linode’s Object Storage using a single command. This guide will describe the process for initially setting up an Object Storage Bucket which can be used to remotely store backups created directly from Gitlab.

Before you Begin

Configuring Gitlab For Object Storage Backups

In order to configure Gitlab on Linode’s Object Storage, the Gitlab instance must first be Accessed Directly Over SSH. To do this, enter the following command, replacing the username and IP address with the unique username and IP address of your Linode:

ssh [email protected]

Once access has been gained, using a text editor of your choice, edit the ‘/etc/gitlab/gitlab.rb’ configuration file to reflect the following:

sudo nano /etc/gitlab/gitlab.rb
File: /etc/gitlab/gitlab.rb
gitlab_rails['backup_upload_connection'] = {
  'provider' => 'AWS',
  'region' => 'us-east-1',
  'endpoint'    => 'https://us-east-1.linodeobjects.com',
  'aws_access_key_id' =>YOUR_ACCESS_KEY,
  'aws_secret_access_key' =>YOUR_SECRET_KEY,
}
gitlab_rails['backup_upload_remote_directory'] = 'bucketname'

The following chart will explain each configuration settings in additional detail:

DescriptorSetting
providerAWS (The provider must be set to AWS because it is dependent on s3cmd)
regionThe region the bucket was created in. A full list of regions can be found in the Product Documentation.
endpointThe endpoint url for the datacenter. Uses the syntax of region.linodeobjects.com
aws_access_key-idThe Object Storage Access Key created in a previous step.
aws_secret_access_keyThe Object Storage Secret Key created in a previous step.
gitlab_rails[‘backup_upload_remote_directory’]The label of the bucket created during bucket creation.

Once the configuration settings are completed, apply the configuration with the following command:

gitlab-ctl reconfigure

Creating a Backup

Once configured, backups can now be created for your gitlab instance at any time by using the following command:

gitlab-backup create

Once complete, the backup will be freely available in a compressed .tar file within the Object Storage bucket, and can be observed directly in the Linode Cloud Manager.

This page was originally published on


Your Feedback Is Important

Let us know if this guide made it easy to get the answer you needed.


Join the conversation.
Read other comments or post your own below. Comments must be respectful, constructive, and relevant to the topic of the guide. Do not post external links or advertisements. Before posting, consider if your comment would be better addressed by contacting our Support team or asking on our Community Site.