mirror of
https://github.com/davestephens/ansible-nas
synced 2024-12-25 02:53:11 +00:00
Move netbootxyz to role
This commit is contained in:
parent
8b55e4aa51
commit
25f9c992fd
2 changed files with 27 additions and 6 deletions
20
roles/netbootxyz/defaults/main.yml
Normal file
20
roles/netbootxyz/defaults/main.yml
Normal file
|
@ -0,0 +1,20 @@
|
|||
---
|
||||
netbootxyz_enabled: false
|
||||
netbootxyz_available_externally: "false"
|
||||
|
||||
# directories
|
||||
netbootxyz_config_directory: "{{ docker_home }}/netbootxyz/config"
|
||||
netbootxyz_assets_directory: "{{ docker_home }}/netbootxyz/assets"
|
||||
|
||||
# network
|
||||
netbootxyz_hostname: netbootxyz
|
||||
netbootxyz_port_http: "3002"
|
||||
netbootxyz_port_http2: "5803"
|
||||
netbootxyz_port_tftp: "69"
|
||||
|
||||
# uid/gid
|
||||
netbootxyz_user_id: "1000"
|
||||
netbootxyz_group_id: "1000"
|
||||
|
||||
# specs
|
||||
netbootxyz_memory: 1g
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
---
|
||||
- name: netbootxyz Directory
|
||||
file:
|
||||
|
@ -20,14 +19,16 @@
|
|||
- "{{ netbootxyz_port_http }}:3000"
|
||||
- "{{ netbootxyz_port_http2 }}:80"
|
||||
- "{{ netbootxyz_port_tftp }}:69/udp"
|
||||
memory: "{{ netbootxyz_memory }}"
|
||||
env:
|
||||
TZ: "{{ ansible_nas_timezone }}"
|
||||
PUID: "{{ netbootxyz_user_id }}"
|
||||
PGID: "{{ netbootxyz_group_id }}"
|
||||
restart_policy: unless-stopped
|
||||
labels:
|
||||
traefik.backend: "netbootxyz"
|
||||
traefik.frontend.rule: "Host:netbootxyz.{{ ansible_nas_domain }}"
|
||||
traefik.enable: "{{ netbootxyz_available_externally }}"
|
||||
traefik.port: "80"
|
||||
memory: 1g
|
||||
traefik.enable: "{{ netbootxyz_externally }}"
|
||||
traefik.http.routers.netdata.rule: "Host(`{{ netbootxyz_hostname }}.{{ ansible_nas_domain }}`)"
|
||||
traefik.http.routers.netdata.tls.certresolver: "letsencrypt"
|
||||
traefik.http.routers.netdata.tls.domains[0].main: "{{ ansible_nas_domain }}"
|
||||
traefik.http.routers.netdata.tls.domains[0].sans: "*.{{ ansible_nas_domain }}"
|
||||
traefik.http.services.netdata.loadbalancer.server.port: "80"
|
||||
|
|
Loading…
Reference in a new issue