Changed to label based config

Removed traefik.yml in favor of label based configuration and
changed hosts to moxietest
This commit is contained in:
2019-12-02 14:24:57 -05:00
parent 8787722c6c
commit f04f3acc58
4 changed files with 4 additions and 16 deletions

View File

@@ -1,18 +1,12 @@
- name: Install Traefik Configuration
template:
src: traefik.yml
dest: traefik.yml
notify: Restart Traefik container
- name: Start Traefik container
docker_container:
name: "{{ traefik_name }}"
image: traefik:{{ traefik_version }}
command: --api.insecure=true --providers.docker
state: started
restart_policy: always
ports:
- "{{ traefik_port }}:80"
- "{{ traefik_admin_port }}:8080"
volumes:
- ./traefik.yml:/etc/traefik/traefik.yml
- /var/run/docker.sock:/var/run/docker.sock

View File

@@ -1,8 +0,0 @@
# Docker configuration backend
providers:
docker:
defaultRule: "Host(`{{'{{'}} trimPrefix `/` .Name }}.{{ traefik_domain }}`)"
# API and dashboard configuration
api:
insecure: true