Files
kb-anhonesthost/src/content/docs/whp/local-dev/overview.mdx
T

51 lines
2.6 KiB
Plaintext
Raw Normal View History

---
title: Develop locally with our containers
description: Run the same Apache/PHP and Node containers locally that we use to host your site in production.
sidebar:
order: 1
---
import { Aside } from '@astrojs/starlight/components';
import Support from '~/content/partials/support-link.mdx';
The same container images we use to host your site in production are published as open-source images you can pull and run on your laptop. If you're comfortable with Docker, this gives you a development environment that matches production exactly — same OS, same Apache/Nginx config, same PHP or Node version.
## Why use our containers locally
- **Dev/prod parity.** Anything that runs in the container on your machine will run the same way in production. No "works on my Mac" surprises.
- **Quick start.** Each container ships a `local-dev.sh` script that handles the Docker incantation, volume layout, and helper commands.
- **No account required.** The images are public — pull and run.
<Aside type="note">
This page is for customers who are comfortable with Docker. You don't need to use these images to host with us — the WHP panel handles everything for the hosted version. This is for **local development** only.
</Aside>
## Available containers
| Stack | Image | Use case |
|---|---|---|
| **PHP + Apache** | `repo.anhonesthost.net/cloud-hosting-platform/cac` | WordPress, Laravel, traditional PHP apps |
| **Node + Nginx** | `repo.anhonesthost.net/cloud-hosting-platform/cnoc` | Express, custom Node apps, PM2-managed processes |
Both images live in our public Gitea organisation at [repo.anhonesthost.net/cloud-hosting-platform/](https://repo.anhonesthost.net/cloud-hosting-platform/) — the source Dockerfiles, build configs, and helper scripts are all there too. Issues and PRs welcome.
## Prerequisites
- **Docker** (or a compatible runtime like Podman / OrbStack / Rancher Desktop). Docker Desktop on Mac/Windows or `docker.io` on Linux both work.
- A terminal where you can run `git`, `docker`, and basic shell scripts.
- Ports `80` and `443` free on your machine (the local-dev scripts bind these by default; both can be overridden with flags).
## Pick your stack
- **[PHP + Apache locally](/whp/local-dev/php-apache/)** — for WordPress and any PHP application.
- **[Node + Nginx locally](/whp/local-dev/node/)** — for Express, Next.js standalone, or any Node app.
## Related
- [Create a site](/whp/how-to/create-a-site/) — how the same images run as hosted sites in WHP.
- [What is containerized hosting?](/whp/getting-started/what-is-containerized-hosting/)
## Still stuck?
<Support />