Skip to content

Commit 3bb1173

Browse files
committed
add Caddy configuration and Docker Compose files for local development
1 parent 2cd3179 commit 3bb1173

File tree

4 files changed

+31
-0
lines changed

4 files changed

+31
-0
lines changed

CONTRIBUTING.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,6 @@ smallweb.localhost, *.smallweb.localhost {
1010

1111
You can follow the instructions from the [docs](https://www.smallweb.run/docs/hosting/local/) to find out how to install caddy locally.
1212

13+
> [!WARNING] Make sure to trust the certificate generated by caddy by running the `caddy trust` command.
14+
1315
Then, all debug commands will use the example workspace located in the `examples` folder.

Caddyfile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
http://smallweb.localhost, http://*.smallweb.localhost, smallweb.localhost, *.smallweb.localhost {
2+
reverse_proxy smallweb:7777
3+
}

docker-compose.dev.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
services:
2+
smallweb:
3+
build:
4+
context: .
5+
dockerfile: Dockerfile
6+
volumes:
7+
- ./examples:/smallweb
8+
caddy:
9+
image: caddy:latest
10+
ports:
11+
- "80:80"
12+
- "443:443"
13+
volumes:
14+
- ./Caddyfile:/etc/caddy/Caddyfile

docker-compose.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
services:
2+
smallweb:
3+
image: ghcr.io/pomdtr/smallweb:latest
4+
volumes:
5+
- ./examples:/smallweb
6+
caddy:
7+
image: caddy:latest
8+
ports:
9+
- "80:80"
10+
- "443:443"
11+
volumes:
12+
- ./Caddyfile:/etc/caddy/Caddyfile

0 commit comments

Comments
 (0)