diff --git a/playbook.yml b/playbook.yml index 7880017..470da79 100644 --- a/playbook.yml +++ b/playbook.yml @@ -4,3 +4,4 @@ roles: - { role: docker, tags: ["docker"] } + - { role: traefik, tags: ["traefik"] } diff --git a/roles/docker/tasks/install.yml b/roles/docker/tasks/install.yml index 8c62c20..dbc04a7 100644 --- a/roles/docker/tasks/install.yml +++ b/roles/docker/tasks/install.yml @@ -32,5 +32,4 @@ ansible.builtin.service: name: "docker" enabled: true - state: started - ignore_errors: true # TODO: Remove it (Not work in docker container) + state: started \ No newline at end of file diff --git a/confs/traefik/config/.gitignore b/roles/traefik/files/config/.gitignore similarity index 100% rename from confs/traefik/config/.gitignore rename to roles/traefik/files/config/.gitignore diff --git a/confs/traefik/config/dynamic_conf.yaml b/roles/traefik/files/config/dynamic_conf.yaml similarity index 100% rename from confs/traefik/config/dynamic_conf.yaml rename to roles/traefik/files/config/dynamic_conf.yaml diff --git a/confs/traefik/config/traefik.yml b/roles/traefik/files/config/traefik.yml similarity index 100% rename from confs/traefik/config/traefik.yml rename to roles/traefik/files/config/traefik.yml diff --git a/confs/traefik/docker-compose.yml b/roles/traefik/files/docker-compose.yml similarity index 100% rename from confs/traefik/docker-compose.yml rename to roles/traefik/files/docker-compose.yml diff --git a/confs/traefik/grafana.env b/roles/traefik/files/grafana.env similarity index 100% rename from confs/traefik/grafana.env rename to roles/traefik/files/grafana.env diff --git a/confs/traefik/grafana/provisioning/dashboards/dashboard.yml b/roles/traefik/files/grafana/provisioning/dashboards/dashboard.yml similarity index 100% rename from confs/traefik/grafana/provisioning/dashboards/dashboard.yml rename to roles/traefik/files/grafana/provisioning/dashboards/dashboard.yml diff --git a/confs/traefik/grafana/provisioning/dashboards/reverse-proxy_rev1.json b/roles/traefik/files/grafana/provisioning/dashboards/reverse-proxy_rev1.json similarity index 100% rename from confs/traefik/grafana/provisioning/dashboards/reverse-proxy_rev1.json rename to roles/traefik/files/grafana/provisioning/dashboards/reverse-proxy_rev1.json diff --git a/confs/traefik/grafana/provisioning/datasources/datasource.yml b/roles/traefik/files/grafana/provisioning/datasources/datasource.yml similarity index 100% rename from confs/traefik/grafana/provisioning/datasources/datasource.yml rename to roles/traefik/files/grafana/provisioning/datasources/datasource.yml diff --git a/roles/traefik/tasks/base.yml b/roles/traefik/tasks/base.yml new file mode 100644 index 0000000..c64d8f9 --- /dev/null +++ b/roles/traefik/tasks/base.yml @@ -0,0 +1,7 @@ +--- + +- name: Copy traefik conf + ansible.builtin.copy: + backup: true + src: . + dest: traefik/ \ No newline at end of file diff --git a/roles/traefik/tasks/main.yml b/roles/traefik/tasks/main.yml new file mode 100644 index 0000000..3f670ac --- /dev/null +++ b/roles/traefik/tasks/main.yml @@ -0,0 +1,4 @@ +--- + +- ansible.builtin.import_tasks: base.yml + name: base \ No newline at end of file