Prerequisites
Before installing Gitaly, ensure you have the required dependencies:- Go: Version 1.16 or 1.17
- Ruby: Version 2.7
- Git: Version 2.33.0 or newer
- Make: For building from source
Installation Methods
Using Pre-built Binaries
Most users won’t install Gitaly on its own. It is already included in your GitLab installation.Building from Source
To build and install Gitaly from source:Build Gitaly
Run This will:
make to download and compile Ruby dependencies and compile the Gitaly Go executable:- Install Ruby dependencies
- Compile all Gitaly executables
- Place binaries in
./_build/bindirectory
Install binaries
Install Gitaly binaries to the target directory:By default, binaries are installed to
/usr/local/bin. You can customize the installation directory using the PREFIX and DESTDIR variables:Build Options
Custom Build Configuration
You can customize the build process by creating aconfig.mak file in Gitaly’s root directory:
Build Variables
The prefix where Gitaly binaries will be installed. Binaries will end up in
${PREFIX}/bin.The prefix where Git will be installed when building bundled Git.
Build tags to include when compiling. For example, to enable Jaeger tracing:
Set to
1 to enable FIPS mode with BoringCrypto.Build Targets
The Makefile provides several useful targets:make build- Build Gitaly but do not install itmake install- Build and install Gitalymake test- Execute both Go and Ruby testsmake clean- Remove all generated build artifactsmake help- Print help about available targets
Verification
After installation, verify that Gitaly is correctly installed:Next Steps
Configuration
Configure Gitaly for your environment
Authentication
Set up authentication tokens