Update traefik 2.2
This commit is contained in:
parent
a804841f87
commit
d7b7e95860
25 changed files with 739 additions and 2 deletions
|
|
@ -68,4 +68,9 @@
|
|||
- name: install / uninstall version 2.1
|
||||
include_tasks: "version_2.1.yml"
|
||||
when:
|
||||
- traefik_version | regex_search('(^2.1)') or traefik_actual_version.stdout | regex_search('(^2.)')
|
||||
- traefik_version | regex_search('(^2.1)')
|
||||
|
||||
- name: install / uninstall version 2.2
|
||||
include_tasks: "version_2.2.yml"
|
||||
when:
|
||||
- traefik_version | regex_search('(^2.2)') or traefik_actual_version.stdout | regex_search('(^2.)')
|
||||
|
|
|
|||
49
tasks/version_2.2.yml
Normal file
49
tasks/version_2.2.yml
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
---
|
||||
- set_fact:
|
||||
traefik_2_2_state: "present"
|
||||
when:
|
||||
- traefik_version | regex_search('(^2.)')
|
||||
|
||||
- set_fact:
|
||||
traefik_2_2_state: "absent"
|
||||
when:
|
||||
- traefik_version | regex_search('(^1.)')
|
||||
|
||||
- name: traefik files version 2.2 need to be {{ traefik_2_2_state }}
|
||||
k8s:
|
||||
state: "{{ traefik_2_2_state }}"
|
||||
context: "{{ my_context }}"
|
||||
resource_definition: "{{ lookup('template', item) | from_yaml }}"
|
||||
with_items:
|
||||
- 2.2/traefik-crd-ingressroutes.yml.j2
|
||||
- 2.2/traefik-crd-ingressroutetcps.yml.j2
|
||||
- 2.2/traefik-crd-ingressrouteudps.yml.j2
|
||||
- 2.2/traefik-crd-middlewares.yml.j2
|
||||
- 2.2/traefik-crd-tlsoptions.yml.j2
|
||||
- 2.2/traefik-crd-tlsstores.yml.j2
|
||||
- 2.2/traefik-crd-traefikservices.yml.j2
|
||||
- 2.2/traefik-cm.yml.j2
|
||||
- 2.2/traefik-sa.yml.j2
|
||||
- 2.2/traefik-clusterrole.yml.j2
|
||||
- 2.2/traefik-clusterrolebinding.yml.j2
|
||||
- 2.2/traefik-dp.yml.j2
|
||||
- 2.2/traefik-svc.yml.j2
|
||||
- 2.2/traefik-dashboard-svc.yml.j2
|
||||
- 2.2/traefik-middleware-httpsredirect.yml.j2
|
||||
- 2.2/traefik-middleware-basicauth.yml.j2
|
||||
- 2.2/traefik-tls-options.yml.j2
|
||||
- 2.2/traefik-dashboard.yml.j2
|
||||
- 2.2/traefik-dashboard-insecure.yml.j2
|
||||
- 2.2/traefik-ping.yml.j2
|
||||
tags: traefik
|
||||
|
||||
- name: IP white list need to be {{ traefik_2_2_state }} for traefik version 2.2
|
||||
k8s:
|
||||
state: "{{ traefik_2_2_state }}"
|
||||
context: "{{ my_context }}"
|
||||
resource_definition: "{{ lookup('template', item) | from_yaml }}"
|
||||
with_items:
|
||||
- 2.2/traefik-middleware-ipwhitelist.yml.j2
|
||||
when:
|
||||
- ingress_whitelist is defined or traefik_2_2_state == "absent"
|
||||
tags: traefik
|
||||
Loading…
Add table
Add a link
Reference in a new issue