summaryrefslogtreecommitdiffstats
path: root/playbooks
diff options
context:
space:
mode:
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/adhoc/uninstall.yml72
-rw-r--r--playbooks/gce/openshift-cluster/tasks/launch_instances.yml2
2 files changed, 44 insertions, 30 deletions
diff --git a/playbooks/adhoc/uninstall.yml b/playbooks/adhoc/uninstall.yml
index cd569937c..789f66b14 100644
--- a/playbooks/adhoc/uninstall.yml
+++ b/playbooks/adhoc/uninstall.yml
@@ -22,6 +22,7 @@
- set_fact:
is_containerized: "{{ is_atomic or containerized | default(false) | bool }}"
+# Stop services on all hosts prior to removing files.
- hosts: nodes
become: yes
tasks:
@@ -35,6 +36,46 @@
- origin-node
failed_when: false
+- hosts: masters
+ become: yes
+ tasks:
+ - name: Stop services
+ service: name={{ item }} state=stopped
+ with_items:
+ - atomic-enterprise-master
+ - atomic-openshift-master
+ - atomic-openshift-master-api
+ - atomic-openshift-master-controllers
+ - openshift-master
+ - openshift-master-api
+ - openshift-master-controllers
+ - origin-master
+ - origin-master-api
+ - origin-master-controllers
+ - pcsd
+ failed_when: false
+
+- hosts: etcd
+ become: yes
+ tasks:
+ - name: Stop services
+ service: name={{ item }} state=stopped
+ with_items:
+ - etcd
+ failed_when: false
+
+- hosts: lb
+ become: yes
+ tasks:
+ - name: Stop services
+ service: name={{ item }} state=stopped
+ with_items:
+ - haproxy
+ failed_when: false
+
+- hosts: nodes
+ become: yes
+ tasks:
- name: unmask services
command: systemctl unmask "{{ item }}"
changed_when: False
@@ -181,6 +222,7 @@
- /etc/systemd/system/openvswitch.service
- /etc/systemd/system/origin-node-dep.service
- /etc/systemd/system/origin-node.service
+ - /etc/systemd/system/origin-node.service.wants
- /run/openshift-sdn
- /var/lib/atomic-enterprise
- /var/lib/openshift
@@ -196,22 +238,6 @@
- hosts: masters
become: yes
tasks:
- - name: Stop services
- service: name={{ item }} state=stopped
- with_items:
- - atomic-enterprise-master
- - atomic-openshift-master
- - atomic-openshift-master-api
- - atomic-openshift-master-controllers
- - openshift-master
- - openshift-master-api
- - openshift-master-controllers
- - origin-master
- - origin-master-api
- - origin-master-controllers
- - pcsd
- failed_when: false
-
- name: unmask services
command: systemctl unmask "{{ item }}"
changed_when: False
@@ -306,12 +332,6 @@
- hosts: etcd
become: yes
tasks:
- - name: Stop services
- service: name={{ item }} state=stopped
- with_items:
- - etcd
- failed_when: false
-
- name: unmask services
command: systemctl unmask "{{ item }}"
changed_when: False
@@ -346,7 +366,7 @@
- /etc/etcd
- /etc/systemd/system/etcd_container.service
- # Intenationally using rm command over file module because if someone had mounted a filesystem
+ # Intenationally using rm command over file module because if someone had mounted a filesystem
# at /var/lib/etcd then the contents was not removed correctly
- name: Remove etcd data
shell: rm -rf /var/lib/etcd/*
@@ -357,12 +377,6 @@
- hosts: lb
become: yes
tasks:
- - name: Stop services
- service: name={{ item }} state=stopped
- with_items:
- - haproxy
- failed_when: false
-
- name: unmask services
command: systemctl unmask "{{ item }}"
changed_when: False
diff --git a/playbooks/gce/openshift-cluster/tasks/launch_instances.yml b/playbooks/gce/openshift-cluster/tasks/launch_instances.yml
index c5c479052..60cf21a5b 100644
--- a/playbooks/gce/openshift-cluster/tasks/launch_instances.yml
+++ b/playbooks/gce/openshift-cluster/tasks/launch_instances.yml
@@ -1,7 +1,7 @@
---
- name: Launch instance(s)
gce:
- instance_names: "{{ instances }}"
+ instance_names: "{{ instances|join(',') }}"
machine_type: "{{ gce_machine_type | default(deployment_vars[deployment_type].machine_type, true) }}"
image: "{{ gce_machine_image | default(deployment_vars[deployment_type].image, true) }}"
service_account_email: "{{ lookup('env', 'gce_service_account_email_address') }}"