Skip to content

Commit 2c4e2fb

Browse files
authored
chore(config): fallback to FromEnv for the SlotCalculator instead of using FromEnvVar (#149)
1 parent 64e3377 commit 2c4e2fb

File tree

2 files changed

+26
-27
lines changed

2 files changed

+26
-27
lines changed

README.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -71,32 +71,32 @@ Finally, if it's non-empty, the submit task attempts to get a signature for the
7171

7272
The Builder is configured via environment variables. The following values are supported for configuration.
7373

74-
| Key | Required | Description |
75-
| ----------------------------- | -------- | ------------------------------------------------------------------- |
76-
| `HOST_CHAIN_ID` | Yes | Host-chain ID (e.g. `3151908`) |
77-
| `RU_CHAIN_ID` | Yes | Rollup-chain ID (e.g. `14174`) |
78-
| `HOST_RPC_URL` | Yes | RPC endpoint for the host chain |
79-
| `ROLLUP_RPC_URL` | Yes | RPC endpoint for the rollup chain |
80-
| `TX_POOL_URL` | Yes | Transaction pool URL (must end with `/`) |
81-
| `TX_BROADCAST_URLS` | No | Additional endpoints for blob txs (comma-separated, slash required) |
82-
| `ZENITH_ADDRESS` | Yes | Zenith contract address |
83-
| `BUILDER_HELPER_ADDRESS` | Yes | Builder helper contract address |
84-
| `QUINCEY_URL` | Yes | Remote sequencer signing endpoint |
85-
| `BUILDER_PORT` | Yes | HTTP port for the Builder (default: `8080`) |
86-
| `SEQUENCER_KEY` | Yes | AWS KMS key ID _or_ local private key for sequencer signing |
87-
| `BUILDER_KEY` | Yes | AWS KMS key ID _or_ local private key for builder signing |
88-
| `BUILDER_REWARDS_ADDRESS` | Yes | Address receiving builder rewards |
89-
| `ROLLUP_BLOCK_GAS_LIMIT` | No | Override for block gas limit |
90-
| `CONCURRENCY_LIMIT` | No | Max concurrent tasks the simulator uses |
91-
| `OAUTH_CLIENT_ID` | Yes | Oauth client ID for the builder |
92-
| `OAUTH_CLIENT_SECRET` | Yes | Oauth client secret for the builder |
93-
| `OAUTH_AUTHENTICATE_URL` | Yes | Oauth authenticate URL for the builder for performing OAuth logins |
94-
| `OAUTH_TOKEN_URL` | Yes | Oauth token URL for the builder to get an Oauth2 access token |
95-
| `AUTH_TOKEN_REFRESH_INTERVAL` | Yes | The OAuth token refresh interval in seconds. |
96-
| `CHAIN_NAME` | Yes | The chain name ("pecorino", or the corresponding name) |
97-
| `SLOT_OFFSET` | Yes | Slot timing offset in seconds. Optional if `CHAIN_NAME` is present |
98-
| `SLOT_DURATION` | Yes | Slot duration in seconds. Optional if `CHAIN_NAME` is present |
99-
| `START_TIMESTAMP` | Yes | UNIX timestamp for slot 0. Optional if `CHAIN_NAME` is present |
74+
| Key | Required | Description |
75+
| ----------------------------- | -------- | ----------------------------------------------------------------------- |
76+
| `HOST_CHAIN_ID` | Yes | Host-chain ID (e.g. `3151908`) |
77+
| `RU_CHAIN_ID` | Yes | Rollup-chain ID (e.g. `14174`) |
78+
| `HOST_RPC_URL` | Yes | RPC endpoint for the host chain |
79+
| `ROLLUP_RPC_URL` | Yes | RPC endpoint for the rollup chain |
80+
| `TX_POOL_URL` | Yes | Transaction pool URL (must end with `/`) |
81+
| `TX_BROADCAST_URLS` | No | Additional endpoints for blob txs (comma-separated, slash required) |
82+
| `ZENITH_ADDRESS` | Yes | Zenith contract address |
83+
| `BUILDER_HELPER_ADDRESS` | Yes | Builder helper contract address |
84+
| `QUINCEY_URL` | Yes | Remote sequencer signing endpoint |
85+
| `BUILDER_PORT` | Yes | HTTP port for the Builder (default: `8080`) |
86+
| `SEQUENCER_KEY` | Yes | AWS KMS key ID _or_ local private key for sequencer signing |
87+
| `BUILDER_KEY` | Yes | AWS KMS key ID _or_ local private key for builder signing |
88+
| `BUILDER_REWARDS_ADDRESS` | Yes | Address receiving builder rewards |
89+
| `ROLLUP_BLOCK_GAS_LIMIT` | No | Override for block gas limit |
90+
| `CONCURRENCY_LIMIT` | No | Max concurrent tasks the simulator uses |
91+
| `OAUTH_CLIENT_ID` | Yes | Oauth client ID for the builder |
92+
| `OAUTH_CLIENT_SECRET` | Yes | Oauth client secret for the builder |
93+
| `OAUTH_AUTHENTICATE_URL` | Yes | Oauth authenticate URL for the builder for performing OAuth logins |
94+
| `OAUTH_TOKEN_URL` | Yes | Oauth token URL for the builder to get an Oauth2 access token |
95+
| `AUTH_TOKEN_REFRESH_INTERVAL` | Yes | The OAuth token refresh interval in seconds. |
96+
| `CHAIN_NAME` | No | The chain name ("pecorino", or the corresponding name) |
97+
| `SLOT_OFFSET` | No | Slot timing offset in seconds. Required if `CHAIN_NAME` is not present |
98+
| `SLOT_DURATION` | No | Slot duration in seconds. Optional if `CHAIN_NAME` is not present |
99+
| `START_TIMESTAMP` | No | UNIX timestamp for slot 0. Optional if `CHAIN_NAME` is not present |
100100

101101
---
102102

src/config.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,6 @@ pub struct BuilderConfig {
154154
pub concurrency_limit: Option<usize>,
155155

156156
/// The slot calculator for the builder.
157-
#[from_env(var = "CHAIN_NAME", desc = "The slot calculator for the builder")]
158157
pub slot_calculator: SlotCalculator,
159158
}
160159

0 commit comments

Comments
 (0)