It may be easier to deal with a local file to manage our env variables.
You can add your .env.local
at the root of this project and define a command function in your ~/.bashrc
:
# ~/.bashrc or ~/.zshrc
function dc() {
if [ -f .env.local ]; then
docker compose --env-file=.env --env-file=.env.local $@
else
docker compose $@
fi
}
NB: If one of the port is already allocated, see the Changing ports section and run command again.
-
Pull this repository
-
If you need a fresh version of images, build all images:
bin/build.sh
Change all the default passwords or secrets you can see in .env
.
They often start with __CHANGE_ME_
.
- Run (magical) configuration for all projects:
bin/setup.sh
If the stack is already deployed, you should use migrate after a fresh build:
bin/migrate.sh
First, make sure you have set the PHRASEA_DOMAIN
to your main domain. A wildcard certificate will be generated on that domain.
Add and configure the following lines to your env.local
:
TRAEFIK_PROVIDERS_FILE_FILENAME=
LETS_ENCRYPT_ENABLED=true
LETS_ENCRYPT_PROVIDER=gandiv5
LEGO_GANDIV5_API_KEY=<Your API key>
Then just update the traefik container:
dc up -d traefik
and wait for traefik to grab your certificate.
By default, we are using Let's Encrypt's staging. To get a fresh production certificate, you should set:
LETS_ENCRYPT_CA_SERVER=https://acme-v02.api.letsencrypt.org/directory
You can change the services port by overriding the environment variables (see .env
file).
You may want to popupate databases with a set of fixtures:
# Be careful! This will empty the databases, insert fixtures and run bin/setup.sh again
bin/install-fixtures.sh
-
Read group of services documentation to customize environment variables:
-
Start the whole stack:
dc up -d
If you are a developer: follow dev setup guide