diff options
author | Hao Liu <44379968+TheRealHaoLiu@users.noreply.github.com> | 2024-07-19 03:19:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-19 03:19:50 +0200 |
commit | ddf4f288d43138b20a2f715284e055a1f7c4e222 (patch) | |
tree | 079e6adebdd8530f3f1037e8a5d23b546b0d2a93 /tools | |
parent | Fix test_url_base_defaults_to_request to reference local host instead… (#15... (diff) | |
download | awx-ddf4f288d43138b20a2f715284e055a1f7c4e222.tar.xz awx-ddf4f288d43138b20a2f715284e055a1f7c4e222.zip |
Remove links from docker-compose template (#15386)
Links are use to indicate network connectivity and optionally provide alias
it is not needed for communication since all the container are on the awx network
in the prometheus container case since awx_ container now have valid hostname it's no longer required (also i think the link is missing a `-` anyway...)
links also implicitly imply dependency between services in this i see awx container depends on redis and postgres so i switch to depends_on to retain that
Making this change to be podman compatible
because i get
```
Error response from daemon: bad parameter: link is not supported
```
Diffstat (limited to 'tools')
-rw-r--r-- | tools/docker-compose/ansible/roles/sources/templates/docker-compose.yml.j2 | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/tools/docker-compose/ansible/roles/sources/templates/docker-compose.yml.j2 b/tools/docker-compose/ansible/roles/sources/templates/docker-compose.yml.j2 index 734b3ba47e..d8ae1b770e 100644 --- a/tools/docker-compose/ansible/roles/sources/templates/docker-compose.yml.j2 +++ b/tools/docker-compose/ansible/roles/sources/templates/docker-compose.yml.j2 @@ -47,7 +47,7 @@ services: {% if minikube_container_group|bool %} MINIKUBE_CONTAINER_GROUP: "true" {% endif %} - links: + depends_on: - postgres - redis_{{ container_postfix }} networks: @@ -197,10 +197,6 @@ services: volumes: - "../../docker-compose/_sources/prometheus.yml:/etc/prometheus/prometheus.yml" - "prometheus_storage:/prometheus:rw" - links: -{% for i in range(control_plane_node_count|int) %} - - awx_{{ loop.index }}:awx{{ loop.index }} # because underscores are not valid in hostnames -{% endfor %} {% endif %} {% if enable_grafana|bool %} grafana: @@ -214,8 +210,6 @@ services: volumes: - "../../grafana:/etc/grafana/provisioning" - "grafana_storage:/var/lib/grafana:rw" - links: - - prometheus depends_on: - prometheus {% endif %} @@ -318,8 +312,6 @@ services: container_name: tools_receptor_hop hostname: receptor-hop command: 'receptor --config /etc/receptor/receptor.conf' - links: - - awx_1 networks: - awx ports: @@ -335,8 +327,6 @@ services: command: 'receptor --config /etc/receptor/receptor.conf' environment: RECEPTORCTL_SOCKET: {{ receptor_socket_file }} - links: - - receptor-hop networks: - awx volumes: |