Skip to content

Enable Fly.io-compatible runtime and container startup#113

Merged
lukepring merged 2 commits into
mainfrom
copilot/update-deploy-fly-io
Jul 8, 2026
Merged

Enable Fly.io-compatible runtime and container startup#113
lukepring merged 2 commits into
mainfrom
copilot/update-deploy-fly-io

Conversation

Copilot AI commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

This app was wired for local Docker Compose assumptions (fixed port + implicit local service topology), which blocks Fly.io deployment. This change makes runtime/network configuration platform-driven while preserving local defaults.

  • Runtime port binding

    • Updated the server to bind to process.env.PORT with a local fallback, so Fly can inject the listen port at runtime.
  • Container boot behavior

    • Added an explicit Docker startup command so the image reliably launches the Node process when deployed.
  • Fly deployment configuration

    • Added fly.toml with http_service.internal_port = 3000 and PORT=3000 to align Fly routing with the containerized app.
  • Database configuration model

    • Kept DB connectivity env-driven (DB_HOST/DB_PORT/DB_USER/DB_PASSWORD/DB_NAME, etc.) with local defaults intact, so Compose-based local development still works while Fly can point to external MySQL.
// app/app.js
const PORT = process.env.PORT || 3000;
app.listen(PORT, "0.0.0.0", () => {
  console.log(`Server running on port ${PORT}`);
});

Copilot AI changed the title [WIP] Update application for deployment on Fly.io Enable Fly.io-compatible runtime and container startup Jul 8, 2026
Copilot AI requested a review from lukepring July 8, 2026 23:37
@lukepring lukepring marked this pull request as ready for review July 8, 2026 23:39
@lukepring lukepring merged commit 794b9d6 into main Jul 8, 2026
1 check passed
@lukepring lukepring deleted the copilot/update-deploy-fly-io branch July 8, 2026 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants