spuder / puppet-gitlab

A puppet module to install gitlab 7
Apache License 2.0
36 stars 44 forks source link

gitlab-ce-7.12.0-omnibus.1-1.x86_64.rpm update fails in consecutive puppet runs #162

Closed walidshaari closed 9 years ago

walidshaari commented 9 years ago

i have upgraded from gitlab 7.7.0 to 7.12.0 the first puppet run have the issue of not finding gitlab-ctl, the subsequent ones have the issue of reporting the following:

Error: Could not update: Execution of '/bin/rpm -i /var/tmp/gitlab-ce-7.12.0-omnibus.1-1.x86_64.rpm' returned 1: package gitlab-ce-7.12.0~omnibus.1-1.x86_64 is already installed Error: /Stage[main]/Gitlab::Install/Package[gitlab]/ensure: change from absent to latest failed: Could not update: Execution of '/bin/rpm -i /var/tmp/gitlab-ce-7.12.0-omnibus.1-1.x86_64.rpm' returned 1: package gitlab-ce-7.12.0~omnibus.1-1.x86_64 is already installed

this seems to be related to the pull request "Use the actual file name for the package #154" however the pull request looks only to cover Debian based releases.

a quick fix for me was to add the name attribute to the package in the install.pp as gitlab-ce instead of the assumed gitlab name.

package { 'gitlab': ensure => latest, name => 'gitlab-ce', source => "${download_location}/${omnibus_filename}", provider => $package_manager, require => Exec['download gitlab'], }

spuder commented 9 years ago

Yes this puppet module is currently broken because gitlab changed their package names. I'm trying to fix it and use the package cloud repos, but there is a problem with the package cloud puppet module that needs to be worked around.

walidshaari commented 9 years ago

Unfortunately due to site restrictions, servers are not directly connected to the internet, i am relying on the download_location under /var/tmp using curl in rhel, hope what ever solution still works with this, yum would work just fine for rhel, but as you said the package naming is the issue and needs to be honoured for idempotency

spuder commented 9 years ago

Good to know that offline installs are a wanted feature. I'll see if I can find a way to use packagecloud repos by default , and failback to local deb/rpm

spuder commented 9 years ago

Module transitioned to here: https://github.com/vshn/puppet-gitlab