This project provides an compose example of how to run Git Providers with Podman and Docker Compose. It currently has:
-
Local GitLab
-
Local Gitea
-
Ubuntu 24.04 (might work with other versions, only tested on 24.04)
-
Podman 4.9.3 or later installed and working
-
Podman running as a rootless service
-
docker
aliased topodman
-
DOCKER_HOST
exported to the Podman socket -
Podman network backend set to netavark
-
Docker Compose v2.28.1 or later
ℹ️
|
Older versions than those mentioned above are not tested, but could work. |
podman info # see version
podman info | grep -A2 'remoteSocket' # should list exists true and the socket
alias docker=podman
export DOCKER_HOST=unix:///run/user/1000/podman/podman.sock # or whatever your podman socket is, see podman info
podman info | grep -A2 'backend' # only tested with netavark
docker compose version # v2 and v2.28.1++
podman compose pull && podman compose --profile gitlab up
ℹ️
|
Before configuring your first runner, you may see errors like "ERROR: Failed to load config stat /etc/gitlab-runner/config.toml:". These can be ignored for now. You might also need to give rootless Podman port rights: sudo sysctl net.ipv4.ip_unprivileged_port_start=80 |
podman exec -it gitlab-ce gitlab-rake "gitlab:password:reset[root]"
podman compose down && podman compose --profile gitlab up
Visit GitLab UI and login with root/your_new_password
podman exec -it gitlab-runner /bin/bash
gitlab-runner register --url http://10.5.0.5/ --token <your_token>
vi /etc/gitlab-runner/config.toml
Refer to the example runner configuration at runner.example.toml
in this project. Ensure to add necessary settings, including privileged
and FF_NET..
for Podman. For more settings, see the GitLab Runner documentation.
podman compose down && podman compose up
# Login to UI and check that the runner is online in the admin area
ℹ️
|
10. Add test projects, CI pipelines, and start experimenting!
Gitea setup instructions are to be added. |
This project is licensed under the Creative Commons CC0-1.0 License - effectively placing it in the public domain. You may use it freely without attribution.