Commit ac4feafe authored by Dimitris Aragiorgis's avatar Dimitris Aragiorgis

deploy/ci: Fix package installation process

When local packages are used (use_local_packages = True in
deploy.conf) we do:

 dpkg -i <local_package.deb> || apt-get install -f

The first command leaves a broken package while the latter fixes it.
For some reason this DOES upgrade the installed packages that the
broken one depends on. To bypass this strange behavior,
after dpkg -i we run apt-mark hold.

Additionally remove any dependencies in all components in order
to check if control files are generated properly. Leave only
python-svipc for ArchipSynnefo and memcached in Cyclades.

Install snf-image 0.14 that does still work with nfs and does not
require a rados backend.

Rename WEB to Webproject.
Signed-off-by: default avatarDimitris Aragiorgis <dimara@grnet.gr>
parent 39ade0fa
......@@ -2,5 +2,8 @@
python-nfqueue = 0.4+physindev-1~wheezy
python-scapy = 2.2.0+rfc6355-1
blktap-utils = 2.0.90next~21~3a70c2f~1452b09-1
libcurl4-openssl-dev = 7.26.0-1+wheezy9
curl = 7.26.0-1+wheezy9
snf-image = 0.14-1~wheezy
[ubuntu]
......@@ -4,5 +4,6 @@ python-scapy = 2.2.0+rfc6355-1
blktap-utils = 2.0.90next~21~3a70c2f~1452b09-1
libcurl4-openssl-dev = 7.26.0-1+wheezy9
curl = 7.26.0-1+wheezy9
snf-image = 0.14-1~wheezy
[ubuntu]
......@@ -186,7 +186,12 @@ class ComponentRunner(FabricRunner):
self._debug(" * Package %s found in %s..."
% (package, config.package_dir))
self.put(deb, "/tmp/%s" % f)
self.run("dpkg -i /tmp/%s || " % f + apt_get + "-f")
cmd = """
dpkg -i /tmp/{0}
{2} -f
apt-mark hold {1}
""".format(f, package, apt_get)
self.run(cmd)
self.run("rm /tmp/%s" % f)
return
......
......@@ -880,11 +880,7 @@ class Gunicorn(base.Component):
class Common(base.Component):
REQUIRED_PACKAGES = [
# snf-common
"python-objpool",
"snf-common",
"python-astakosclient",
"snf-django-lib",
"snf-branding",
]
......@@ -910,12 +906,11 @@ class Common(base.Component):
]
class WEB(base.Component):
class Webproject(base.Component):
REQUIRED_PACKAGES = [
"python-astakosclient",
"snf-django-lib",
"snf-webproject",
"python-psycopg2",
"python-gevent",
"python-django",
]
@base.run_cmds
......@@ -943,17 +938,14 @@ class WEB(base.Component):
class Astakos(base.Component):
REQUIRED_PACKAGES = [
"python-django-south",
"snf-astakos-app",
"kamaki",
"python-openssl",
]
alias = constants.ASTAKOS
service = constants.ASTAKOS
def required_components(self):
return [HW, SSH, DNS, APT, Apache, Gunicorn, Common, WEB]
return [HW, SSH, DNS, APT, Apache, Gunicorn, Common, Webproject]
@base.run_cmds
def setup_user(self):
......@@ -1121,14 +1113,13 @@ class Astakos(base.Component):
class CMS(base.Component):
REQUIRED_PACKAGES = [
"snf-cloudcms"
"python-openssl",
]
alias = constants.CMS
service = constants.CMS
def required_components(self):
return [HW, SSH, DNS, APT, Apache, Gunicorn, Common, WEB]
return [HW, SSH, DNS, APT, Apache, Gunicorn, Common, Webproject]
@update_admin
def admin_pre(self):
......@@ -1258,11 +1249,8 @@ EOF
class Pithos(base.Component):
REQUIRED_PACKAGES = [
"kamaki",
"python-svipc",
"snf-pithos-app",
"snf-pithos-webclient",
"python-openssl",
]
alias = constants.PITHOS
......@@ -1270,7 +1258,7 @@ class Pithos(base.Component):
def required_components(self):
return [
HW, SSH, DNS, APT, Apache, Gunicorn, Common, WEB,
HW, SSH, DNS, APT, Apache, Gunicorn, Common, Webproject,
PithosBackend, Archip, ArchipSynnefo
]
......@@ -1353,10 +1341,7 @@ class Cyclades(base.Component):
REQUIRED_PACKAGES = [
"memcached",
"python-memcache",
"kamaki",
"snf-cyclades-app",
"python-django-south",
"python-openssl",
]
alias = constants.CYCLADES
......@@ -1365,7 +1350,7 @@ class Cyclades(base.Component):
def required_components(self):
return [
HW, SSH, DNS, APT,
Apache, Gunicorn, Common, WEB, VNC, PithosBackend,
Apache, Gunicorn, Common, Webproject, VNC, PithosBackend,
Archip, ArchipSynnefo
]
......@@ -1614,7 +1599,6 @@ class Kamaki(base.Component):
class Burnin(base.Component):
REQUIRED_PACKAGES = [
"kamaki",
"snf-tools",
]
......@@ -1646,7 +1630,7 @@ class Stats(base.Component):
def required_components(self):
return [
HW, SSH, DNS, APT,
Apache, Gunicorn, Common, WEB, Collectd
Apache, Gunicorn, Common, Webproject, Collectd
]
@update_admin
......@@ -1725,6 +1709,9 @@ class Archip(base.Component):
class ArchipSynnefo(base.Component):
REQUIRED_PACKAGES = [
"python-svipc",
]
def _configure(self):
r1 = {"HOST": self.node.fqdn}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment