1 ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
2 : Copyright (c) 2018 Mirantis Inc., Enea AB and others.
4 : All rights reserved. This program and the accompanying materials
5 : are made available under the terms of the Apache License, Version 2.0
6 : which accompanies this distribution, and is available at
7 : http://www.apache.org/licenses/LICENSE-2.0
8 ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
9 From: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
10 Date: Wed, 22 Aug 2018 01:35:06 +0200
11 Subject: [PATCH] OPNFV package installation, Ubuntu user
13 * Install OpenSSH server (and client), so other OPNFV projects can
14 easily connect to the Salt master node;
15 * Install 'salt-formula-gnocchi' distro package (empty git formula
17 * While at it, create 'ubuntu' user so other OPNFV projects don't
18 have to switch to 'root' login;
20 Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
22 DockerMake.yml | 28 ++++++++++++++++++++++++++++
23 1 file changed, 28 insertions(+)
25 diff --git a/DockerMake.yml b/DockerMake.yml
26 index 2c75586..4883e2c 100644
29 @@ -108,6 +108,34 @@ salt-formulas:
30 && bash -c 'source /srv/salt/formula-fetch.sh && setupPyEnv && fetchAll' \
31 && eval ${LAYER_CLEANUP}
35 + # Some formulas have empty git repos, use the package version
36 + ARG SALT_FORMULA_VERSION="nightly"
37 + ENV SALT_FORMULA_VERSION $SALT_FORMULA_VERSION
38 + ARG SALT_FORMULA_LIST="salt-formula-gnocchi"
39 + ENV SALT_FORMULA_LIST $SALT_FORMULA_LIST
40 + ENV APT_REPOSITORY "deb [arch=amd64] http://apt.mirantis.com/xenial ${SALT_FORMULA_VERSION} salt"
41 + ENV APT_REPOSITORY_GPG "http://apt.mirantis.com/public.gpg"
42 + RUN echo "Layer extra salt-formulas packages" \
43 + && echo "$APT_REPOSITORY" | tee /etc/apt/sources.list.d/salt-formulas.list >/dev/null \
44 + && curl -sL $APT_REPOSITORY_GPG | $SUDO apt-key add - \
45 + && eval ${LAYER_PKGUPDT} \
46 + && ${LAYER_INSTALL} ${SALT_FORMULA_LIST} -y --fix-missing -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" \
47 + && eval ${LAYER_CLEANUP}
48 + RUN echo "Layer with OPNFV packages" \
49 + && eval ${LAYER_PKGUPDT} \
50 + && ${LAYER_INSTALL} \
56 + && useradd -m ubuntu \
57 + && echo 'ubuntu ALL=(ALL) NOPASSWD:ALL' > /etc/sudoers.d/ubuntu \
58 + && eval ${LAYER_CLEANUP}