mirror of
https://github.com/davestephens/ansible-nas
synced 2024-12-25 02:53:11 +00:00
add nofile ulimits to time machine docker container
This commit is contained in:
parent
2082d5b3ea
commit
26977cc523
1 changed files with 22 additions and 20 deletions
|
@ -6,34 +6,36 @@
|
||||||
|
|
||||||
- name: Time Machine Docker Container
|
- name: Time Machine Docker Container
|
||||||
docker_container:
|
docker_container:
|
||||||
name: timemachine
|
name: timemachine
|
||||||
image: awlnx/samba-timemachine:latest
|
image: awlnx/samba-timemachine:latest
|
||||||
pull: true
|
pull: true
|
||||||
ports:
|
ports:
|
||||||
- "{{ timemachine_port }}:445"
|
- "{{ timemachine_port }}:445"
|
||||||
env:
|
env:
|
||||||
TMSIZE: "{{ timemachine_volume_size_limit }}"
|
TMSIZE: "{{ timemachine_volume_size_limit }}"
|
||||||
PASS: "{{ timemachine_password }}"
|
PASS: "{{ timemachine_password }}"
|
||||||
SHARENAME: "{{ timemachine_share_name }}"
|
SHARENAME: "{{ timemachine_share_name }}"
|
||||||
volumes:
|
volumes:
|
||||||
- "{{ timemachine_data_directory }}/data:/backups"
|
- "{{ timemachine_data_directory }}/data:/backups"
|
||||||
network_mode: bridge
|
ulimits:
|
||||||
restart_policy: unless-stopped
|
- "nofile:1048576:1048576"
|
||||||
memory: 1g
|
network_mode: bridge
|
||||||
|
restart_policy: unless-stopped
|
||||||
|
memory: 1g
|
||||||
|
|
||||||
- name: Install avahi
|
- name: Install avahi
|
||||||
apt:
|
apt:
|
||||||
name: "avahi-daemon"
|
name: "avahi-daemon"
|
||||||
state: present
|
state: present
|
||||||
register: result
|
register: result
|
||||||
until: result is succeeded
|
until: result is succeeded
|
||||||
|
|
||||||
- name: Setup timemachine service for avahi
|
- name: Setup timemachine service for avahi
|
||||||
template:
|
template:
|
||||||
src: timemachine/timemachine.service
|
src: timemachine/timemachine.service
|
||||||
dest: "/etc/avahi/services/timemachine.service"
|
dest: "/etc/avahi/services/timemachine.service"
|
||||||
|
|
||||||
- name: Reload avahi configuration
|
- name: Reload avahi configuration
|
||||||
service:
|
service:
|
||||||
name: avahi-daemon
|
name: avahi-daemon
|
||||||
state: reloaded
|
state: reloaded
|
||||||
|
|
Loading…
Reference in a new issue