1.9 KiB
1.9 KiB
self-goat-farmos
Hosting files and documentation for the SELF + GOAT instance(s) of farmOS
Overview
The folder named "docker" has the Docker Compose files I used to self-host farmOS on a private server at my house. zrok provides the public IP address and TLS certificate and sends the public traffic over a secure tunnel to the private server.
compose.yml
- this file describes the two containers for farmOSwww
- the farmOS web application (Drupal)db
- the database server (PostgreSQL)
compose.override.yml
- this file describes the zrok containers and was downloaded from the zrok Docker share guide.zrok-enable
- uses the account token to enable an isolated zrok environment in a named volumezrok-share
- runs zrok to reserve the unique name and proxy to the target URL
How To Host farmOS with Docker
These compose files are a complete solution for self-hosting farmOS with a few additional steps.
- Get a zrok account token and save it in a new file name
.env
in the same directory as the two compose files, e.g.,ZROK_ENABLE_TOKEN=abcd1234
. - Set a long, random database password, also in the
.env
file, e.g.,POSTGRES_PASSWORD=71adb2791158c0fdf81a0a48002646b107a62d16d33b2e6e1e
- In
compose.override.yml
, set variableZROK_UNIQUE_NAME
to the desired zrok subdomain, e.g. "selfgoatfarm" becomes https://selfgoatfarm.share.zrok.io. - In case you're self-hosting zrok too, not using zrok.io, then you must set
ZROK_API_ENDPOINT
to your zrok controller's API endpoint. - In the working directory with the compose files, say
docker compose up --detach
.
If everything works and you can visit farmOS at the zrok public share URL you specified then you're good. farmOS will auto-start if you reboot.
If it's not working then check the logs: docker compose logs --follow
.