summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenny Woodson <kwoodson@redhat.com>2017-10-25 14:04:51 -0400
committerKenny Woodson <kwoodson@redhat.com>2017-10-25 14:04:51 -0400
commit23c370fd192b374eacc893b08bb090933b277522 (patch)
treea743861671c5a40af136e9d2a731384d580d1205
parent3dea8bceeb98d5a30f0223f7109cc78caa3a6b8f (diff)
downloadopenshift-23c370fd192b374eacc893b08bb090933b277522.tar.gz
openshift-23c370fd192b374eacc893b08bb090933b277522.tar.bz2
openshift-23c370fd192b374eacc893b08bb090933b277522.tar.xz
openshift-23c370fd192b374eacc893b08bb090933b277522.zip
Moving removal of unwanted artifacts to image_prep.
-rw-r--r--playbooks/common/openshift-node/clean_image.yml10
-rw-r--r--playbooks/common/openshift-node/image_prep.yml3
-rw-r--r--roles/openshift_aws/tasks/seal_ami.yml7
3 files changed, 13 insertions, 7 deletions
diff --git a/playbooks/common/openshift-node/clean_image.yml b/playbooks/common/openshift-node/clean_image.yml
new file mode 100644
index 000000000..38753d0af
--- /dev/null
+++ b/playbooks/common/openshift-node/clean_image.yml
@@ -0,0 +1,10 @@
+---
+- name: Configure nodes
+ hosts: oo_nodes_to_config:!oo_containerized_master_nodes
+ tasks:
+ - name: Remove any ansible facts created during AMI creation
+ file:
+ path: "/etc/ansible/facts.d/{{ item }}"
+ state: absent
+ with_items:
+ - openshift.fact
diff --git a/playbooks/common/openshift-node/image_prep.yml b/playbooks/common/openshift-node/image_prep.yml
index 00d167c22..30651a1df 100644
--- a/playbooks/common/openshift-node/image_prep.yml
+++ b/playbooks/common/openshift-node/image_prep.yml
@@ -19,3 +19,6 @@
- name: Re-enable excluders
include: enable_excluders.yml
+
+- name: Remove any undesired artifacts from build
+ include: clean_image.yml
diff --git a/roles/openshift_aws/tasks/seal_ami.yml b/roles/openshift_aws/tasks/seal_ami.yml
index d319fdd1a..0cb749dcc 100644
--- a/roles/openshift_aws/tasks/seal_ami.yml
+++ b/roles/openshift_aws/tasks/seal_ami.yml
@@ -1,11 +1,4 @@
---
-- name: Remove any ansible facts created during AMI creation
- file:
- path: "/etc/ansible/facts.d/{{ item }}"
- state: absent
- with_items:
- - openshift.fact
-
- name: fetch newly created instances
ec2_remote_facts:
region: "{{ openshift_aws_region }}"