Wrong SSH/external url provided on Gitlab AWS


I just installed Gitab on an AWS machine. I spend a lot of time trying to find the source of Permission Denied (public key) error even after adding the right SSH key. It turned out that the SSH URLerror1 provided by the Gitlab Web Interface was wrong all along. It didn’t match the ec2 machine id. I just wanted to know why this happened and how can I modify this without tampering the gitlab.rb file. or is there something I did wrong while setting it up.error2

Your IP address on EC2 is not guaranteed, it can change. Just a guess, but it probably changed after a reboot (?) during the installation process… I have had AWS machines seemingly randomly do so…