Skip to content

chore(fly): node2/node3 configs as deployed on 0.9.0 - #676

Merged
kevincodex1 merged 1 commit into
mainfrom
chore/fly-node-configs-090
Dec 4, 2026
Merged

kevincodex1 merged 1 commit into
mainfrom
chore/fly-node-configs-090

Conversation

@kevincodex1

@kevincodex1 kevincodex1 commented Dec 4, 2026 •

Copy link
Copy Markdown
Member

Link: https://github.com/Twigpine/node/compare/main...chore/fly-node-configs-090?expand=1
Title: chore(fly): node2/node3 configs as deployed on 0.9.0

What

Brings the tracked Fly configs for node2 and node3 in line with what runs on 0.9.0 since 2026-12-04:

  • TWIGPINE_TRUSTED_PROXY = 'fly' + TWIGPINE_TRUSTED_PROXY_CIDRS = '<machine's Fly proxy peer>/32'. 0.9.0 (fix(node): verify proxy socket peers before trusting forwarded client IPs #634) ignores Fly-Client-IP unless the socket peer is in that list. Without it, every client on a node shares one per-IP bucket. The addresses were measured from each machine's connection table while sending traffic through the public hostname: node2 172.19.60.209, node3 172.19.60.241.
  • TWIGPINE_DB_CONNECT_TIMEOUT_SECS = '1800'. Migration 55 took 32 s on node3, close to the 60 s default startup budget.

Each env table equals the deployed config (checked by parsing both files).

Known trade-off

The /32 is the narrowest trust, as docs/RUN-A-NODE.md advises. If Fly moves a machine to another host, its proxy peer changes. The node then fails closed: it ignores the header and clients share one bucket until the address is updated.

node1's config (untracked infra/fly/node1.fly.toml) has the same change with 172.19.15.241/32.

Summary by CodeRabbit

  • Infrastructure
    • Updated deployment settings for two service instances to allow longer database connection waits and recognize trusted proxy traffic. These changes affect how the services handle database connections and forwarded client requests.

Trusted Fly proxy peer per machine (0.9.0 ignores Fly-Client-IP without
TWIGPINE_TRUSTED_PROXY_CIDRS) and a 30 min startup-migration budget.
@coderabbitai

coderabbitai Bot commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The node 2 and node 3 Fly configurations add a 1,800-second database connection timeout and set Fly as a trusted proxy. Each configuration specifies a different trusted proxy CIDR.

Changes: Fly node settings

Layer / File(s) Summary
Node connection and proxy settings
infra/fly/gitlawb-node-2.fly.toml, infra/fly/gitlawb-node-3.fly.toml
Both configurations add a 1,800-second database connection timeout and set fly as the trusted proxy. Node 2 uses CIDR 172.19.60.209/32; node 3 uses 172.19.60.241/32.

Estimated code review effort: 2 (Simple) | ~8 minutes

Possibly related PRs

  • Twigpine/node#152: Adds a per-client-IP push limiter that reads Fly-Client-IP or X-Forwarded-For. This PR configures trusted proxy settings that may determine the client IP used by the limiter; the exact code path is not confirmed.

Suggested reviewers: beardthelion, jatmn

Merge Risk: Minimal · up to 325cd

This updates node 2 and node 3 Fly configs to match their deployed 0.9.0 settings, with a longer database startup timeout and trusted proxy handling. No actionable merge-blocking risk was found. If Fly moves a machine, the proxy address must be re-measured and updated.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the change scope (Fly node2/node3 configs) and the release they match (0.9.0). The PR only updates the tracked Fly configs for node2 and node3 to match the 0.9.0 deployment, adding tru…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description is thorough and specific. It states the purpose (align the tracked node2 and node3 Fly configs with the 0.9.0 deployments), the two env changes (TWIGPINE_TRUSTED_PROXY with per-machine…
Full details: Title check

Explanation

The title names the change scope (Fly node2/node3 configs) and the release they match (0.9.0). The PR only updates the tracked Fly configs for node2 and node3 to match the 0.9.0 deployment, adding trusted-proxy settings and a 1800-second DB connect timeout. The title is specific and accurate, though it is a chore and does not name the proxy or timeout change.

Full details: Description check

Explanation

The description is thorough and specific. It states the purpose (align the tracked node2 and node3 Fly configs with the 0.9.0 deployments), the two env changes (TWIGPINE_TRUSTED_PROXY with per-machine /32 CIDRs, and TWIGPINE_DB_CONNECT_TIMEOUT_SECS=1800 with the migration 55 reason), how the values were measured and verified, and a known trade-off. It covers the template's key information, but the template's other sections are not addressed: the Kind of change checklist is not marked, there is no 'Closes #' issue link (the PR references #634 and #676 in the text but not as a closing link), the 'How a reviewer can verify' section has no command block, the 'Before you request review' checklist is absent, and the Protocol & signing impact block is not addressed. These are mostly non-critical for a config-only chore, so the description is mostly complete.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 3776f4c0-b024-46fb-9763-096e7929ffad
Commits

Reviewing files that changed from the base of the PR and between 01cd1b0 and 325cd61.

Files selected for processing: 2

  • infra/fly/gitlawb-node-2.fly.toml
  • infra/fly/gitlawb-node-3.fly.toml

Included review availability: This review used your included allowance. 4 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.

@kevincodex1
kevincodex1 enabled auto-merge December 4, 2026 05:02
@kevincodex1
kevincodex1 disabled auto-merge December 4, 2026 05:02
@kevincodex1
kevincodex1 merged commit ecf0686 into main Dec 4, 2026
18 checks passed
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.

1 participant