Use ansible docker module to remove services

This commit is contained in:
Łukasz Oleś 2015-06-10 12:20:57 +00:00
parent 16dc68ec2f
commit 103561bfdf
5 changed files with 20 additions and 12 deletions

View File

@ -1,6 +1,8 @@
- hosts: [{{ ip }}] - hosts: [{{ ip }}]
sudo: yes sudo: yes
tasks: tasks:
- shell: docker stop {{ name }} - name: glance api container
- shell: docker rm {{ name }} docker:
name: {{ name }}
image: {{ image }}
state: absent

View File

@ -1,6 +1,8 @@
- hosts: [{{ ip }}] - hosts: [{{ ip }}]
sudo: yes sudo: yes
tasks: tasks:
- shell: docker stop {{ name }} - name: glance registry container
- shell: docker rm {{ name }} docker:
name: {{ name }}
image: {{ image }}
state: absent

View File

@ -1,6 +1,8 @@
- hosts: [{{ ip }}] - hosts: [{{ ip }}]
sudo: yes sudo: yes
tasks: tasks:
- shell: docker stop {{ name }} - name: haproxy container
- shell: docker rm {{ name }} docker:
name: {{ name }}
image: {{ image }}
state: absent

View File

@ -2,5 +2,8 @@
- hosts: [{{ ip }}] - hosts: [{{ ip }}]
sudo: yes sudo: yes
tasks: tasks:
- shell: docker stop {{ name }} - name: keystone container
- shell: docker rm {{ name }} docker:
image: {{ image }}
name: {{ name }}
state: absent

View File

@ -1,4 +1,3 @@
# TODO
- hosts: [{{ ip }}] - hosts: [{{ ip }}]
sudo: yes sudo: yes
tasks: tasks: