Skip to content

Add contract deployment script for testnet and mainnet #374

Description

@ogazboiz

Join our community: https://t.me/+DOylgFv1jyJlNzM0

Description

There is no automated deployment script. The CI pipeline now builds and optimizes WASM, but deploying and initializing the contract still requires manual CLI commands.

What Needs to Happen

  • Create scripts/deploy.sh:
    1. Build WASM: cargo build --target wasm32-unknown-unknown --release
    2. Optimize: stellar contract optimize
    3. Deploy: stellar contract deploy --wasm-hash ...
    4. Initialize: stellar contract invoke ... initialize --admin ... --treasury ... --fee_rate_bps ...
    5. Save contract ID and tx hashes to deployment-info.json
  • Support --network testnet|mainnet flag
  • Validate required env vars before any action (DEPLOYER_SECRET, TREASURY_ADDRESS, FEE_RATE_BPS)
  • Document in README under "Deployment"

Files

  • scripts/deploy.sh (create)

Acceptance Criteria

  • Single command deploys and initializes to testnet
  • deployment-info.json updated with contract ID
  • Clear error if required env vars are missing

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programgood first issueGood for newcomersinfraCI/CD and infrastructure

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions