Solution using Strapi v4 with Docker. I was missing an simple small way to use Strapi v4 in Docker and never wanted to trick with something like: Strapi Community.
- clone this repository
- modify the
.env
file - create your own docker compose file by extending
strapi4-postgres-compose.yml
and embedingpostgres_db
andstrapi4
IMPORTANT Postgres service name should be passed to strapis environment variables as DATABASE_HOST
value.
a docker node container is used with a startup script docker-init.sh
. This script starts or installs strapi inside the container. Installation folder is exported.
- integrate letsencrypt to be automatically applied (script or nginx container mod)
- nextjs and other (?) frontend helper
- suggestions
(https://hub.docker.com/_/postgres)
(https://docs.docker.com/compose/)
(https://docs.strapi.io/developer-docs/latest/getting-started/quick-start.html)
npx create-strapi-app@latest --help