From 1ae5df7168947cea830f2a507711118c95ada55e Mon Sep 17 00:00:00 2001 From: Manuel Meister Date: Sat, 6 Apr 2024 00:57:29 +0200 Subject: [PATCH] docs: clarify additional compose service configuration (#6019) [skip ci] Co-authored-by: Randy Fay --- docs/content/users/extend/custom-compose-files.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/content/users/extend/custom-compose-files.md b/docs/content/users/extend/custom-compose-files.md index e0bb6ff5037..f44c7c93732 100644 --- a/docs/content/users/extend/custom-compose-files.md +++ b/docs/content/users/extend/custom-compose-files.md @@ -50,9 +50,9 @@ To better understand how DDEV parses your custom docker-compose files, run `ddev ## Conventions for Defining Additional Services -When defining additional services for your project, we recommended following these conventions to ensure DDEV handles your service the same way DDEV handles default services. +When defining additional services for your project, we recommend following these conventions to ensure DDEV handles your service the same way DDEV handles default services. -* The container name should be `ddev-${DDEV_SITENAME}-`. +* The container name should be `ddev-${DDEV_SITENAME}-`. This ensures the auto-generated [Traefik routing configuration](./traefik-router.md#project-traefik-configuration) matches your custom service. * Provide containers with required labels: ```yaml @@ -67,7 +67,7 @@ When defining additional services for your project, we recommended following the * To expose a web interface to be accessible over HTTP, define the following environment variables in the `environment` section for docker-compose: - * `VIRTUAL_HOST=$DDEV_HOSTNAME` + * `VIRTUAL_HOST=$DDEV_HOSTNAME` You can also specify an arbitrary hostname like `VIRTUAL_HOST=extra.ddev.site`. * `HTTP_EXPOSE=portNum` The `hostPort:containerPort` convention may be used here to expose a container’s port to a different external port. To expose multiple ports for a single container, define the ports as comma-separated values. * `HTTPS_EXPOSE=:portNum` This will expose an HTTPS interface on `` to the host (and to the `web` container) as `https://.ddev.site:exposedPortNumber`. To expose multiple ports for a single container, use comma-separated definitions, as in `HTTPS_EXPOSE=9998:80,9999:81`, which would expose HTTP port 80 from the container as `https://.ddev.site:9998` and HTTP port 81 from the container as `https://.ddev.site:9999`.