From e81ddeb685f494bfcfa592212fe8d44c9cc55862 Mon Sep 17 00:00:00 2001 From: Juan Antonio Osorio Robles Date: Thu, 13 Apr 2017 13:46:31 +0000 Subject: Introduce common resources for docker templates This enables common resources that the docker templates might need. The initial resource only is common volumes, and two volumes are introduced (localtime and hosts). Change-Id: Ic55af32803f9493a61f9b57aff849bfc6187d992 --- docker/services/panko-api.yaml | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) (limited to 'docker/services/panko-api.yaml') diff --git a/docker/services/panko-api.yaml b/docker/services/panko-api.yaml index f4f1f7b0..61bdf7ac 100644 --- a/docker/services/panko-api.yaml +++ b/docker/services/panko-api.yaml @@ -29,6 +29,9 @@ parameters: resources: + ContainersCommon: + type: ./containers-common.yaml + PankoApiPuppetBase: type: ../../puppet/services/panko-api.yaml properties: @@ -76,10 +79,13 @@ outputs: detach: false privileged: false volumes: - - /var/lib/config-data/panko/etc/panko:/etc/panko:ro - - /etc/hosts:/etc/hosts:ro - - /etc/localtime:/etc/localtime:ro - - logs:/var/log + yaql: + expression: $.data.common.concat($.data.service) + data: + common: {get_attr: [ContainersCommon, volumes]} + service: + - /var/lib/config-data/panko/etc/panko:/etc/panko:ro + - logs:/var/log command: /usr/bin/panko-dbsync step_4: panko_api: @@ -89,11 +95,14 @@ outputs: privileged: false restart: always volumes: - - /var/lib/kolla/config_files/panko-api.json:/var/lib/kolla/config_files/config.json:ro - - /var/lib/config-data/panko/etc/panko/:/etc/panko/:ro - - /var/lib/config-data/panko/etc/httpd/:/etc/httpd/:ro - - /var/lib/config-data/panko/var/www/:/var/www/:ro - - /etc/hosts:/etc/hosts:ro - - /etc/localtime:/etc/localtime:ro + yaql: + expression: $.data.common.concat($.data.service) + data: + common: {get_attr: [ContainersCommon, volumes]} + service: + - /var/lib/kolla/config_files/panko-api.json:/var/lib/kolla/config_files/config.json:ro + - /var/lib/config-data/panko/etc/panko/:/etc/panko/:ro + - /var/lib/config-data/panko/etc/httpd/:/etc/httpd/:ro + - /var/lib/config-data/panko/var/www/:/var/www/:ro environment: - KOLLA_CONFIG_STRATEGY=COPY_ALWAYS -- cgit 1.2.3-korg