Running on a Raspberry Pi

In order to run GitLab on a Raspberry Pi, you need either a Pi 2 or a Pi 3. We recommend using a Pi 3 for best results. The Pi 1 and Pi Zero do not have enough RAM to make running GitLab feasible.

Configure Swap

Even with a newer Pi, the first setting you will want to change is to ensure the device has enough memory available by expanding the swap space to 4GB.

On Raspbian, Swap can be configured in /etc/dphys-swapfile. See the manpage for available settings.

Reduce running processes

Once you have installed the GitLab package, you should change the following settings before running reconfigure.

# Reduce the number of running workers to the minimum in order to reduce memory usage
unicorn['worker_processes'] = 2
sidekiq['concurrency'] = 9

# Turn off monitoring to reduce idle cpu and disk usage
prometheus_monitoring['enable'] = false

Additional recommendations

Use a proper harddrive

GitLab will perform best if you mount /var/opt/gitlab and the swapfile from a harddrive rather than the SDcard.

You can attach an external harddrive to the Pi using the USB interface.

Use external services

You can improve the GitLab performance on the Pi by connecting GitLab to external database and redis instances.