Rename tmpfiles.d files

On CentOS /run/lock is created by /usr/lib/tmpfiles.d/legacy.conf file
which can be run after other conf we create for opentack services.
This patch rename the service files to openstack-service.conf to ensure
it is ran after legacy.conf

Change-Id: I2de6d437d6f6aae126deb9e619cd744dfb91eaad
This commit is contained in:
Marc Gariepy 2016-11-10 09:37:36 -05:00 committed by Marc Gariépy
parent 3a640f4845
commit 42cc677ee0
1 changed files with 13 additions and 1 deletions

View File

@ -37,10 +37,22 @@
- group
when: inventory_hostname in groups[item.1]
# TODO(mgariepy):
# Remove this in Pike as it only needed to handle upgrades
# from Newton->Newton and Newton->Ocata
- name: Cleanup old tmpfiles.d entry
file:
path: "{{ item.0.service_name }}.conf"
state: absent
with_subelements:
- "{{ ceilometer_services }}"
- group
when: inventory_hostname in groups[item.1]
- name: Create tmpfiles.d entry
template:
src: "ceilometer-systemd-tmpfiles.j2"
dest: "/etc/tmpfiles.d/{{ item.0.service_name }}.conf"
dest: "/etc/tmpfiles.d/openstack-{{ item.0.service_name }}.conf"
mode: "0644"
owner: "root"
group: "root"