# Rx3-Docker/PHP-Apache Docker Image #------------------------------------------------------------------------------- name: ${IMG_NAME} services: webapp: container_name: ${IMG_NAME} hostname: ${IMG_NAME} image: ${IMG_URL} build: context: . args: IMG_NAME: ${IMG_NAME} IMG_NAME_FULL: ${IMG_NAME_FULL} IMG_VERSION: ${IMG_VERSION} IMG_MAINTAINER: ${IMG_MAINTAINER} IMG_FROM_URL: ${IMG_FROM_URL} APACHE_DOC_ROOT: ${WEBAPP_DOC_ROOT} APACHE_LOG_DIR: ${WEBAPP_LOG_HTTPD_DIR} APACHE_PORT: ${WEBAPP_PORT_MAIN_INT} restart: unless-stopped environment: APACHE_UID: ${APACHE_UID} APACHE_GID: ${APACHE_GID} APACHE_DOC_ROOT: ${WEBAPP_DOC_ROOT} healthcheck: test: ["CMD", "curl", "-f", "http://localhost:${WEBAPP_PORT_MAIN_INT}"] interval: 10s timeout: 3s retries: 3 volumes: # - ./var/www/html:${WEBAPP_DOC_ROOT} - ./var/log/init:${WEBAPP_LOG_INIT_DIR} - ./var/log/supervisor:${WEBAPP_LOG_SV_DIR} - ./var/log/httpd:${WEBAPP_LOG_HTTPD_DIR} ports: - "127.0.0.1:${WEBAPP_PORT_SV_EXT}:${WEBAPP_PORT_SV_INT}" - "127.0.0.1:${WEBAPP_PORT_MAIN_EXT}:${WEBAPP_PORT_MAIN_INT}"