Solved discourse network bug

This commit is contained in:
Kevin Veen-Birkenbach 2024-01-08 12:30:08 +01:00
parent bf421835c3
commit 21b5b4a299
2 changed files with 7 additions and 7 deletions

View File

@ -18,6 +18,11 @@
state: directory state: directory
mode: 0755 mode: 0755
- name: "Ensure {{docker_compose_project_name}}_default network exists"
community.docker.docker_network:
name: "{{docker_compose_project_name}}_default"
state: present
- name: add docker-compose.yml - name: add docker-compose.yml
template: src=docker-compose.yml.j2 dest={{docker_compose_instance_directory}}docker-compose.yml template: src=docker-compose.yml.j2 dest={{docker_compose_instance_directory}}docker-compose.yml
notify: docker compose project setup notify: docker compose project setup
@ -47,12 +52,6 @@
dest: "{{discourse_repository_directory}}containers/app.yml" dest: "{{discourse_repository_directory}}containers/app.yml"
notify: recreate discourse notify: recreate discourse
- name: "Ensure {{docker_compose_project_name}}_default network exists"
community.docker.docker_network:
name: "{{docker_compose_project_name}}_default"
state: present
when: enable_central_database | bool
- name: "add central database temporary to {{docker_compose_project_name}}_default" - name: "add central database temporary to {{docker_compose_project_name}}_default"
command: command:
cmd: "docker network connect discourse_default central-{{ database_type }}" cmd: "docker network connect discourse_default central-{{ database_type }}"

View File

@ -10,3 +10,4 @@ services:
redis: redis:
{% include 'templates/docker-compose-networks.yml.j2' %} {% include 'templates/docker-compose-networks.yml.j2' %}
external: true