Split compose configs for publish and local testing
This commit is contained in:
19
README.md
19
README.md
@@ -12,7 +12,7 @@ Merge multiple iCalendar feeds into one and serve the result over HTTP. Built wi
|
||||
|
||||
2. Edit `.env` and set your calendar URLs and Traefik host.
|
||||
|
||||
3. Start behind Traefik (requires external `proxy` network):
|
||||
3. Start the published image behind Traefik (requires external `proxy` network):
|
||||
|
||||
```bash
|
||||
docker compose up -d
|
||||
@@ -26,19 +26,15 @@ Merge multiple iCalendar feeds into one and serve the result over HTTP. Built wi
|
||||
|
||||
## Local testing (without Traefik)
|
||||
|
||||
Create `docker-compose.override.yml` (gitignored) with a port mapping:
|
||||
Use the local build compose file for development and testing:
|
||||
|
||||
```yaml
|
||||
services:
|
||||
cal-funnel:
|
||||
ports:
|
||||
- "8080:8080"
|
||||
```bash
|
||||
docker compose -f docker-compose.local.yml up -d --build
|
||||
```
|
||||
|
||||
Then run:
|
||||
|
||||
```bash
|
||||
docker compose up -d
|
||||
curl http://localhost:8080/health
|
||||
curl http://localhost:8080/calendar.ics
|
||||
```
|
||||
@@ -64,6 +60,13 @@ curl http://localhost:8080/calendar.ics
|
||||
| `/health` | Health check (`200` when ready) |
|
||||
| `/` | Short HTML page with subscription link |
|
||||
|
||||
## Compose files
|
||||
|
||||
| File | Purpose |
|
||||
|------|---------|
|
||||
| `docker-compose.yml` | Published deployment using the registry image `git.beging.de/troogs/cal-funnel:latest` and Traefik routing |
|
||||
| `docker-compose.local.yml` | Local build/test deployment with `build: .` and `localhost:8080` published |
|
||||
|
||||
## Build image
|
||||
|
||||
```bash
|
||||
|
||||
10
docker-compose.local.yml
Normal file
10
docker-compose.local.yml
Normal file
@@ -0,0 +1,10 @@
|
||||
services:
|
||||
cal-funnel:
|
||||
build: .
|
||||
image: cal-funnel:local
|
||||
container_name: cal-funnel-local
|
||||
restart: unless-stopped
|
||||
env_file:
|
||||
- .env
|
||||
ports:
|
||||
- "8080:8080"
|
||||
@@ -1,8 +1,6 @@
|
||||
services:
|
||||
cal-funnel:
|
||||
build: .
|
||||
image: cal-funnel:latest
|
||||
container_name: cal-funnel
|
||||
image: git.beging.de/troogs/cal-funnel:latest
|
||||
restart: unless-stopped
|
||||
env_file:
|
||||
- .env
|
||||
|
||||
Reference in New Issue
Block a user