Skip to content

Commit

Permalink
add flags for rebuilding service containers
Browse files Browse the repository at this point in the history
pmbauer committed Sep 1, 2015
1 parent 07cc1f6 commit 15bd9e7
Showing 4 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions roles/haproxy/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -8,6 +8,8 @@ haproxy_image_tag: latest
# app1.example.com, app2.example.com, etc. set this to 'example.com'
haproxy_domain: example.com

haproxy_rebuild_container: False

consul_template_dir: /mnt/consul-template.d
consul_template_loglevel: debug
consul_backend: consul.service.consul:8500
7 changes: 7 additions & 0 deletions roles/haproxy/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -31,6 +31,13 @@
tags:
- haproxy

- name: destroy old haproxy container
when: haproxy_rebuild_container
docker:
name: haproxy
image: "{{ haproxy_image }}"
state: absent

- name: run haproxy container
docker:
name: haproxy
1 change: 1 addition & 0 deletions roles/marathon/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -12,6 +12,7 @@ marathon_java_settings: '-Xmx512m -Xms512m -XX:+HeapDumpOnOutOfMemoryError'
marathon_artifact_store: 'file:///store'
marathon_artifact_store_dir: '/etc/marathon/store'
marathon_server_zk_group: marathon_servers
marathon_rebuild_container: False
marathon_image: "mesosphere/marathon:v{{ marathon_version }}"
marathon_master_peers: "zk://{{ zookeeper_peers_nodes }}/mesos"
marathon_zk_peers: "zk://{{ zookeeper_peers_nodes }}/marathon"
7 changes: 7 additions & 0 deletions roles/marathon/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -21,6 +21,13 @@
tags:
- marathon

- name: destroy old marathon container
when: marathon_rebuild_container
docker:
name: chronos
image: "{{ marathon_image }}"
state: absent

- name: run marathon container
when: marathon_enabled | bool
docker:

0 comments on commit 15bd9e7

Please sign in to comment.