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
2 changes: 1 addition & 1 deletion dappnode_package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"upstream": [
{
"repo": "dappnode/staker-package-scripts",
"version": "v0.1.1",
"version": "v0.1.0",
"arg": "STAKER_SCRIPTS_VERSION"
}
],
Expand Down
6 changes: 3 additions & 3 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@ services:
build:
context: shutter
args:
UPSTREAM_VERSION: v1.3.7
UPSTREAM_VERSION: v1.3.9
KEYPER_CONFIG_DIR: /keyper/config
SHUTTER_CHAIN_DIR: /chain
STAKER_SCRIPTS_VERSION: v0.1.1
STAKER_SCRIPTS_VERSION: v0.1.0
restart: unless-stopped
environment:
- SHUTTER_API_NODE_PRIVATEKEY=""
- SHUTTER_PUSH_METRICS_ENABLED=false
- KEYPER_NAME=""
- ETHEREUM_WS=""
- ETHEREUM_WS=
- SHUTTER_PUSH_LOGS_ENABLED=false
- PUSHGATEWAY_USERNAME=""
- PUSHGATEWAY_PASSWORD=""
Expand Down
4 changes: 2 additions & 2 deletions package_variants/gnosis/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ services:
CHAIN_PORT: 27656
KEYPER_PORT: 24003
KEYPER_METRICS_PORT: 9100
ASSETS_VERSION: shutter-api-gnosis-1000-v0.0.0
ASSETS_VERSION: shutter-api-gnosis-1000-v0.0.1
ports:
- "24003:24003"
- "27656:27656"
Expand All @@ -17,4 +17,4 @@ services:
build:
args:
NETWORK: gnosis
ASSETS_VERSION: shutter-api-gnosis-1000-v0.0.0
ASSETS_VERSION: shutter-api-gnosis-1000-v0.0.1
11 changes: 6 additions & 5 deletions shutter/go-shutter-settings/settings/keyper.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,12 @@ type KeyperConfig struct {
BeaconAPIURL string `env:"SHUTTER_BEACONAPIURL"`
MaxNumKeysPerMessage int `env:"_ASSETS_MAX_NUM_KEYS_PER_MESSAGE"`
Chain struct {
EncryptedGasLimit int `env:"_ASSETS_ENCRYPTED_GAS_LIMIT"`
MaxTxPointerAge int `env:"_ASSETS_MAX_TX_POINTER_AGE"`
GenesisSlotTimestamp int `env:"_ASSETS_GENESIS_SLOT_TIMESTAMP"`
SyncStartBlockNumber int `env:"_ASSETS_SYNC_START_BLOCK_NUMBER"`
Node struct {
EncryptedGasLimit int `env:"_ASSETS_ENCRYPTED_GAS_LIMIT"`
MaxTxPointerAge int `env:"_ASSETS_MAX_TX_POINTER_AGE"`
GenesisSlotTimestamp int `env:"_ASSETS_GENESIS_SLOT_TIMESTAMP"`
SyncStartBlockNumber int `env:"_ASSETS_SYNC_START_BLOCK_NUMBER"`
SyncMonitorCheckInterval int `env:"_ASSETS_SYNC_MONITOR_CHECK_INTERVAL"`
Node struct {
PrivateKey string `env:"SHUTTER_API_NODE_PRIVATEKEY"`
ContractsURL string `env:"SHUTTER_GNOSIS_NODE_CONTRACTSURL"` //Unused
DeploymentDir string `env:"SHUTTER_DEPLOYMENT_DIR"` // Unused
Expand Down
16 changes: 11 additions & 5 deletions shutter/scripts/configure_keyper.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,18 @@ NODE_PATH=$NODE_HOME/lib/node_modules
PATH=$NODE_HOME/bin:$PATH

function test_ethereum_url() {
# FIXME: This is a workaround for the issue with the [email protected] not setting get_execution_ws_url_from_global_env correctly in the environment variables.
# Git Issue: https://github.com/dappnode/staker-package-scripts/issues/11
export SHUTTER_NETWORK_NODE_ETHEREUMURL=${ETHEREUM_WS:-$(get_execution_ws_url_from_global_env ${NETWORK} ${SUPPORTED_NETWORKS})}
RESULT=$(wscat -c "$SHUTTER_NETWORK_NODE_ETHEREUMURL" -x '{"jsonrpc": "2.0", "method": "eth_syncing", "params": [], "id": 1}')
if [[ $RESULT =~ '"id":1' ]]; then return 0; else
echo "Could not find DAppNode RPC/WS url for this package!"
echo "Please configure 'ETHEREUM_WS' to point to an applicable websocket RPC service."
exit 1;
export SHUTTER_NETWORK_NODE_ETHEREUMURL=ws://execution.${NETWORK}.dncore.dappnode:8545
RESULT=$(wscat -c "$SHUTTER_NETWORK_NODE_ETHEREUMURL" -x '{"jsonrpc": "2.0", "method": "eth_syncing", "params": [], "id": 1}')
if [[ $RESULT =~ '"id":1' ]]; then return 0; else
echo "Could not find DAppNode RPC/WS url for this package!"
echo "Please configure 'ETHEREUM_WS' to point to an applicable websocket RPC service."
exit 1
fi
fi
}

Expand All @@ -33,9 +40,8 @@ fi

export SHUTTER_P2P_ADVERTISEADDRESSES="[\"/ip4/${_DAPPNODE_GLOBAL_PUBLIC_IP}/tcp/${KEYPER_PORT}\", \"/ip4/${_DAPPNODE_GLOBAL_PUBLIC_IP}/udp/${KEYPER_PORT}/quic-v1\"]"

export SHUTTER_NETWORK_NODE_ETHEREUMURL=${ETHEREUM_WS:-$(get_execution_ws_url_from_global_env "$NETWORK" "$SUPPORTED_NETWORKS")}
echo "[DEBUG | configure] SHUTTER_NETWORK_NODE_ETHEREUMURL is ${SHUTTER_NETWORK_NODE_ETHEREUMURL}"
test_ethereum_url
echo "[DEBUG | configure] SHUTTER_NETWORK_NODE_ETHEREUMURL is ${SHUTTER_NETWORK_NODE_ETHEREUMURL}"

export VALIDATOR_PUBLIC_KEY=$(cat "${SHUTTER_CHAIN_DIR}/config/priv_validator_pubkey.hex")
export SHUTTER_METRICS_ENABLED=${SHUTTER_PUSH_METRICS_ENABLED}
Expand Down
Loading