Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -997,6 +997,10 @@ upgrade_proof_aggregator: ## Upgrade ProofAggregator contract. Parameters: NETWO
@echo "Upgrading ProofAggregator Contract on $(NETWORK) network..."
@. contracts/scripts/.env.$(NETWORK) && . contracts/scripts/upgrade_proof_aggregator.sh

deploy_agg_mode_payment_service:
@echo "Deploying Agg Mode Payment Service contract on $(NETWORK) network..."
@. contracts/scripts/.env.$(NETWORK) && . contracts/scripts/deploy_agg_mode_payment_service.sh

__SP1_FFI__: ##
build_sp1_macos:
@cd operator/sp1/lib && cargo build $(RELEASE_FLAG)
Expand Down
41 changes: 41 additions & 0 deletions contracts/scripts/deploy_agg_mode_payment_service.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#!/bin/bash

# ENV VARIABLES
#
# PROOF_AGGREGATOR_DEPLOY_CONFIG_PATH: Path to the proof aggregator deploy config file
# - Holesky Stage: ./script/deploy/config/holesky/proof-aggregator-service.holesky.config.stage.json
# - Holesky Prod: ./script/deploy/config/holesky/proof-aggregator-service.holesky.config.json
# - Sepolia: ./script/deploy/config/sepolia/proof-aggregator-service.sepolia.config.json
#
# PROOF_AGGREGATOR_OUTPUT_PATH: Path to the proof aggregator output file
# - Holesky Stage: ./script/output/holesky/proof_aggregation_service_deployment_output.stage.json
# - Holesky Prod: ./script/output/holesky/proof_aggregation_service_deployment_output.json
# - Sepolia: ./script/output/sepolia/proof_aggregation_service_deployment_output.json
#
# RPC_URL: The RPC URL to connect to the Ethereum network
#
# PRIVATE_KEY: The private key to use for the deployment
#
# ETHERSCAN_API_KEY: The Etherscan API key to use for verification
#

# cd to the directory of this script so that this can be run from anywhere
parent_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P )
# At this point we are in contracts/scripts
cd "$parent_path"

# At this point we are in contracts
cd ../

# Deploy agg mode payment service contract
forge script script/deploy/AggregationModePaymentServiceDeployer.s.sol \
$PROOF_AGGREGATOR_DEPLOY_CONFIG_PATH \
$PROOF_AGGREGATOR_OUTPUT_PATH \
--rpc-url $RPC_URL \
--private-key $PRIVATE_KEY \
--broadcast \
--verify \
--etherscan-api-key $ETHERSCAN_API_KEY \
--slow \
--sig "run(string configPath, string outputPath)" \
--via-ir
Loading