service: Validation, set default for mounts in additional containers
This commit is contained in:
@@ -1,4 +1,9 @@
|
|||||||
---
|
---
|
||||||
|
- name: Fail if service_name is empty
|
||||||
|
ansible.builtin.fail:
|
||||||
|
msg: service_name must not be empty
|
||||||
|
when: service_name | length == 0
|
||||||
|
|
||||||
- name: Fail if service_container_user is not string
|
- name: Fail if service_container_user is not string
|
||||||
ansible.builtin.fail:
|
ansible.builtin.fail:
|
||||||
msg: "service_container_user must be a string, not int."
|
msg: "service_container_user must be a string, not int."
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ _service_all_template_mounts: >-
|
|||||||
_service_template_mounts +
|
_service_template_mounts +
|
||||||
(
|
(
|
||||||
_service_additional_containers |
|
_service_additional_containers |
|
||||||
map(attribute='mounts') |
|
map(attribute='mounts', default=[]) |
|
||||||
flatten
|
flatten
|
||||||
)
|
)
|
||||||
) |
|
) |
|
||||||
|
|||||||
Reference in New Issue
Block a user