ceph-ansible/roles/ceph-iscsi-gw/tasks/container/containerized.yml

34 lines
790 B
YAML

---
- name: create rbd target log directories
file:
path: '/var/log/{{ item }}'
state: directory
with_items:
- rbd-target-api
- rbd-target-gw
- name: generate systemd unit files for tcmu-runner, rbd-target-api and rbd-target-gw
template:
src: "{{ role_path }}/templates/{{ item }}.service.j2"
dest: /etc/systemd/system/{{ item }}.service
owner: "root"
group: "root"
mode: "0644"
with_items:
- tcmu-runner
- rbd-target-gw
- rbd-target-api
notify: restart ceph {{ item }}
- name: systemd start tcmu-runner, rbd-target-api and rbd-target-gw containers
systemd:
name: "{{ item }}"
state: started
enabled: yes
masked: no
daemon_reload: yes
with_items:
- tcmu-runner
- rbd-target-gw
- rbd-target-api