Commit 6c5599ce85a1a80931e27b421884dc6e7f109abd
1 parent
03481d44
Exists in
master
and in
27 other branches
util/debian-install: fallback to remote packages
Showing
2 changed files
with
9 additions
and
4 deletions
Show diff stats
util/debian-install/Vagrantfile
... | ... | @@ -7,7 +7,8 @@ VAGRANTFILE_API_VERSION = "2" |
7 | 7 | require 'fileutils' |
8 | 8 | debs = `find ../../pkg/ -name '*.deb' | sort -t _ -V | tail -2`.split |
9 | 9 | if debs.empty? |
10 | - puts "W: no debs built in ../../pkg/; will install local ones, or none at all" | |
10 | + puts "W: no debs built in ../../pkg/; will either install existing local" | |
11 | + puts " ones, or the ones from the remote repository" | |
11 | 12 | else |
12 | 13 | local_debs = Dir.glob('*.deb') |
13 | 14 | debs.each do |f| | ... | ... |
util/debian-install/install
... | ... | @@ -69,6 +69,10 @@ apt-get update |
69 | 69 | apt-get dist-upgrade -qy |
70 | 70 | apt-get install -qy postgresql ruby1.8 |
71 | 71 | |
72 | -dpkg --unpack /vagrant/noosfero_*.deb /vagrant/noosfero-apache_*.deb | |
73 | -apt-cache policy noosfero | |
74 | -apt-get install -qyf | |
72 | +if dpkg --unpack /vagrant/noosfero_*.deb /vagrant/noosfero-apache_*.deb; then | |
73 | + apt-cache policy noosfero | |
74 | + apt-get install -qyf | |
75 | +else | |
76 | + apt-cache policy noosfero | |
77 | + apt-get install -qy noosfero noosfero-apache | |
78 | +fi | ... | ... |