Skip to content

Commit 634ac96

Browse files
keanji-xclaude
andauthored
chore: drop gcp-secret-manager optional cargo feature, revert #713 (#714)
## Summary Removes the optional GCP Secret Manager build mode in `bin/gravity_node` and reverts the workflow split that #713 forced as a band-aid. - **`bin/gravity_node/Cargo.toml`** — drop the local `gcp-secret-manager` forwarding feature. Instead pull the `gaptos` dep with that feature always enabled (`features = [\"gcp-secret-manager\"]`). `reqwest` + `base64` become a permanent part of every `gravity_node` build. - **`.github/workflows/release.yml`** — collapse the two-step `gravity_node` / `gravity_cli` build back to the single pre-#713 step. With the feature permanently on at the dep level, the explicit `--features` flag (and the `-p gravity_node` scoping it required) is redundant. No upstream `gravity-aptos` change: the feature flag on `aptos-config` is left in place; we just unconditionally enable it from this side. `cargo` pin is unchanged at `e9544c8`. ## Why The feature was a footgun. v1.6.0 shipped with `default = []` and the Staging Mainnet VFNs auto-restart-looped on the panic in `aptos-config/.../network_config.rs:281` because their identity source is `gcp_secret`. #713 patched the workflow but the underlying design — an optional build flag that every production deploy must remember to enable — is what should go. `reqwest` is already in the workspace via `gravity_cli`'s upload-side `secret_manager.rs`, so making it unconditional in `aptos-config` (via the gaptos feature being always on) does not introduce a new transitive dep at workspace scope. ## Test plan - [x] Local \`cargo check -p gravity_node --profile=quick-release\` (with `RUSTFLAGS=\"--cfg tokio_unstable\"`) passes — finished in 2m27s. Confirms `gaptos = { features = [\"gcp-secret-manager\"] }` resolves and pulls `reqwest` + `base64` into the build graph. - [ ] CI release workflow dry-run (PR-trigger) — the workflow attaches \`release-dryrun-<sha>\` artifact when triggered on a PR. Single \`Build gravity_node and gravity_cli\` step should succeed. - [ ] After merge: cut a new release tag (e.g. \`gravity-mainnet-v1.6.2\`), then verify on a Staging Mainnet VFN that the panic at \`network_config.rs:281\` is gone and \`journalctl -u gravity-vfn-1.service\` advances past the identity-load step. ## References - #713 — the workflow-level fix this supersedes - #710 — original release workflow that shipped without the feature - #688 / #695 — the cluster.toml-side wiring that originally introduced the optional build mode 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent cc982ac commit 634ac96

2 files changed

Lines changed: 3 additions & 28 deletions

File tree

.github/workflows/release.yml

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -64,31 +64,11 @@ jobs:
6464
exit 1
6565
fi
6666
67-
- name: Build gravity_node (with gcp-secret-manager)
68-
# gravity_node's `gcp-secret-manager` cargo feature must be enabled or
69-
# the binary panics on first startup when any node's identity is
70-
# configured as `source = "gcp_secret"` (the production case for
71-
# Staging Mainnet / future mainnet):
72-
#
73-
# panicked at .../config/network_config.rs:281:25:
74-
# load identity blob for peer_id from GCP secret ...: GCP Secret
75-
# Manager support not compiled in. Rebuild aptos-config with
76-
# `--features gcp-secret-manager` ...
77-
#
78-
# The feature is declared on bin/gravity_node/Cargo.toml (not on the
79-
# workspace), so we must scope cargo with `-p gravity_node` to make
80-
# `--features` resolve. gravity_cli is built in a separate step
81-
# below because it does not declare the same feature.
67+
- name: Build gravity_node and gravity_cli
8268
shell: bash
8369
run: |
8470
set -euo pipefail
85-
cargo build --profile quick-release -p gravity_node --bin gravity_node --features gcp-secret-manager
86-
87-
- name: Build gravity_cli
88-
shell: bash
89-
run: |
90-
set -euo pipefail
91-
cargo build --profile quick-release -p gravity_cli --bin gravity_cli
71+
cargo build --profile quick-release --bin gravity_node --bin gravity_cli
9272
9373
- name: Stage release assets and compute sha256
9474
id: stage

bin/gravity_node/Cargo.toml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,6 @@ rust-version.workspace = true
1313
[features]
1414
# Forward feature to gaptos so `-p gravity_node --features randomness_disabled` works
1515
randomness_disabled = ["gaptos/randomness_disabled"]
16-
# Forward feature to gaptos/aptos-config so identity blobs can be loaded from
17-
# GCP Secret Manager at startup. Off by default to keep the HTTP/TLS stack out
18-
# of the default build graph; enable when cluster.toml configures any node with
19-
# `identity = { source = "gcp_secret", ... }`.
20-
gcp-secret-manager = ["gaptos/gcp-secret-manager"]
2116
default = []
2217

2318
[dependencies]
@@ -47,7 +42,7 @@ alloy-transport-http = "=1.0.37"
4742
alloy-rpc-types-eth = "=1.0.37"
4843
async-trait.workspace = true
4944
api.workspace = true
50-
gaptos.workspace = true
45+
gaptos = { workspace = true, features = ["gcp-secret-manager"] }
5146
block-buffer-manager.workspace = true
5247
proposer-reth-map.workspace = true
5348
build-info.workspace = true

0 commit comments

Comments
 (0)