Upgrade from docker image 14.3.3 to 14.4.0 fails during migration step

Today I did what I always do to upgrade Gitlab (using docker-compose):

docker pull gitlab/gitlab-ce:latest
docker-compose up -d

After waiting about 5 minutes, I still wasn’t able to access Gitlab (proxy shows 502 bad gateway) so I checked the docker container logs which get to the migration step, then end with a lot of output that I do not understand, and the final line is this:

Chef Infra Client failed. 11 resources updated in 30 seconds

The container keeps restarting and failing in the same way in an infinite loop. Are there special considerations for upgrading to 14.4.0, or something else I can look for?

Luckily going back to 14.3.3 works fine so I’ll hang tight until I find out more.

I was experiencing this issue: Gitlab 14.4 upgrade fails "PG::InvalidObjectDefinition: ERROR: functions in index predicate must be marked IMMUTABLE" (#343694) · Issues · GitLab.org / GitLab · GitLab

Resolved by running gitlab-psql and adding the index:

CREATE INDEX CONCURRENTLY index_issue_metrics_first_mentioned_in_commit ON issue_metrics(issue_id) WHERE EXTRACT(YEAR FROM first_mentioned_in_commit_at at time zone 'UTC') > 2019;
1 Like

Thanks a lot, I had the same issue and this query resolved the problem during update.