Skip to content

Instantly share code, notes, and snippets.

View joohhnnn's full-sized avatar

John Chase joohhnnn

View GitHub Profile
@joohhnnn
joohhnnn / storage_interaction.go
Last active May 2, 2023 08:32
A complete Go program that demonstrates how to interact with the Storage smart contract.
package main
import (
"context"
"crypto/ecdsa"
"fmt"
"log"
"math/big"
"github.com/ethereum/go-ethereum/accounts/abi/bind"
@joohhnnn
joohhnnn / entrypoint-l2.sh
Created September 6, 2023 06:44
entrypoint-l2.sh
#!/bin/sh
set -exu
VERBOSITY=${GETH_VERBOSITY:-3}
GETH_DATA_DIR=/db
GETH_CHAINDATA_DIR="$GETH_DATA_DIR/geth/chaindata"
GETH_KEYSTORE_DIR="$GETH_DATA_DIR/keystore"
GENESIS_FILE_PATH="${GENESIS_FILE_PATH:-/genesis.json}"
CHAIN_ID=$(cat "$GENESIS_FILE_PATH" | jq -r .config.chainId)
BLOCK_SIGNER_PRIVATE_KEY="ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"