Remove bootstrap.yml abstraction for haproxy

Change-Id: Ia7328ff96ba22db1b132bfefaa433af9dc666cbf
Partially-Implements: blueprint remove-abstraction-ansible
This commit is contained in:
Sam Yaple 2015-08-13 05:07:01 +00:00
parent 59a2d537e0
commit 061d290e53
2 changed files with 40 additions and 32 deletions

View File

@ -5,23 +5,10 @@ project_name: "haproxy"
####################
# Docker
####################
docker_haproxy_registry: "{{ docker_registry ~ '/' if docker_registry else '' }}"
docker_haproxy_namespace: "{{ docker_namespace }}"
kolla_haproxy_base_distro: "{{ kolla_base_distro }}"
kolla_haproxy_install_type: "{{ kolla_install_type }}"
kolla_haproxy_container_name: "haproxy"
keepalived_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/{{ kolla_base_distro }}-{{ kolla_install_type }}-keepalived"
keepalived_tag: "{{ openstack_release }}"
keepalived_image_full: "{{ keepalived_image }}:{{ keepalived_tag }}"
docker_haproxy_image: "{{ docker_haproxy_registry }}{{ docker_haproxy_namespace }}/{{ kolla_haproxy_base_distro }}-{{ kolla_haproxy_install_type }}-{{ kolla_haproxy_container_name }}"
docker_haproxy_tag: "{{ openstack_release }}"
docker_haproxy_image_full: "{{ docker_haproxy_image }}:{{ docker_haproxy_tag }}"
docker_keepalived_registry: "{{ docker_registry ~ '/' if docker_registry else '' }}"
docker_keepalived_namespace: "{{ docker_namespace }}"
kolla_keepalived_base_distro: "{{ kolla_base_distro }}"
kolla_keepalived_install_type: "{{ kolla_install_type }}"
kolla_keepalived_container_name: "keepalived"
docker_keepalived_image: "{{ docker_keepalived_registry }}{{ docker_keepalived_namespace }}/{{ kolla_keepalived_base_distro }}-{{ kolla_keepalived_install_type }}-{{ kolla_keepalived_container_name }}"
docker_keepalived_tag: "{{ openstack_release }}"
docker_keepalived_image_full: "{{ docker_keepalived_image }}:{{ docker_keepalived_tag }}"
haproxy_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/{{ kolla_base_distro }}-{{ kolla_install_type }}-haproxy"
haproxy_tag: "{{ openstack_release }}"
haproxy_image_full: "{{ haproxy_image }}:{{ haproxy_tag }}"

View File

@ -1,23 +1,44 @@
---
- include: ../../start.yml
vars:
container_image: "{{ docker_keepalived_image_full }}"
container_name: "keepalived"
container_privileged: "True"
container_volumes:
- name: Starting keepalived container
docker:
docker_api_version: "{{ docker_api_version }}"
net: host
pull: "{{ docker_pull_policy }}"
restart_policy: "{{ docker_restart_policy }}"
restart_policy_retry: "{{ docker_restart_policy_retry }}"
state: reloaded
registry: "{{ docker_registry }}"
username: "{{ docker_registry_username }}"
password: "{{ docker_registry_password }}"
insecure_registry: "{{ docker_insecure_registry }}"
name: keepalived
image: "{{ keepalived_image_full }}"
privileged: True
volumes:
- "{{ node_config_directory }}/keepalived/:/opt/kolla/keepalived/:ro"
- "/run:/run"
container_environment:
env:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
- include: ../../start.yml
vars:
container_image: "{{ docker_haproxy_image_full }}"
container_name: "haproxy"
container_volumes:
- name: Starting HAProxy container
docker:
docker_api_version: "{{ docker_api_version }}"
net: host
pull: "{{ docker_pull_policy }}"
restart_policy: "{{ docker_restart_policy }}"
restart_policy_retry: "{{ docker_restart_policy_retry }}"
state: reloaded
registry: "{{ docker_registry }}"
username: "{{ docker_registry_username }}"
password: "{{ docker_registry_password }}"
insecure_registry: "{{ docker_insecure_registry }}"
name: haproxy
image: "{{ haproxy_image_full }}"
privileged: True
volumes:
- "{{ node_config_directory }}/haproxy/:/opt/kolla/haproxy/:ro"
- "/run:/run"
container_environment:
env:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
- name: Ensuring latest haproxy config is used