summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDrew Walters <drewwalters96@gmail.com>2019-01-14 11:34:54 -0600
committerDrew Walters <drewwalters96@gmail.com>2019-01-14 11:36:55 -0600
commitf84d7b3f775dffc171b04d7c7d9811ae67516ed2 (patch)
treece1bf937b092c1d2fe93346021dd40f45efacb19
parenteb325595f5bb6de86e9e6324958902a0fd09b033 (diff)
airskiff: Install AppArmor in package script
This commit moves the installation and enablement of AppArmor to the package installation script. Previously, it was in an additional script where its usage was undocumented, causing confusing deployment errors. Change-Id: I904f87c544f3edb87ce79fd4d16d5f83596317e9
Notes
Notes (review): Code-Review+2: Matt McEuen <matt.mceuen@att.com> Code-Review+2: Kaspars Skels <kaspars.skels@gmail.com> Workflow+1: Kaspars Skels <kaspars.skels@gmail.com> Verified+2: Zuul Submitted-by: Zuul Submitted-at: Wed, 16 Jan 2019 22:34:40 +0000 Reviewed-on: https://review.openstack.org/631318 Project: openstack/airship-treasuremap Branch: refs/heads/master
-rwxr-xr-xtools/deployment/airskiff/developer/000-install-packages.sh5
-rwxr-xr-xtools/deployment/airskiff/developer/001-enable-apparmor.sh26
-rw-r--r--tools/gate/playbooks/airskiff-deploy-gate.yaml7
3 files changed, 5 insertions, 33 deletions
diff --git a/tools/deployment/airskiff/developer/000-install-packages.sh b/tools/deployment/airskiff/developer/000-install-packages.sh
index eb6e25b..1a4bf2d 100755
--- a/tools/deployment/airskiff/developer/000-install-packages.sh
+++ b/tools/deployment/airskiff/developer/000-install-packages.sh
@@ -19,6 +19,7 @@ set -xe
19 19
20sudo apt-get update 20sudo apt-get update
21sudo apt-get install --no-install-recommends -y \ 21sudo apt-get install --no-install-recommends -y \
22 apparmor \
22 ca-certificates \ 23 ca-certificates \
23 git \ 24 git \
24 make \ 25 make \
@@ -42,6 +43,10 @@ sudo apt-add-repository \
42sudo apt-get update 43sudo apt-get update
43sudo apt-get install --no-install-recommends -y docker-ce 44sudo apt-get install --no-install-recommends -y docker-ce
44 45
46# Enable apparmor
47sudo systemctl enable apparmor
48sudo systemctl start apparmor
49
45# Add $USER to docker group 50# Add $USER to docker group
46# NOTE: This requires re-authentication. Restart your shell. 51# NOTE: This requires re-authentication. Restart your shell.
47sudo adduser "$(whoami)" docker 52sudo adduser "$(whoami)" docker
diff --git a/tools/deployment/airskiff/developer/001-enable-apparmor.sh b/tools/deployment/airskiff/developer/001-enable-apparmor.sh
deleted file mode 100755
index 83cc4bd..0000000
--- a/tools/deployment/airskiff/developer/001-enable-apparmor.sh
+++ /dev/null
@@ -1,26 +0,0 @@
1#!/bin/bash
2
3# Copyright 2017 The Openstack-Helm Authors.
4# Copyright 2018 AT&T Intellectual Property. All other rights reserved.
5#
6# Licensed under the Apache License, Version 2.0 (the "License"); you may
7# not use this file except in compliance with the License. You may obtain
8# a copy of the License at
9#
10# http://www.apache.org/licenses/LICENSE-2.0
11#
12# Unless required by applicable law or agreed to in writing, software
13# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
15# License for the specific language governing permissions and limitations
16# under the License.
17
18set -xe
19
20sudo apt-get update
21sudo apt-get install --no-install-recommends -y \
22 apparmor
23
24sudo systemctl enable apparmor
25sudo systemctl start apparmor
26sudo systemctl status apparmor.service
diff --git a/tools/gate/playbooks/airskiff-deploy-gate.yaml b/tools/gate/playbooks/airskiff-deploy-gate.yaml
index 2e80214..d796413 100644
--- a/tools/gate/playbooks/airskiff-deploy-gate.yaml
+++ b/tools/gate/playbooks/airskiff-deploy-gate.yaml
@@ -21,13 +21,6 @@
21 chdir: "{{ zuul.project.src_dir }}" 21 chdir: "{{ zuul.project.src_dir }}"
22 become: yes 22 become: yes
23 23
24 - name: Enable apparmor
25 shell: |
26 ./tools/deployment/airskiff/developer/001-enable-apparmor.sh
27 args:
28 chdir: "{{ zuul.project.src_dir }}"
29 become: yes
30
31 - name: Build Armada 24 - name: Build Armada
32 shell: | 25 shell: |
33 make images 26 make images