nitro-stack/stack-orchestrator/config/nitro-contracts/deploy.sh
Nabarun Gogoi c0fe155708
Add stack for running individual nitro node (#2)
* Build go-nitro container image

* Run nitro node using stack

* Add config setup in readme for running nitro node

* Add script for deploying contracts

---------

Co-authored-by: Shreerang Kale <shreerangkale@gmail.com>
Co-authored-by: Neeraj <neeraj.rtly@gmail.com>
2024-07-18 10:22:37 +05:30

28 lines
918 B
Bash
Executable File

#!/bin/bash
# TODO: Make sure contracts are not deployed on L2
set -e
if [ -n "$CERC_SCRIPT_DEBUG" ]; then
set -x
fi
echo "Environment variables..."
echo "CERC_SCRIPT_DEBUG: ${CERC_SCRIPT_DEBUG}"
echo "CERC_GETH_URL: ${CERC_GETH_URL}"
echo "CERC_OPTIMISM_URL: ${CERC_OPTIMISM_URL}"
echo "CERC_GETH_CHAIN_ID: ${CERC_GETH_CHAIN_ID}"
echo "CERC_OPTIMISM_CHAIN_ID: ${CERC_OPTIMISM_CHAIN_ID}"
echo "CERC_GETH_DEPLOYER_PK: ${CERC_GETH_DEPLOYER_PK}"
echo "CERC_OPTIMISM_DEPLOYER_PK: ${CERC_OPTIMISM_DEPLOYER_PK}"
echo "CERC_DISABLE_DETERMINISTIC_DEPLOYMENT: true"
export GETH_URL=$CERC_GETH_URL
export GETH_CHAIN_ID=$CERC_GETH_CHAIN_ID
export OPTIMISM_CHAIN_ID=$CERC_OPTIMISM_CHAIN_ID
export OPTIMISM_URL=$CERC_OPTIMISM_URL
export GETH_DEPLOYER_PK=$CERC_GETH_DEPLOYER_PK
export OPTIMISM_DEPLOYER_PK=$GETH_DEPLOYER_PK
export DISABLE_DETERMINISTIC_DEPLOYMENT=true
yarn contracts:deploy-geth
yarn contracts:deploy-optimism