Whether you're deploying your first app or tuning a production cluster, these guides walk you through what Lagoonify does, how to use it, and what to look out for.
Lagoon is a container hosting platform that deploys Docker-based applications to Kubernetes. It reads two config files from your repo:
.lagoon.yml — Project metadata, routes, cron jobs, and environment settingsdocker-compose.yml — Service definitions, build instructions, and service typesLagoonify analyses your codebase and generates both files for you.
Or use Full Pipeline to run all three in one click.
Lagoon uses service types (set via lagoon.type labels in docker-compose) to decide how to deploy each container. The most common:
| Type | Port | Use case |
|---|---|---|
python | 8800 | Python apps (Flask, FastAPI, Django) |
node | 3000 | Node.js apps (Express, Next.js) |
nginx-php | 8080 | PHP with Nginx (Laravel, WordPress) |
nginx | 8080 | Static sites or custom Nginx configs |
basic | 3000 | Generic container (Ruby, Go, etc.) |
Add -persistent to any type (e.g. node-persistent) to attach a persistent storage volume. Lagoonify detects this automatically when your app uses file uploads, SQLite, or local data directories.
Lagoon provides Alpine Linux-based base images (uselagoon/*). This matters:
apk add, not apt-get installchown to named users — use chmod 775 insteadIf your repo already has a Dockerfile, Lagoonify will use it. Otherwise, it generates one using the appropriate Lagoon base image.
The generated Dockerfile covers the common case. Write your own when you need:
Routes in .lagoon.yml map domains to services. A minimal route:
environments:
main:
routes:
- node:
- myapp.example.com:
tls-acme: true
insecure: Redirect
tls-acme: true — Auto-provision a Let's Encrypt SSL certificateinsecure: Redirect — Redirect HTTP to HTTPSMultiple routes can point to different services in the same project. Routes are per-environment, so staging and production can have different domains.
The biggest trap in deployment config is over-engineering. Here's a practical framework:
Lagoonify detects monorepos automatically. When multiple sub-projects are found (e.g. frontend/ and backend/), you'll be prompted to pick which one to configure.
Each sub-project gets its own service in the docker-compose file. The analyser looks at the root and each sub-directory for framework indicators like package.json, requirements.txt, or composer.json.
Lagoon base images are Alpine Linux. Use apk add instead of apt-get install. Package names may differ too — check Alpine packages.
Usually a port mismatch. Lagoon runs health checks on the port assigned to your service type. If your app listens on 8000 but the service type expects 8800, health checks never pass.
Check your CMD or ENTRYPOINT. The process must stay in the foreground. Common fix: ensure your web server binds to 0.0.0.0, not 127.0.0.1.
Kubernetes doesn't allow changing certain fields (like spec.selector) on existing deployments. If you change lagoon.type on a service that's already deployed, you'll need to delete the environment and redeploy from scratch.
Lagoon containers run as uid 10000. Don't chown files to named users. Use chmod 775 to ensure the container user can read and write.