直接修改配置文件:
sudo vim /opt/gitlab/embedded/service/gitlab-rails/config/gitlab.yml
## GitLab settings
gitlab:
## Web server settings (note: host is the FQDN, do not include http://)
host: 119.1.1.181
port: 28080
https: false
然后重启gitlab:
sudo gitlab-ctl restart