blob: 5738eb8f82146cf7a957981aaa7e89ea022a818d [file] [log] [blame]
Peter Pentchev19473822022-12-12 18:23:59 +02001---
2- name: "Create the spopenstack group"
3 become: true
4 ansible.builtin.group:
5 name: spopenstack
6 system: true
7
8- name: "Add the 'cinder', 'nova', and 'glance' accounts to that group"
9 become: true
10 ansible.builtin.lineinfile:
11 backrefs: true
Peter Pentchev72d02a32022-12-12 20:07:21 +020012 line: "\\g<1>:cinder,nova,glance,stack"
Peter Pentchev19473822022-12-12 18:23:59 +020013 path: /etc/group
14 regexp: "^(spopenstack:[^:]*:[^:]*):$"
15
16- name: "Let's see what we did there..."
17 shell: getent group spopenstack
18
19- name: "Create the /var/spool/openstack-storpool directory"
20 become: true
21 ansible.builtin.file:
22 path: /var/spool/openstack-storpool
23 state: directory
24 owner: root
25 group: spopenstack
26 mode: 0770
27
28- name: "Create the /var/spool/openstack-storpool/openstack-attach.json file"
29 become: true
30 ansible.builtin.copy:
31 dest: /var/spool/openstack-storpool/openstack-attach.json
32 owner: root
33 group: spopenstack
34 mode: 0660
35 content: |
36 {}