From 5ab3e6565e5fa13f3ef1972c5c59647f61c69e6c Mon Sep 17 00:00:00 2001 From: Egon Rijpkema Date: Mon, 17 Sep 2018 13:40:50 +0200 Subject: [PATCH] Make systemd unit file install .. without running other tasks --- cinder-controller.yml | 2 ++ roles/cinder-controller/tasks/main.yml | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/cinder-controller.yml b/cinder-controller.yml index ce6f7e9..d1dd124 100644 --- a/cinder-controller.yml +++ b/cinder-controller.yml @@ -2,6 +2,8 @@ - hosts: all name: Dummy to gather facts tasks: [] + tags: + - facts - hosts: cinder-controller become: True diff --git a/roles/cinder-controller/tasks/main.yml b/roles/cinder-controller/tasks/main.yml index 30e8eac..5f65fca 100644 --- a/roles/cinder-controller/tasks/main.yml +++ b/roles/cinder-controller/tasks/main.yml @@ -4,6 +4,8 @@ include_vars: file: ../../secrets.yml name: secrets + tags: + - facts - set_fact: docker_image: registry.webhosting.rug.nl/hpc/openstack-cinder-controller:latest @@ -21,6 +23,8 @@ -e "RABBIT_PASSWORD={{ secrets['RABBIT_PASSWORD'] }}" -e "RABBIT_USER=openstack" -e "RBD_SECRET_UUID={{ secrets['CINDER_RBD_SECRET_UUID']}}" + tags: + - facts - name: pull docker image docker_image: @@ -43,11 +47,17 @@ mode: 644 owner: root group: root + tags: + - systemd - name: start service at boot. command: systemctl reenable cinder-controller.service + tags: + - systemd - command: systemctl daemon-reload + tags: + - systemd - name: Initialize database. command: >