Populate network from docker itself

main
Alpha Chen 1 year ago
parent 2f3fb21ab6
commit 38c023e314
Signed by: alpha
SSH Key Fingerprint: SHA256:3fOT8fiYQG/aK9ntivV3Bqtg8AYQ7q4nV6ZgihOA20g

@ -46,6 +46,11 @@
- vars.yml
tasks:
- name: Get docker network
community.docker.docker_network:
name: lotus_land_story
register: docker_network
- name: Run Miniflux
community.docker.docker_container:
# recreate: true
@ -60,7 +65,7 @@
ADMIN_PASSWORD: "{{ miniflux.password }}"
BASE_URL: https://rss.{{ domain }}
METRICS_COLLECTOR: "1"
METRICS_ALLOWED_NETWORKS: "172.25.0.0/16" # TODO Read this from docker?
METRICS_ALLOWED_NETWORKS: "{{ docker_network.network.IPAM.Config[0].Subnet }}"
restart_policy: unless-stopped
networks:
- name: lotus_land_story

Loading…
Cancel
Save