You are not logged in.
Pages: 1
I've had Gitlab running for quite a few months now and everything has worked great until I was suddenly unable to update the package. I get the following error:
community/gitlab 8.7.0-2 -> 8.8.2-4
......
error: failed to commit transaction (conflicting files)
gitlab-shell: /var/lib/gitlab/.gitconfig exists in filesystem
gitlab-shell: /var/lib/gitlab/.ssh/authorized_keys exists in filesystem
gitlab: /usr/share/webapps/gitlab/config/secrets.yml exists in filesystem
Errors occurred, no packages were upgraded.
I've tried forcing the install but that leaves me with a broken installation. It seems weird having to overwrite secrets.yml and authorized_keys.
Anyone know what the workaround here is?
Cheers!
Last edited by Zygote (2016-06-02 21:20:27)
Offline
Did you check the wiki? https://wiki.archlinux.org/index.php/pa … leshooting
This may be a packaging bug though as you think, since those files look user specific, but I can't say because I don't use gitlab
Offline
Did you check the wiki? https://wiki.archlinux.org/index.php/pa … leshooting
This may be a packaging bug though as you think, since those files look user specific, but I can't say because I don't use gitlab
Yep, I am fully aware of how Pacman handles issues with conflicting files, etc. The problem in this case is that there is seemingly no solution. I suspect there is something wrong with the Gitlab package something the Gitlab wiki page also seems to confirm (Check the notice at the top of the page)
Offline
So for anyone running into the same issue, here is a rough idea of what I did to make the upgrade work. It was quite the hassle actually.
Firstly, rename the following files (just append .bak or something).
/var/lib/gitlab/.gitconfig
/var/lib/gitlab/.ssh/authorized_keys
/usr/share/webapps/gitlab/config/secrets.yml
Then, update gitlab-shell. This messed up permissions in /usr/share/webapps/gitlab and /usr/share/webapps/gitlab-shell so I had to fix those.
chown -R gitlab:gitlab /usr/share/webapps/gitlab
chown -R gitlab:gitlab /usr/share/webapps/gitlab-shell
Then I upgraded the gitlab package.
At this point you'll have to go through /usr/share/webapps/gitlab and /var/lib/gitlab and fix all the symbolic links that now point to files that do not exist. The files you renamed earlier will have to be put in their new designated locations according to the symlinks. When you're certain all files are present and valid, run the migration
su - gitlab -s /bin/sh -c "cd '/usr/share/webapps/gitlab'; bundle-2.1 exec rake db:migrate RAILS_ENV=production"
Then reload and restart the services.
systemctl daemon-reload
systemctl restart gitlab-unicorn gitlab-sidekiq gitlab-workhorse
At this point, Gitlab should be functional again. Upgrading gitlab-workhorse breaks as well and I havent been able to figure out a workaround yet. I will update this post when I do.
Offline
Pages: 1