Hi!
We are trying to upgrade our instance from 9.4.5 to the latest version of 10.
To do this, I have built a new server (we need to move infrastructure at the same time), installed gitlab-ce 9.4.5 and then intend to import one of our backups. Our postgres install is on a seperate server. I have copied over gitlab.rb from our current live install and changed the postgres values to the new server, and ensured postgresql['enable'] = false
The config looks like this:
gitlab_rails['db_adapter'] = "postgresql"
gitlab_rails['db_encoding'] = "unicode"
gitlab_rails['db_database'] = "gitlabhq_production"
gitlab_rails['db_pool'] = 10
gitlab_rails['db_username'] = "gitlab"
gitlab_rails['db_password'] = "hunter2"
gitlab_rails['db_host'] = "dbservername.com"
gitlab_rails['db_port'] = 5432
gitlab_rails['db_socket'] = nil
At the point of running gitlab-ctl reconfigure
, it fails with the following:
192.168.1.2 is the (redacted) IP of the gitlab server and not the postgres server, as I would expect. postgres is not installed and it enable is set to false in the config file.
Recipe: gitlab::postgresql_disable
* link[/opt/gitlab/service/postgresql] action delete (up to date)
* directory[/opt/gitlab/sv/postgresql] action delete (up to date)
Recipe: gitlab::database_migrations
* bash[migrate gitlab-rails database] action run
[execute] rake aborted!
PG::ConnectionBad: FATAL: no pg_hba.conf entry for host "192.168.1.2", user "gitlab", database "gitlabhq_production", SSL on
FATAL: no pg_hba.conf entry for host "192.168.1.2", user "gitlab", database "gitlabhq_production", SSL off
/opt/gitlab/embedded/service/gitlab-rails/lib/tasks/gitlab/db.rake:49:in `block (3 levels) in <top (required)>'
/opt/gitlab/embedded/bin/bundle:22:in `load'
/opt/gitlab/embedded/bin/bundle:22:in `<main>'
Tasks: TOP => gitlab:db:configure
(See full trace by running task with --trace)
================================================================================
Error executing action `run` on resource 'bash[migrate gitlab-rails database]'
================================================================================
This also happens if I run gitlab-rake gitlab:setup
and gitlab-rake gitlab:env:info
. If I try to start gitlab, only redis comes up.
I’m at a loss as to why this may be occuring as I can find no trace of any reference to using local postgres in the config, that should be disabled, and it isn’t even installed.
Any help would be greatly appreciated.