aboutsummaryrefslogtreecommitdiffstats
path: root/mcp/patches/docker/0002-OPNFV-package-installation-Ubuntu-user.patch
blob: e0526c577e13b4e2bba04712fcd126dc05192c34 (plain)
1
2
3

@media only all and (prefers-color-scheme: dark) {
.highlight .hll { background-color: #49483e }
.highlight .c { color: #75715e } /* Comment */
.highlight .err { color: #960050; background-color: #1e0010 } /* Error */
.highlight .k { color: #66d9ef } /* Keyword */
.highlight .l { color: #ae81ff } /* Literal */
.highlight .n { color: #f8f8f2 } /* Name */
.highlight .o { color: #f92672 } /* Operator */
.highlight .p { color: #f8f8f2 } /* Punctuation */
.highlight .ch { color: #75715e } /* Comment.Hashbang */
.highlight .cm { color: #75715e } /* Comment.Multiline */
.highlight .cp { color: #75715e } /* Comment.Preproc */
.highlight .cpf { color: #75715e } /* Comment.PreprocFile */
.highlight .c1 { color: #75715e } /* Comment.Single */
.highlight .cs { color: #75715e } /* Comment.Special */
.highlight .gd { color: #f92672 } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .gi { color: #a6e22e } /* Generic.Inserted */
.highlight .gs { font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #75715e } /* Generic.Subheading */
.highlight .kc { color: #66d9ef } /* Keyword.Constant */
.highlight .kd { color: #66d9ef } /* Keyword.Declaration */
.highlight .kn { color: #f92672 } /* Keyword.Namespace */
.highlight .kp { color: #66d9ef } /* Keyword.Pseudo */
.highlight .kr { color: #66d9ef } /* Keyword.Reserved */
.highlight .kt { color: #66d9ef } /* Keyword.Type */
.highlight .ld { color: #e6db74 } /* Literal.Date */
.highlight .m { color: #ae81ff } /* Literal.Number */
.highlight .s { color: #e6db74 } /* Literal.String */
.highlight .na { color: #a6e22e } /* Name.Attribute */
.highlight .nb { color: #f8f8f2 } /* Name.Builtin */
.highlight .nc { color: #a6e22e } /* Name.Class */
.highlight .no { color: #66d9ef } /* Name.Constant */
.highlight .nd { color: #a6e22e } /* Name.Decorator */
.highlight .ni { color: #f8f8f2 } /* Name.Entity */
.highlight .ne { color: #a6e22e } /* Name.Exception */
.highlight .nf { color: #a6e22e } /* Name.Function */
.highlight .nl { color: #f8f8f2 } /* Name.Label */
.highlight .nn { color: #f8f8f2 } /* Name.Namespace */
.highlight .nx { color: #a6e22e } /* Name.Other */
.highlight .py { color: #f8f8f2 } /* Name.Property */
.highlight .nt { color: #f92672 } /* Name.Tag */
.highlight .nv { color: #f8f8f2 } /* Name.Variable 
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
: Copyright (c) 2018 Mirantis Inc., Enea AB and others.
:
: All rights reserved. This program and the accompanying materials
: are made available under the terms of the Apache License, Version 2.0
: which accompanies this distribution, and is available at
: http://www.apache.org/licenses/LICENSE-2.0
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
From: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
Date: Wed, 22 Aug 2018 01:35:06 +0200
Subject: [PATCH] OPNFV package installation, Ubuntu user

* Install OpenSSH server (and client), so other OPNFV projects can
  easily connect to the Salt master node;
* Install 'salt-formula-gnocchi' distro package (empty git formula
  workaround);
* While at it, create 'ubuntu' user so other OPNFV projects don't
  have to switch to 'root' login;
* Preinstall `salt_minion_dependency_packages` and
  `salt_minion_reclass_dependencies`;

Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
---
 DockerMake.yml | 36 +++++++++++++++++++++++++++++++++++-
 1 file changed, 35 insertions(+), 1 deletion(-)

diff --git a/DockerMake.yml b/DockerMake.yml
index 2c75586..d7d4c49 100644
--- a/DockerMake.yml
+++ b/DockerMake.yml
@@ -102,12 +102,46 @@ salt-formulas:
     ENV SALT_ENV_PATH_ $SALT_ENV_PATH_
     ARG RECLASS_BASE="/srv/salt/reclass"
     ENV RECLASS_BASE $RECLASS_BASE
-    RUN echo "Layer python/salt module prerequisites, formulas" \
+    RUN echo "Layer python/salt module prerequisites, formulas (27 Sep 2018)" \
       && mkdir -p /srv/salt \
       && curl -sSqL https://raw.githubusercontent.com/salt-formulas/salt-formulas-scripts/master/formula-fetch.sh -o /srv/salt/formula-fetch.sh \
       && bash -c 'source /srv/salt/formula-fetch.sh && setupPyEnv && fetchAll' \
       && eval ${LAYER_CLEANUP}

+opnfv:
+  build: |
+    # Some formulas have empty git repos, use the package version
+    ARG SALT_FORMULA_VERSION="nightly"
+    ENV SALT_FORMULA_VERSION $SALT_FORMULA_VERSION
+    ARG SALT_FORMULA_LIST="salt-formula-gnocchi"
+    ENV SALT_FORMULA_LIST $SALT_FORMULA_LIST
+    ENV APT_REPOSITORY "deb [arch=amd64] http://apt.mirantis.com/xenial ${SALT_FORMULA_VERSION} salt"
+    ENV APT_REPOSITORY_GPG "http://apt.mirantis.com/public.gpg"
+    RUN echo "Layer extra salt-formulas packages" \
+      && echo "$APT_REPOSITORY" | tee /etc/apt/sources.list.d/salt-formulas.list >/dev/null \
+      && curl -sL $APT_REPOSITORY_GPG | $SUDO apt-key add - \
+      && eval ${LAYER_PKGUPDT} \
+      && ${LAYER_INSTALL} ${SALT_FORMULA_LIST} -y --fix-missing -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" \
+      && eval ${LAYER_CLEANUP}
+    RUN echo "Layer with OPNFV packages" \
+      && eval ${LAYER_PKGUPDT} \
+      && ${LAYER_INSTALL} \
+           gawk \
+           inetutils-ping \
+           kmod \
+           net-tools \
+           openssh-server \
+           python-m2crypto \
+           python-msgpack \
+           python-netaddr \
+           python-oauth \
+           python-psutil \
+           python-yaml \
+      && useradd -m ubuntu \
+      && echo 'ubuntu ALL=(ALL) NOPASSWD:ALL' > /etc/sudoers.d/ubuntu \
+      && eval ${LAYER_CLEANUP}
+
+
 wheel:
   requires:
     - base