Skip to content

Conversation

@Chaitu-Tatipamula
Copy link
Contributor

Summary

This PR implements automatic deployment address management using deployments.json, addressing issue #354. Scripts now automatically load and update contract addresses from a JSON file keyed by chain-id, eliminating the need for manual environment variable management.

Changes

  • Added tools/deployments.sh: Shared script with functions to:

    • Load deployment addresses from deployments.json for a given chain-id
    • Update addresses in JSON after deployment
    • Track metadata (commit hash, deployment timestamp)
    • Handle missing chains gracefully
  • Created deployments.json: JSON structure for storing addresses organized by chain-id

  • Updated deployment scripts to use the shared system:

    • deploy-all-warm-storage.sh
    • deploy-session-key-registry.sh
    • deploy-registry-calibnet.sh
    • deploy-warm-storage-calibnet.sh
    • upgrade.sh
    • upgrade-registry.sh
  • Updated documentation: Added section to tools/README.md explaining the system

Features

  • Addresses automatically loaded from JSON (no need to set env vars)
  • Addresses automatically updated after deployment
  • Chain-id based organization (e.g., jq '.["314"]' deployments.json)
  • Environment variables can still override JSON values
  • Control flags: SKIP_LOAD_DEPLOYMENTS and SKIP_UPDATE_DEPLOYMENTS
  • Metadata tracking for commit hash and deployment timestamp

Usage

Addresses are automatically loaded from deployments.json

./tools/deploy-all-warm-storage.sh

Query addresses

jq '.["314159"].WARM_STORAGE_PROXY_ADDRESS' deployments.json

Skip loading/updating if needed

SKIP_LOAD_DEPLOYMENTS=true ./tools/deploy-all-warm-storage.sh## Testing

  • Tested with calibnet deployment
  • Verified addresses are correctly loaded and updated
  • Confirmed backward compatibility (env vars still work)

Closes #354

- Add deployments.sh with load/update functions
- Create deployments.json structure for chain-id based storage
- Update all deployment scripts to use shared system
- Add metadata tracking (commit hash, deployment timestamp)
- Support SKIP_LOAD_DEPLOYMENTS and SKIP_UPDATE_DEPLOYMENTS flags
@FilOzzy FilOzzy added this to FS Dec 5, 2025
@github-project-automation github-project-automation bot moved this to 📌 Triage in FS Dec 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 📌 Triage

Development

Successfully merging this pull request may close these issues.

doc: Deployment Addresses json

1 participant