Move traefik into its own role
This commit is contained in:
parent
9962d9103f
commit
89ba23719c
9 changed files with 14 additions and 23 deletions
|
@ -1,2 +1,6 @@
|
||||||
|
docker_user:
|
||||||
|
id: 3000
|
||||||
|
name: dockeruser
|
||||||
|
|
||||||
docker_compose_file_mask: 0664
|
docker_compose_file_mask: 0664
|
||||||
docker_compose_directory_mask: 0775
|
docker_compose_directory_mask: 0775
|
|
@ -21,4 +21,5 @@
|
||||||
docker_users:
|
docker_users:
|
||||||
- "{{ user }}"
|
- "{{ user }}"
|
||||||
- docker-cleanup
|
- docker-cleanup
|
||||||
|
- traefik
|
||||||
- docker
|
- docker
|
||||||
|
|
|
@ -1,6 +1,3 @@
|
||||||
- name: Include docker variables
|
|
||||||
include_vars: docker.yml
|
|
||||||
|
|
||||||
- name: Install docker-compose
|
- name: Install docker-compose
|
||||||
apt:
|
apt:
|
||||||
name: docker-compose
|
name: docker-compose
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
docker_user:
|
|
||||||
id: 3000
|
|
||||||
name: dockeruser
|
|
|
@ -1,8 +1,3 @@
|
||||||
- name: Include docker variables
|
|
||||||
include_vars: docker.yml
|
|
||||||
|
|
||||||
# Applications
|
|
||||||
|
|
||||||
- name: Install calibre
|
- name: Install calibre
|
||||||
include: calibre.yml
|
include: calibre.yml
|
||||||
|
|
||||||
|
@ -51,9 +46,6 @@
|
||||||
- name: Install theorangeone.net
|
- name: Install theorangeone.net
|
||||||
include: theorangeone.net.yml
|
include: theorangeone.net.yml
|
||||||
|
|
||||||
- name: Install traefik
|
|
||||||
include: traefik.yml
|
|
||||||
|
|
||||||
- name: Install tt-rss
|
- name: Install tt-rss
|
||||||
include: tt-rss.yml
|
include: tt-rss.yml
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
- name: Create traefik directory
|
- name: Create install directory
|
||||||
file:
|
file:
|
||||||
path: /opt/traefik
|
path: /opt/traefik
|
||||||
state: directory
|
state: directory
|
||||||
|
@ -6,16 +6,16 @@
|
||||||
mode: "{{ docker_compose_directory_mask }}"
|
mode: "{{ docker_compose_directory_mask }}"
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Create traefik config directory
|
- name: Create config directory
|
||||||
file:
|
file:
|
||||||
path: /opt/traefik/traefik
|
path: /opt/traefik/traefik
|
||||||
state: directory
|
state: directory
|
||||||
mode: "{{ docker_compose_directory_mask }}"
|
mode: "{{ docker_compose_directory_mask }}"
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Install traefik compose file
|
- name: Install compose file
|
||||||
template:
|
template:
|
||||||
src: files/traefik/docker-compose.yml
|
src: files/docker-compose.yml
|
||||||
dest: /opt/traefik/docker-compose.yml
|
dest: /opt/traefik/docker-compose.yml
|
||||||
mode: "{{ docker_compose_file_mask }}"
|
mode: "{{ docker_compose_file_mask }}"
|
||||||
owner: "{{ docker_user.name }}"
|
owner: "{{ docker_user.name }}"
|
||||||
|
@ -23,25 +23,25 @@
|
||||||
register: compose_file
|
register: compose_file
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Install traefik config
|
- name: Install config
|
||||||
template:
|
template:
|
||||||
src: files/traefik/traefik.yml
|
src: files/traefik.yml
|
||||||
dest: /opt/traefik/traefik/traefik.yml
|
dest: /opt/traefik/traefik/traefik.yml
|
||||||
mode: "{{ docker_compose_file_mask }}"
|
mode: "{{ docker_compose_file_mask }}"
|
||||||
owner: "{{ docker_user.name }}"
|
owner: "{{ docker_user.name }}"
|
||||||
register: config_file
|
register: config_file
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Install traefik file provider
|
- name: Install file provider
|
||||||
template:
|
template:
|
||||||
src: files/traefik/file-provider.yml
|
src: files/file-provider.yml
|
||||||
dest: /opt/traefik/traefik/file-provider.yml
|
dest: /opt/traefik/traefik/file-provider.yml
|
||||||
mode: "{{ docker_compose_file_mask }}"
|
mode: "{{ docker_compose_file_mask }}"
|
||||||
owner: "{{ docker_user.name }}"
|
owner: "{{ docker_user.name }}"
|
||||||
register: file_provider
|
register: file_provider
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Cycle traefik container
|
- name: Cycle container
|
||||||
docker_compose:
|
docker_compose:
|
||||||
project_src: /opt/traefik
|
project_src: /opt/traefik
|
||||||
pull: true
|
pull: true
|
Loading…
Reference in a new issue