{% include 'roles/sys-svc-compose/templates/base.yml.j2' %} {% set service_name = PENPOT_FRONTEND_SERVICE %} {{ service_name }}: {% include 'roles/sys-svc-container/templates/base.yml.j2' %} {{ lookup('container_image', application_id, 'frontend') }} {{ lookup('compose_only', 'container_name', PENPOT_FRONTEND_CONTAINER) }} command: - /bin/bash - -c - 'until getent hosts {{ PENPOT_BACKEND_SERVICE }}. >/dev/null 2>&1 && getent hosts {{ PENPOT_EXPORTER_SERVICE }}. >/dev/null 2>&1; do sleep 1; done; exec nginx -g "daemon off;"' {{ lookup('container_ports', ['penpot', 'http', DOCKER_BIND_HOST]) | indent(4) }} {{ lookup('container_volumes', service_name) | indent(4) }} {{ lookup('container_healthcheck', 'penpot') | indent(4) }} {{ lookup('container_networks') | indent(4) }} {{ lookup('container_depends_on', application_id, extra={ PENPOT_BACKEND_SERVICE: {'condition': 'service_started'}, PENPOT_EXPORTER_SERVICE: {'condition': 'service_started'}, }) | indent(4) }} {% set service_name = PENPOT_BACKEND_SERVICE %} {{ service_name }}: {% include 'roles/sys-svc-container/templates/base.yml.j2' %} {{ lookup('container_extra_hosts') | indent(4) }} {{ lookup('container_image', application_id, 'backend') }} {{ lookup('compose_only', 'container_name', PENPOT_BACKEND_CONTAINER) }} {% if (TLS_MODE | lower) == 'self_signed' %} command: - {{ lookup('volume', 'web-app-penpot', 'java_ca_trust').target }} - /bin/bash - run.sh {% endif %} {{ lookup('container_volumes', service_name) | indent(4) }} {{ lookup('container_healthcheck', 'backend') | indent(4) }} {{ lookup('container_networks') | indent(4) }} {{ lookup('container_depends_on', application_id) | indent(4) }} {% set service_name = PENPOT_EXPORTER_SERVICE %} {{ service_name }}: {% include 'roles/sys-svc-container/templates/base.yml.j2' %} {{ lookup('container_image', application_id, 'exporter') }} {{ lookup('compose_only', 'container_name', PENPOT_EXPORTER_CONTAINER) }} {{ lookup('container_networks') | indent(4) }} {{ lookup('container_depends_on', application_id) | indent(4) }} {{ lookup('compose_volumes') }} {{ lookup('compose_networks') }}