Skip to content

Deployment using Docker Compose


Warning!

The minimum Docker version required for operation is 20.04.

Download the latest version of GitFlic self-hosted.

Installation and Launch on Linux

  1. Download the gitflic-server-enterprise image from your personal account. docker/images/gitflic-server-ee.tar

  2. Load the image into the system

    docker load -i gitflic-server-ee.tar
    
  3. Go to the docker folder with the gitflic-server release files and edit the .env file

    # .env
    ...
    GITFLIC_IMAGE=gitflic-server-ee:<current tag>
    ...
    
  4. Adjust other settings if necessary

  5. Create a certificate for the SSH server and an RSA key pair

    ssh-keygen -t ed25519 -N "" -q -f ./key.pem
    openssl genpkey -algorithm RSA -out ./private_key.pem -pkeyopt rsa_keygen_bits:2048
    openssl rsa -pubout -in private_key.pem -out ./public_key.pem
    
  6. Create a volume named gitflic_cert and place the created keys inside it. The volume mount point can be found using the command docker volume inspect gitflic_cert | grep Mountpoint

    docker volume create gitflic_cert
    sudo cp private_key.pem public_key.pem key.pem $(docker volume inspect gitflic_cert -f '{{.Mountpoint}}')
    
  7. Launch the system

    docker compose up -d
    
  1. Create a certificate for the SSH server and an RSA key pair

    ssh-keygen -t ed25519 -N "" -q -f ./key.pem
    openssl genpkey -algorithm RSA -out ./private_key.pem -pkeyopt rsa_keygen_bits:2048
    openssl rsa -pubout -in private_key.pem -out ./public_key.pem
    
  2. Create a volume named gitflic_cert and place the created keys inside it. The volume mount point can be found using the command docker volume inspect gitflic_cert | grep Mountpoint

    docker volume create gitflic_cert
    cp private_key.pem public_key.pem key.pem $(docker volume inspect gitflic_cert -f '{{.Mountpoint}}')
    
  3. Go to the docker directory inside the unpacked archive and edit the .env file if necessary

  4. Launch the system

    docker compose --detach -f docker-compose.yaml --env-file .env up
    

Login credentials

  • Email: adminuser@admin.local
  • Password: qwerty123

Installation and Launch on Windows

Use PowerShell for installation and configuration. When using MINGW, file paths and commands may differ; you need to independently determine the standard paths to the files described below.

  1. Create a certificate for the SSH server and an RSA key pair

    ssh-keygen -t ed25519 -N "" -q -f ./key.pem
    openssl genpkey -algorithm RSA -out ./private_key.pem -pkeyopt rsa_keygen_bits:2048
    openssl rsa -pubout -in private_key.pem -out ./public_key.pem
    
  2. Create a volume named gitflic_cert and place the created keys inside it. The volume mount point can be found using the command docker volume inspect gitflic_cert | grep Mountpoint

    docker run --rm -v gitflic_cert:/gitflic_cert .:/_data alpine:latest cp _data/key.pem _data/private_key.pem _data/public_key.pem /gitflic_cert
    
  3. Go to the docker directory inside the unpacked archive and edit the .env file if necessary

  4. Launch the system

    docker compose -f docker-compose.yaml --env-file .env up --detach
    

Login credentials

  • Email: adminuser@admin.local
  • Password: qwerty123

Description of New Volumes and Data

  • Volume gitflic_data is responsible for storing GitFlic software data.
  • Volume gitflic_etc is responsible for storing GitFlic software settings.
  • Volume gitflic_cert is responsible for storing GitFlic software certificates.
  • Volume pg_data is responsible for storing Postgres database data.
  • Volume redis_data is responsible for storing Redis database data.
  • The .env file is the main file loaded by default.
  • The external.env file is additional and serves to override data. It is responsible for database connections, mail configuration, and working with elasticsearch. The file can be empty or commented out but must be present in the directory alongside docker-compose.yaml.
  • The TRANSPORT_URL parameter has been removed from .env. Data from the BASE_URL variable is substituted into it.
  • The TRANSPORT_SSH parameter is used only during the initial initialization of GitFlic software and serves to set the correct display of links for SSH. If necessary, it can be overridden in the GitFlic software web interface.
  • If it is necessary to add additional parameters to gitflic-server, create a file with the .properties extension (for example, s3.properties) and place it in the gitflic_etc volume. Changes will be applied automatically after restarting the GitFlic software. It is not recommended to modify the application.properties file.

Automated translation!

This page has been automatically translated. The text may contain inaccuracies.