I tried to change port number on these files. But when I run gitlab-ctl
reconfigure for updating. I can't access my link (http://myaddress.example:8790
) Those files which I changed are:
/var/opt/gitlab/gitlab-rails/etc/gitlab.yml
/opt/gitlab/embedded/conf/nginx.conf
/opt/gitlab/embedded/cookbooks/gitlab/attributes/default.rb
/opt/gitlab/embedded/service/gitlab-rails/config/gitlab.yml
/var/opt/gitlab/nginx/conf/gitlab-http.conf
In /etc/gitlab/gitlab.rb
I change external_url "http://myaddress.example:8790"
How can I fix it?
Using GIT_LAB_PATH as you gitlab base directory (the root where is it installed)
GIT_LAB_PATH/gitlab/gitlab.yml
If you use non-standard ssh port you need to specify it
ssh_port: SSH_PORT
Modify
GIT_LAB_PATH/gitlab-shell/config.yml
to use the new HTTP port:Url to gitlab instance. Used for api calls. Should end with a slash.
Modify
/etc/nginx/sites-available/gitlab
listen *:HTTP_PORT default_server; # e.g., listen 192.168.1.1:80; In most cases *:80 is a good idea
Modify
/etc/ssh/sshd_config
What ports, IPs and protocols we listen for
Restart SSH, restart GitLab, restart nginx:
sudo service ssh restart sudo service gitlab restart sudo service nginx restart
Test GitLab:
sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production
Update the remote origins for your repos to use the new port:
Dear all I missing open port in firewall I type it on linu terminal
It worked