diff --git a/roles/cassandra/tasks/main.yml b/roles/cassandra/tasks/main.yml index df00309..1c1cad5 100644 --- a/roles/cassandra/tasks/main.yml +++ b/roles/cassandra/tasks/main.yml @@ -7,9 +7,14 @@ mode: 644 owner: root group: root + - name: install service file command: systemctl daemon-reload + - name: make sure service is started systemd: name: cassandra.service state: started + +- name: start service at boot. + command: systemctl reenable cassandra.service diff --git a/roles/cinder-controller/tasks/main.yml b/roles/cinder-controller/tasks/main.yml index b9fe54f..5da9329 100644 --- a/roles/cinder-controller/tasks/main.yml +++ b/roles/cinder-controller/tasks/main.yml @@ -43,6 +43,9 @@ owner: root group: root +- name: start service at boot. + command: systemctl reenable cinder-controller.service + - command: systemctl daemon-reload - name: Initialize database. diff --git a/roles/cinder-storage/tasks/main.yml b/roles/cinder-storage/tasks/main.yml index 2ed2df2..8743975 100644 --- a/roles/cinder-storage/tasks/main.yml +++ b/roles/cinder-storage/tasks/main.yml @@ -55,6 +55,9 @@ - command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable cinder-storage.service + - name: make sure service is started systemd: name: cinder-storage.service diff --git a/roles/dockerregistry/tasks/main.yml b/roles/dockerregistry/tasks/main.yml index 489f8b4..ec21d32 100644 --- a/roles/dockerregistry/tasks/main.yml +++ b/roles/dockerregistry/tasks/main.yml @@ -7,13 +7,18 @@ mode: 644 owner: root group: root + - name: install service file command: systemctl daemon-reload + - name: make sure service is started systemd: name: dockerregistry.service state: started +- name: start service at boot. + command: systemctl reenable dockerregistry.service + - name: Copy certificates and passwd file copy: src: "{{ item }}" diff --git a/roles/glance-controller/tasks/main.yml b/roles/glance-controller/tasks/main.yml index 6b45df2..058d150 100644 --- a/roles/glance-controller/tasks/main.yml +++ b/roles/glance-controller/tasks/main.yml @@ -42,6 +42,9 @@ owner: root group: root +- name: start service at boot. + command: systemctl reenable glance.service + - command: systemctl daemon-reload - name: Initialize database. diff --git a/roles/horizon/tasks/main.yml b/roles/horizon/tasks/main.yml index fe16f94..279c87c 100644 --- a/roles/horizon/tasks/main.yml +++ b/roles/horizon/tasks/main.yml @@ -19,6 +19,9 @@ - command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable horizon.service + - name: make sure service is started systemd: name: horizon.service diff --git a/roles/keystone/tasks/main.yml b/roles/keystone/tasks/main.yml index 41cca97..eb8a4d6 100644 --- a/roles/keystone/tasks/main.yml +++ b/roles/keystone/tasks/main.yml @@ -36,6 +36,9 @@ - name: install service file command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable keystone.service + - name: Initialize db script: scripts/initialize_db.sh environment: diff --git a/roles/mariadb/tasks/main.yml b/roles/mariadb/tasks/main.yml index b3c6ac4..002fdbb 100644 --- a/roles/mariadb/tasks/main.yml +++ b/roles/mariadb/tasks/main.yml @@ -13,6 +13,9 @@ owner: root group: root +- name: start service at boot. + command: systemctl reenable mysql.service + - name: make mariadb settings volume file: path: "{{ item }}" diff --git a/roles/memcached/tasks/main.yml b/roles/memcached/tasks/main.yml index c46c616..2606ae2 100644 --- a/roles/memcached/tasks/main.yml +++ b/roles/memcached/tasks/main.yml @@ -7,8 +7,13 @@ mode: 644 owner: root group: root + - name: install service file command: systemctl daemon-reload + +- name: start service at boot. + command: systemctl reenable memcached.service + - name: make sure service is started systemd: name: memcached.service diff --git a/roles/neutron-controller/tasks/main.yml b/roles/neutron-controller/tasks/main.yml index 097cbfc..b14e101 100644 --- a/roles/neutron-controller/tasks/main.yml +++ b/roles/neutron-controller/tasks/main.yml @@ -45,6 +45,9 @@ - command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable neutron-controller.service + - name: Initialize neutron command: > /usr/bin/docker run --rm diff --git a/roles/nova-compute/tasks/main.yml b/roles/nova-compute/tasks/main.yml index 8a23b26..d34b1dd 100644 --- a/roles/nova-compute/tasks/main.yml +++ b/roles/nova-compute/tasks/main.yml @@ -38,6 +38,9 @@ name: nova-compute.service state: restarted +- name: start service at boot. + command: systemctl reenable nova-compute.service + - name: let nova controler discover new host command: docker exec -i nova-controller.service nova-manage cell_v2 discover_hosts delegate_to: "{{ hostvars[groups['nova-controller'][0]]['ansible_hostname'] }}" diff --git a/roles/nova-controller/tasks/main.yml b/roles/nova-controller/tasks/main.yml index b5865f9..d6d12f6 100644 --- a/roles/nova-controller/tasks/main.yml +++ b/roles/nova-controller/tasks/main.yml @@ -52,6 +52,9 @@ - command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable nova-controller.service + - name: Initialize database. command: > /usr/bin/docker run --rm diff --git a/roles/rabbitmq/tasks/main.yml b/roles/rabbitmq/tasks/main.yml index ef7ad17..00d18d7 100644 --- a/roles/rabbitmq/tasks/main.yml +++ b/roles/rabbitmq/tasks/main.yml @@ -19,6 +19,9 @@ - name: install service file command: systemctl daemon-reload +- name: start service at boot. + command: systemctl reenable rabbitmq.service + - name: make sure service is started systemd: name: rabbitmq.service