From e72bc045fd467a442a0ffb1c78e710a270a59dfa Mon Sep 17 00:00:00 2001 From: grakiss Date: Mon, 15 Feb 2016 22:14:45 -0500 Subject: Support version Liberty of OpenStack for CENTOS7 JIRA:COMPASS-315 -Support version Liberty of OpenStack for CENTOS7 Change-Id: I81abbb37a295a0ea733398ad1f278bafc3525d87 Signed-off-by: grakiss --- .../adapters/ansible/roles/storage/files/storage.service | 15 +++++++++++++++ deploy/adapters/ansible/roles/storage/tasks/main.yml | 7 +++++++ 2 files changed, 22 insertions(+) create mode 100644 deploy/adapters/ansible/roles/storage/files/storage.service (limited to 'deploy/adapters/ansible/roles/storage') diff --git a/deploy/adapters/ansible/roles/storage/files/storage.service b/deploy/adapters/ansible/roles/storage/files/storage.service new file mode 100644 index 00000000..924db25a --- /dev/null +++ b/deploy/adapters/ansible/roles/storage/files/storage.service @@ -0,0 +1,15 @@ +[Unit] +Description=Storage Service +Before=runlevel2.target runlevel3.target runlevel4.target runlevel5.target shutdown.target +After=remote-fs.target nss-lookup.target network-online.target time-sync.target network-online.target net_init.service +Before=ceph.service +Wants=network-online.target +Conflicts=shutdown.target + +[Service] +Type=oneshot +ExecStart=/bin/sh -c "/etc/init.d/storage" + +[Install] +WantedBy=multi-user.target + diff --git a/deploy/adapters/ansible/roles/storage/tasks/main.yml b/deploy/adapters/ansible/roles/storage/tasks/main.yml index 0a27be5d..b48e6769 100755 --- a/deploy/adapters/ansible/roles/storage/tasks/main.yml +++ b/deploy/adapters/ansible/roles/storage/tasks/main.yml @@ -42,6 +42,13 @@ tags: - storage +- name: set autostart file for centos + copy: src=storage.service dest=/usr/lib/systemd/system/storage.service mode=0755 + when: ansible_os_family == "RedHat" + tags: + - storage + + - name: enable service service: name=storage enabled=yes tags: -- cgit 1.2.3-korg