Ansible lint, update versions

This commit is contained in:
Peter Schiffer 2023-12-17 02:39:45 +01:00
parent c7d2da3d72
commit 82550ee69c
No known key found for this signature in database
GPG key ID: F2A18AC34A008397
4 changed files with 52 additions and 52 deletions

View file

@ -1,5 +1,6 @@
--- ---
- hosts: localhost - name: PDNS
hosts: localhost
vars: vars:
pdns_master_ip: 172.5.0.20 pdns_master_ip: 172.5.0.20
pdns_slave_ip: 172.5.0.21 pdns_slave_ip: 172.5.0.21
@ -8,8 +9,8 @@
i_state: present i_state: present
alpine: false alpine: false
tasks: tasks:
- name: create docker network - name: Create docker network
docker_network: community.docker.docker_network:
name: pdns-net name: pdns-net
state: present state: present
ipam_config: ipam_config:
@ -20,8 +21,8 @@
- pdns-admin - pdns-admin
- pdns-recursor - pdns-recursor
- name: build pdns recursor - name: Build pdns recursor
docker_image: community.docker.docker_image:
name: pschiffe/pdns-recursor name: pschiffe/pdns-recursor
state: '{{ i_state }}' state: '{{ i_state }}'
source: build source: build
@ -32,8 +33,8 @@
tags: tags:
- pdns-recursor - pdns-recursor
- name: build pdns recursor alpine version - name: Build pdns recursor alpine version
docker_image: community.docker.docker_image:
name: pschiffe/pdns-recursor name: pschiffe/pdns-recursor
tag: alpine tag: alpine
state: '{{ i_state }}' state: '{{ i_state }}'
@ -46,26 +47,26 @@
tags: tags:
- pdns-recursor - pdns-recursor
- name: pdns recursor - name: PDNS recursor
docker_container: community.docker.docker_container:
name: pdns-recursor name: pdns-recursor
image: pschiffe/pdns-recursor:{{ "alpine" if alpine | bool else "latest" }} image: pschiffe/pdns-recursor:{{ "alpine" if alpine | bool else "latest" }}
state: '{{ c_state }}' state: '{{ c_state }}'
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
volumes: volumes:
- /etc/localtime:/etc/localtime:ro - /etc/localtime:/etc/localtime:ro
ulimits:
- 'nofile:5000:5000'
tags: tags:
- pdns-recursor - pdns-recursor
- name: db - name: DB
docker_container: community.docker.docker_container:
name: pdns-mariadb name: pdns-mariadb
image: mariadb:10.11 image: mariadb:11
pull: true pull: true
state: '{{ c_state }}' state: '{{ c_state }}'
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
aliases: aliases:
@ -77,19 +78,18 @@
env: env:
MYSQL_ROOT_PASSWORD: 'my-secret-pw' MYSQL_ROOT_PASSWORD: 'my-secret-pw'
healthcheck: healthcheck:
test: ['CMD', 'mysqladmin', 'ping', '-h', 'localhost'] test: ['CMD', 'healthcheck.sh', '--su=mysql', '--connect', '--innodb_initialized']
timeout: 10s timeout: 10s
retries: 5 retries: 5
tags: tags:
- db - db
- name: phpmyadmin - name: Phpmyadmin
docker_container: community.docker.docker_container:
name: pdns-phpmyadmin name: pdns-phpmyadmin
image: phpmyadmin:5 image: phpmyadmin:5
pull: true pull: true
state: '{{ c_state }}' state: '{{ c_state }}'
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
published_ports: published_ports:
@ -99,8 +99,8 @@
tags: tags:
- db - db
- name: build pdns - name: Build pdns
docker_image: community.docker.docker_image:
name: pschiffe/pdns-mysql name: pschiffe/pdns-mysql
state: '{{ i_state }}' state: '{{ i_state }}'
source: build source: build
@ -111,8 +111,8 @@
tags: tags:
- pdns - pdns
- name: build pdns alpine version - name: Build pdns alpine version
docker_image: community.docker.docker_image:
name: pschiffe/pdns-mysql name: pschiffe/pdns-mysql
tag: alpine tag: alpine
state: '{{ i_state }}' state: '{{ i_state }}'
@ -125,13 +125,12 @@
tags: tags:
- pdns - pdns
- name: pdns master - name: PDNS master
docker_container: community.docker.docker_container:
name: pdns name: pdns
image: pschiffe/pdns-mysql:{{ "alpine" if alpine | bool else "latest" }} image: pschiffe/pdns-mysql:{{ "alpine" if alpine | bool else "latest" }}
state: '{{ c_state }}' state: '{{ c_state }}'
hostname: ns1.example.com hostname: ns1.example.com
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
ipv4_address: '{{ pdns_master_ip }}' ipv4_address: '{{ pdns_master_ip }}'
@ -155,13 +154,12 @@
tags: tags:
- pdns - pdns
- name: pdns slave - name: PDNS slave
docker_container: community.docker.docker_container:
name: pdns-slave name: pdns-slave
image: pschiffe/pdns-mysql:{{ "alpine" if alpine | bool else "latest" }} image: pschiffe/pdns-mysql:{{ "alpine" if alpine | bool else "latest" }}
state: '{{ c_state }}' state: '{{ c_state }}'
hostname: ns2.example.com hostname: ns2.example.com
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
ipv4_address: '{{ pdns_slave_ip }}' ipv4_address: '{{ pdns_slave_ip }}'
@ -185,8 +183,8 @@
tags: tags:
- pdns - pdns
- name: build pdns-admin base - name: Build pdns-admin base
docker_image: community.docker.docker_image:
name: pschiffe/pdns-admin-base name: pschiffe/pdns-admin-base
tag: latest tag: latest
state: '{{ i_state }}' state: '{{ i_state }}'
@ -198,8 +196,8 @@
tags: tags:
- pdns-admin - pdns-admin
- name: build pdns-admin backend - name: Build pdns-admin backend
docker_image: community.docker.docker_image:
name: pschiffe/pdns-admin-uwsgi name: pschiffe/pdns-admin-uwsgi
tag: latest tag: latest
state: '{{ i_state }}' state: '{{ i_state }}'
@ -211,8 +209,8 @@
tags: tags:
- pdns-admin - pdns-admin
- name: build pdns-admin frontent - name: Build pdns-admin frontent
docker_image: community.docker.docker_image:
name: pschiffe/pdns-admin-static name: pschiffe/pdns-admin-static
tag: latest tag: latest
state: '{{ i_state }}' state: '{{ i_state }}'
@ -224,12 +222,11 @@
tags: tags:
- pdns-admin - pdns-admin
- name: pdns-admin backend - name: PDNS-admin backend
docker_container: community.docker.docker_container:
name: pdns-admin-uwsgi name: pdns-admin-uwsgi
image: pschiffe/pdns-admin-uwsgi image: pschiffe/pdns-admin-uwsgi
state: '{{ c_state }}' state: '{{ c_state }}'
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
aliases: aliases:
@ -238,17 +235,16 @@
- /etc/localtime:/etc/localtime:ro - /etc/localtime:/etc/localtime:ro
env: env:
PDNS_ADMIN_SQLA_DB_PASSWORD: "'my-secret-pw'" PDNS_ADMIN_SQLA_DB_PASSWORD: "'my-secret-pw'"
PDNS_VERSION: "4.7" PDNS_VERSION: "4.8"
PDNS_API_KEY: "secret" PDNS_API_KEY: "secret"
tags: tags:
- pdns-admin - pdns-admin
- name: pdns-admin frontend - name: PDNS-admin frontend
docker_container: community.docker.docker_container:
name: pdns-admin-static name: pdns-admin-static
image: pschiffe/pdns-admin-static image: pschiffe/pdns-admin-static
state: '{{ c_state }}' state: '{{ c_state }}'
networks_cli_compatible: true
networks: networks:
- name: pdns-net - name: pdns-net
published_ports: published_ports:
@ -258,14 +254,14 @@
tags: tags:
- pdns-admin - pdns-admin
- name: remove docker volumes - name: Remove docker volume
command: docker volume rm pdns-mariadb-volume community.docker.docker_volume:
ignore_errors: true name: pdns-mariadb-volume
state: absent
when: wipe | bool when: wipe | bool
- name: remove network - name: Remove network
docker_network: community.docker.docker_network:
name: pdns-net name: pdns-net
state: absent state: absent
ignore_errors: true
when: wipe | bool when: wipe | bool

