-
Notifications
You must be signed in to change notification settings - Fork 8
Update reverse proxy networks
Connect/disconnect Traefik proxy to/from Docker networks.
This command is designed for MacOS and/or other systems where Traefik proxy cannot use the host network mode.
Note that command is not compatible with the Traefik configuration providers.docker.exposedbydefault=true - it
handles only container that have the label traefik.enable=true.
Not tested with Docker Desktop on Linux (who uses that?).
One-time connect/disconnect Traefik proxy to/from Docker networks:
php "${DOCKERIZER_PROJECTS_ROOT_DIR}dockerizer_for_php/bin/dockerizer" -d xdebug.start_with_request=trigger maintenance:traefik:update-networks -c reverse-proxyContinuous connect/disconnect Traefik proxy to/from Docker networks and watch for Docker network events (note the --watch option):
php "${DOCKERIZER_PROJECTS_ROOT_DIR}dockerizer_for_php/bin/dockerizer" -d xdebug.start_with_request=trigger maintenance:traefik:update-networks -c reverse-proxy --watchUse the -vvv for verbose output in the debug mode to view all events data that Dockerizer receives from the Docker daemon.
Restart the Traefik proxy requires restarting this command as well.
-
-c(--container, required): Container name or ID of the Traefik proxy. -
-w(--watch, optional): Watch for Docker network events and connect/disconnect Traefik proxy to/from new compositions automatically. -
-vvv(--verbose, optional): Symfony verbose output for debugging purposes.
This is a stateful command collects information about all Docker networks and Traefik proxy container. We store the state in order to react the container kill and network connect events fast and without iterating through all compositions/containers/networks/etc.
This command will:
- Collect information about all Docker networks and containers with the label
traefik.enable=true. - Connects Traefik proxy to all networks that have containers with the label
traefik.enable=true. - Disconnects Traefik proxy from all networks that do not have containers with the label
traefik.enable=true. - Watch for Docker network
connectevents and containerkill/dieevents and react to them.
- docker:mysql:connect
- docker:mysql:export-db
- docker:mysql:import-db
- docker:mysql:upload-to-aws
- docker:mysql:generate-metadata
- docker:mysql:reconstruct-db
- docker:mysql:test-metadata
- MacOS and Docker Desktop support
- Bash aliases
- Install Symfony with Dockerizer
- Running-apps-with-existing-Docker-compositions
- Limitations
- Building MySQL images with DB: how it works
- Configure AWS Lambda
- Gitlab pipeline to build images
- Managing AWS S3 access
- Using AWS credentials with Dockerizer
- Access management cheat-sheet
- FAQ