Bug #2761
closedUpgrade to foreman-1.2 on debian: postinsts problem
Description
Hello,
I just upgraded from foreman-1.1 to 1.2 using the deb.theforeman.org repository.
I get a nice problem with the dpkg --configure foreman process: the /var/lib/dpkg/info/foreman.postinst seems to be missing some important command, like "bundle update rails".
How to reproduce:
- be sure to get foreman-1.1 installed
- upgrade it
- you'll see an error for the dpkg --configure foreman (post-install instructions)
Workaround:
- go to /usr/share/foreman
- run bundle update rails (may take a while)
- run dpkg --configure -a
This corrected the foreman installation - it may be good to add this bundle command to the foreman.postinst file, like:
cd /usr/share/foreman + bundle update rails if [ -f Gemfile.lock ]; then CMD="bundle update --local" else CMD="bundle install --path ./vendor/ --local --no-prune" fi
This may help other people wanting to update the foreman smoothly.
Cheers,
C.
Updated by Dominic Cleal over 11 years ago
- Project changed from Foreman to Packaging
Updated by Greg Sutcliffe over 11 years ago
- Status changed from New to Assigned
- Assignee set to Greg Sutcliffe
I'll try to reproduce later this week, probably Friday, but it shouldn't be necessary
Updated by Greg Sutcliffe over 11 years ago
I'm assuming you're on Squeeze (Wheezy doesn't have 1.1 packages). I can't replicate this on Squeeze with your method, my exactly commands were:
# facter operatingsystemrelease 6.0.7 # apt-get install foreman=1.1.1+debian1 [finishes ok] # apt-get install foreman-sqlite3=1.1.1+debian1 [finishes ok] # vi /etc/default/foreman [enable webrick] # /etc/init.d/foreman start [start webrick, web UI loads fine, version confirmed as 1.1-1] # DEBUG=1 apt-get dist-upgrade [finishes fine, UI confirms version is now 1.2.0]
I can only conclude there was something odd about your 1.1 install - can we close this, or is there more testing you'd like to try?
Updated by Greg Sutcliffe over 11 years ago
- Status changed from Assigned to Feedback
Updated by Cédric Jeanneret over 11 years ago
Hello Greg,
Hmm, you're probably right - I didn't install the 1.1 version (some colleague did it). Maybe there was some weird stuff.
I propose we close this report, as I'm on my side unable to provide more information about the (now migrated) 1.1 setup (it's a wheezy, there was the 1.1 on it some weeks/months ago).
Maybe someone else will hit this problem as well (hopefully not ;) ).
Cheers,
C.
Updated by Greg Sutcliffe over 11 years ago
- Status changed from Feedback to Closed
Potentially a 1.1-wheezy-using-squeeze-packages setup or something else odd. Thanks for the clarification, closing this one.