Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/teamdeeson/docker-proxy
Proxy for Docker
https://github.com/teamdeeson/docker-proxy
docker drupal proxy traefik
Last synced: 18 days ago
JSON representation
Proxy for Docker
- Host: GitHub
- URL: https://github.com/teamdeeson/docker-proxy
- Owner: teamdeeson
- Created: 2018-10-30T23:09:35.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-02-26T16:59:42.000Z (12 months ago)
- Last Synced: 2024-11-17T21:27:33.700Z (3 months ago)
- Topics: docker, drupal, proxy, traefik
- Language: Shell
- Size: 5.86 KB
- Stars: 0
- Watchers: 5
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# docker4drupal Traefik Proxy
## Purpose
Provides a Traefik proxy that is independent of docker4drupal. This allows a web developer to have several projects running at the same time.
## Installation
1. Clone this repository locally to your machine.
2. Navigate into the cloned respository and run `make start`
3. To stop run `make stop`
4. To see the Traefik logs run `make view-logs`When Traefik is running you can access its dashboard at [https://monitor.localhost](https://monitor.localhost)
## Configuring your d4d project
### .env
Remove
COMPOSE_PROJECT_NAME
Add the following:
PROJECT_NAME=mylovelproject
PROJECT_BASE_URL=mylovelproject.localhostReplace `mylovelproject` with your project
### docker-compose.yml
In the `docker-compose.yml` file you must add `container_name` parameters to each of you active services.
Use the patterncontainer_name: "${PROJECT_NAME}_mylovelyservice"
Replace `mylovelyservice` with the name of the service you are adding the parameter to.
So, the value of the `container_name` parameter of the `mariadb` service would be:container_name: "${PROJECT_NAME}_mariadb"
To each service add the following:
networks:
- proxyRemove the `traefik.backend` labels from all services.
Remove or comment out the service definition for `traefik`.Add the following to the bottom of the file:
networks:
proxy:
external: trueAdd the following parameter to the `php` service:
D4D_HOSTNAME: ${PROJECT_BASE_URL}
### Drupal settings.php
Add the following mapping to the `$base_domains` array:
getenv('D4D_HOSTNAME') => 'local'
### Drush sites.aliases.drushrc.php
Alter the `uri` key of the `docker` alias:
'uri' => getenv('D4D_HOSTNAME')