forked from uumas/ansible-docker
container: rework bind mount directory permissions, move from volume syntax to mount syntax, add single file template volumes
This commit is contained in:
@@ -57,8 +57,7 @@
|
||||
name: "{{ docker_service_name }}"
|
||||
image: "{{ container_image.image.Id }}"
|
||||
user: "{{ docker_user | default(omit) }}"
|
||||
pull: "{{ dockerfile is not defined }}"
|
||||
volumes: "{{ docker_volume_definition }}"
|
||||
mounts: "{{ docker_volume_definition }}"
|
||||
published_ports: "{{ container_published_ports + docker_published_ports }}"
|
||||
labels: "{{ traefik_labels | default(omit) }}"
|
||||
env: "{{ docker_env | combine(docker_additional_env) }}"
|
||||
@@ -68,11 +67,3 @@
|
||||
networks: "{{ container_networks | default(omit) }}"
|
||||
log_driver: local
|
||||
register: container_out
|
||||
|
||||
- name: "Reset bind mount directory permissions"
|
||||
file:
|
||||
path: "{{ docker_mounts_dir }}/{{ item.name }}"
|
||||
state: directory
|
||||
mode: 0750
|
||||
when: "docker_volume_type == 'bind' and item.name is defined"
|
||||
loop: "{{ final_docker_volumes }}"
|
||||
|
||||
Reference in New Issue
Block a user