25 lines
517 B
YAML
25 lines
517 B
YAML
---
|
|
- name: Always End Session
|
|
block:
|
|
|
|
|
|
- name: Start Session
|
|
ansible.builtin.include_tasks:
|
|
file: api/session-create.yaml
|
|
when: glpi.api.session | default('') == ''
|
|
|
|
|
|
- name: Append/Create Item
|
|
ansible.builtin.include_tasks:
|
|
file: append-create-item.yaml
|
|
loop: "{{ glpi_config_as_code_json }}"
|
|
|
|
|
|
always:
|
|
|
|
|
|
- name: End Session
|
|
ansible.builtin.include_tasks:
|
|
file: api/session-end.yaml
|
|
when: glpi_session_get.status | default(0) | int == 200
|