使用Docker部署 Gitlab 后 局域網可以訪問到,但 無法用git clone 同步
應該如何設定呢?
8080、80 和 22埠 有其它程式占用
docker 映射的引數:
-p 211:80 \
-p 212:22 \
/var/opt/gitlab/gitlab-rails/etc/gitlab.yml 設定
gitlab:
## Web server settings (note: host is the FQDN, do not include http://)
host: mygitlab.com
port: 80
https: false
# Uncommment this line below if your ssh host is different from HTTP/HTTPS one
# (you'd obviously need to replace ssh.host_example.com with your own host).
# Otherwise, ssh host will be set to the `host:` value above
ssh_host:
/ect/gitlab/gitlab.rb 設定
external_url 'http://mygitlab.com'
然后在訪問的電腦上修改了 host mygitlab.com 到 部署的 192.168.0.167 (部署docker的電腦)
然后訪問登錄是正常的,但 git clone 提示
remote: HTTP Basic: Access denied
fatal: Authentication failed for ‘http://mygitlab.com/wujh/test-project.git/'
是不是還要做一些埠轉發設定?
轉載請註明出處,本文鏈接:https://www.uj5u.com/qita/263109.html
標籤:Docker
上一篇:求助求助大佬
