summaryrefslogtreecommitdiffstats
path: root/roles/etcd/tasks/backup/backup.yml
diff options
context:
space:
mode:
authorGiuseppe Scrivano <gscrivan@redhat.com>2017-10-03 21:50:25 +0200
committerGiuseppe Scrivano <gscrivan@redhat.com>2017-10-23 14:20:27 +0200
commit657cf2a8290d7ba1d3307234f7214b09f5fbeb90 (patch)
treea157f9afcde45db4dabac9f84b0d76afa990e06b /roles/etcd/tasks/backup/backup.yml
parent75fc5ef69b792d9595918383286b0d9e45eda848 (diff)
downloadopenshift-657cf2a8290d7ba1d3307234f7214b09f5fbeb90.tar.gz
openshift-657cf2a8290d7ba1d3307234f7214b09f5fbeb90.tar.bz2
openshift-657cf2a8290d7ba1d3307234f7214b09f5fbeb90.tar.xz
openshift-657cf2a8290d7ba1d3307234f7214b09f5fbeb90.zip
etcd: remove hacks for the system container
Use ADDTL_MOUNTS to add a bind mount to the etcd configuration. Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'roles/etcd/tasks/backup/backup.yml')
-rw-r--r--roles/etcd/tasks/backup/backup.yml16
1 files changed, 8 insertions, 8 deletions
diff --git a/roles/etcd/tasks/backup/backup.yml b/roles/etcd/tasks/backup/backup.yml
index ec1a1989c..ca0d29155 100644
--- a/roles/etcd/tasks/backup/backup.yml
+++ b/roles/etcd/tasks/backup/backup.yml
@@ -3,7 +3,7 @@
# TODO: replace shell module with command and update later checks
- name: Check available disk space for etcd backup
- shell: df --output=avail -k {{ l_etcd_data_dir }} | tail -n 1
+ shell: df --output=avail -k {{ etcd_data_dir }} | tail -n 1
register: l_avail_disk
# AUDIT:changed_when: `false` because we are only inspecting
# state, not manipulating anything
@@ -11,7 +11,7 @@
# TODO: replace shell module with command and update later checks
- name: Check current etcd disk usage
- shell: du --exclude='*openshift-backup*' -k {{ l_etcd_data_dir }} | tail -n 1 | cut -f1
+ shell: du --exclude='*openshift-backup*' -k {{ etcd_data_dir }} | tail -n 1 | cut -f1
register: l_etcd_disk_usage
# AUDIT:changed_when: `false` because we are only inspecting
# state, not manipulating anything
@@ -44,17 +44,17 @@
- r_etcd_common_embedded_etcd | bool
- not l_ostree_booted.stat.exists | bool
-- name: Check selinux label of '{{ l_etcd_data_dir }}'
+- name: Check selinux label of '{{ etcd_data_dir }}'
command: >
- stat -c '%C' {{ l_etcd_data_dir }}
+ stat -c '%C' {{ etcd_data_dir }}
register: l_etcd_selinux_labels
- debug:
msg: "{{ l_etcd_selinux_labels }}"
-- name: Make sure the '{{ l_etcd_data_dir }}' has the proper label
+- name: Make sure the '{{ etcd_data_dir }}' has the proper label
command: >
- chcon -t svirt_sandbox_file_t "{{ l_etcd_data_dir }}"
+ chcon -t svirt_sandbox_file_t "{{ etcd_data_dir }}"
when:
- l_etcd_selinux_labels.rc == 0
- "'svirt_sandbox_file_t' not in l_etcd_selinux_labels.stdout"
@@ -68,12 +68,12 @@
# https://github.com/openshift/openshift-docs/commit/b38042de02d9780842dce95cfa0ef45d53b58bc6
- name: Check for v3 data store
stat:
- path: "{{ l_etcd_data_dir }}/member/snap/db"
+ path: "{{ etcd_data_dir }}/member/snap/db"
register: l_v3_db
- name: Copy etcd v3 data store
command: >
- cp -a {{ l_etcd_data_dir }}/member/snap/db
+ cp -a {{ etcd_data_dir }}/member/snap/db
{{ l_etcd_backup_dir }}/member/snap/
when: l_v3_db.stat.exists