aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/ship/deploy_impl_v2.go
Commit message (Collapse)AuthorAgeFilesLines
* fix: pass container port (not host port) as PORT env varClawd2026-02-181-5/+8
| | | | | | Docker deployments were passing the host port as PORT to the container, but the port mapping routes traffic to container port. This caused apps that read PORT from env to listen on the wrong port inside the container.
* fix: port allocator scans existing ports to avoid collisionsClawd2026-02-181-8/+2
| | | | | | | - Collapse multi-line allocScript to single line (fixes SSH+sudo mangling) - Scan /etc/ship/ports/* to find highest port in use - Use max(next_port, highest_used + 1) to prevent collisions - Fixes issue where stale/missing next_port caused port conflicts
* Preserve existing Caddyfiles on redeployClawd2026-02-171-35/+43
| | | | | | | Don't overwrite Caddyfile if it already exists. This preserves manual customizations (NIP-05 routes, custom headers, etc.). First deploy generates Caddyfile, subsequent deploys leave it alone.
* Fix port collision bug, add --container-port flagClawd2026-02-171-17/+28
| | | | | | | | | | | | Port allocation: - Use atomic flock-based allocation via /etc/ship/next_port - Prevents race conditions when multiple deploys run concurrently - Each app still gets its port stored in /etc/ship/ports/<name> Docker container port: - Add --container-port flag (default 80) - Template now uses {{.ContainerPort}} instead of hardcoded 80 - Supports containers that listen on 8080, 3000, etc.
* fix: set ownership before rsync for Docker deployClawd2026-02-151-0/+7
|
* fix: split sudo commands to fix ownership for rsync uploadClawd2026-02-151-2/+8
|
* feat(v2): implement deploy flowsClawd2026-02-151-0/+365
- deploy_impl_v2.go: full implementations for static, docker, binary deploys - Static: rsync + Caddyfile generation + reload - Docker: rsync + build + systemd unit + env file + Caddyfile - Binary: scp + systemd unit + service user + env file + Caddyfile - Port allocation: server-side in /etc/ship/ports/ - TTL: server-side in /etc/ship/ttl/ - Health checks: HTTP GET with 30s retry loop All deploy types now functional (pending Go compilation test)