fix: correct tunnel token env var so cloudflared gets the token #136
No reviewers
Labels
No labels
architecture
backend
bug
ci
config
database
docker
documentation
duplicate
enhancement
frontend
help wanted
invalid
issue-25
issue-26
issue-42
issue-65
issue-67
issue-82
migrations
p0-critical
p1-high
p2-medium
p3-low
performance
quality
question
security
state-management
testing
timezone
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
fastie81/honbu-manager!136
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/tunnel-token-var"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes the production tunnel crash-looping (cloudflared 'Restarting 255' with an empty token).
Root cause: the base docker-compose.yml declared the cloudflared token as:
but the CI deploy job injects TUNNEL_TOKEN into .env.prod/.env.test. Variable-name mismatch meant the token never reached the container, so cloudflared ran without a token and exited.
Changes:
Verified green on branch: test 2m6s, lint 58s, build 2m3s.
The base docker-compose.yml declared the cloudflared tunnel's token as TUNNEL_TOKEN= but the CI deploy job injects TUNNEL_TOKEN into .env.prod/.env.test. The name mismatch left the tunnel with an empty token, causing cloudflared to crash-loop (Restarting 255) in production. - docker-compose.yml: tunnel now reads ${TUNNEL_TOKEN:-} (matches the secret name, the workflow injector, and the .env.prod placeholder). - ci.yml: the deploy injector now also substitutes a CLOUDFLARE_TUNNEL_TOKEN placeholder if present, and only skips appending TUNNEL_TOKEN when either truthy var already exists -- so the whole pipeline is robust to either placeholder.