View file

@ -8,9 +8,13 @@ services:
- pdns - pdns
volumes: volumes:
- /etc/localtime:/etc/localtime:ro - /etc/localtime:/etc/localtime:ro
ulimits:
nofile:
soft: 5000
hard: 5000
mariadb: mariadb:
image: mariadb:10.11 image: mariadb:11
networks: networks:
pdns: pdns:
aliases: aliases:
@ -22,7 +26,7 @@ services:
environment: environment:
- MYSQL_ROOT_PASSWORD=my-secret-pw - MYSQL_ROOT_PASSWORD=my-secret-pw
healthcheck: healthcheck:
test: ['CMD', 'mysqladmin', 'ping', '-h', 'localhost'] test: ['CMD', 'healthcheck.sh', '--su=mysql', '--connect', '--innodb_initialized']
timeout: 10s timeout: 10s
retries: 5 retries: 5
@ -100,7 +104,7 @@ services:
- /etc/localtime:/etc/localtime:ro - /etc/localtime:/etc/localtime:ro
environment: environment:
- PDNS_ADMIN_SQLA_DB_PASSWORD='my-secret-pw' - PDNS_ADMIN_SQLA_DB_PASSWORD='my-secret-pw'
- PDNS_VERSION=4.7 - PDNS_VERSION=4.8
- PDNS_API_KEY=secret - PDNS_API_KEY=secret
depends_on: depends_on:
- mariadb - mariadb

View file

@ -58,7 +58,7 @@ spec:
- name: PDNS_API_URL - name: PDNS_API_URL
value: "http://master-api-pdns:8081/" value: "http://master-api-pdns:8081/"
- name: PDNS_VERSION - name: PDNS_VERSION
value: "4.7" value: "4.8"
- name: PDNS_API_KEY - name: PDNS_API_KEY
valueFrom: valueFrom:
secretKeyRef: secretKeyRef:

View file

@ -27,7 +27,7 @@ spec:
spec: spec:
containers: containers:
- name: mariadb-pdns - name: mariadb-pdns
image: mariadb:10.11 image: mariadb:11
imagePullPolicy: Always imagePullPolicy: Always
env: env:
- name: MYSQL_ROOT_PASSWORD - name: MYSQL_ROOT_PASSWORD