here's my gitlab & traefik configuration
version: '3.7'
services:
gitlab_web:
image: 'gitlab/gitlab-ce:latest'
restart: always
hostname: 'gitlab.roger'
container_name: gitlab-ce
environment:
GITLAB_OMNIBUS_CONFIG: |
external_url 'http://gitlab.roger'
labels:
- "traefik.enable=true"
- "traefik.http.routers.gitlab_local.rule=Host(`gitlab.roger`)"
- "traefik.http.routers.gitlab_roger.entrypoints=web"
- "traefik.http.services.gitlab_roger.loadbalancer.server.port=80"
- "traefik.tcp.routers.gitlab-ssh-roger.rule=HostSNI(`gitlab.roger`)"
- "traefik.tcp.routers.gitlab-ssh-roger.entrypoints=ssh"
- "traefik.tcp.routers.gitlab-ssh-roger.service=gitlab-ssh-roger"
- "traefik.tcp.services.gitlab-ssh-roger.loadbalancer.server.port=22"
volumes:
- '$GITLAB_HOME/config:/etc/gitlab'
- '$GITLAB_HOME/logs:/var/log/gitlab'
- '$GITLAB_HOME/data:/var/opt/gitlab'
networks:
- rudak_traefik_network
gitlab-runner:
image: gitlab/gitlab-runner:alpine
restart: always
depends_on:
- gitlab_web
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./runner.toml:/etc/gitlab-runner/config.toml
networks:
- rudak_traefik_network
networks:
rudak_traefik_network:
external: true
version: "3.7"
services:
traefik:
image: "traefik:v2.3"
command:
- "--configfile=/etc/traefik/traefik_static.yaml"
ports:
- "22:22"
- "80:80"
- "8080:8080"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "./traefik_static.yaml:/etc/traefik/traefik_static.yaml:ro"
- "./dynamic_conf.yaml:/etc/traefik/dynamic_conf.yaml:ro"
networks:
- rudak_traefik_network
networks:
rudak_traefik_network:
external: true
traefik_static.yaml
api:
dashboard: true
insecure: true
entryPoints:
web:
address: ":80"
websecure:
address: ":443"
ssh:
address: ":22"
providers:
docker:
endpoint: "unix:///var/run/docker.sock"
exposedByDefault: false
file:
filename: "/etc/traefik/dynamic_conf.yaml"
I have access to the gitlab web interface
I can access git clone from my different containers which are on the only rudak_traefik_network
I can git clone from my docker server too
my problem is that I can't access git clone from my remote pc
the traefik dashboard is all success with tcp router HostSNI(gitlab.roger) success too
the ssh key on my pc is correctly inserted in the gitlab interface and it works fine from any container, but I'm getting this
git clone git@gitlab.roger:roger/test-project.git
Cloning into 'test-project'...
git@gitlab.roger's password:
(my server's name is strangely roger, but I don't think that's the problem ^^.)