11#! /bin/bash
22
33# errors are handled gracefully to tell the user
4- # set -euo pipefail
4+ set -euo pipefail
55
66# ----------------------------------------
77ALLOW_MAINNET_EXTERNAL=" false"
@@ -132,7 +132,7 @@ select connection_type in "${connection_options[@]}"; do
132132done
133133
134134# Define the list of available networks
135- available_networks=(" mainnet" " preprod" " preview" " sanchonet-pig " " sanchonet-chicken " )
135+ available_networks=(" mainnet" " preprod" " preview" " sanchonet" )
136136
137137
138138# If user selected external node configuration
233233echo -e " ${CYAN} Setting up Docker node...${NC} "
234234
235235# Define the list of available node versions
236- available_versions=( " 10.5.3" " 10.5.1 " )
236+ available_versions=( " 10.5.3" " 10.5.4 " " 10.6.2 " )
237237
238238# Initialize variables to avoid unbound variable errors
239239network=" "
@@ -283,11 +283,7 @@ else
283283fi
284284
285285# Normalize network name for directory/container naming
286- # sanchonet-pig and sanchonet-chicken both normalize to sanchonet
287286network_normalized=" $network "
288- if [ " $network " = " sanchonet-pig" ] || [ " $network " = " sanchonet-chicken" ]; then
289- network_normalized=" sanchonet"
290- fi
291287
292288# Function to assign a unique port based on version
293289# This ensures different versions on the same network use different ports
@@ -395,7 +391,7 @@ dumps_dir="$base_dir/dumps/$network_normalized"
395391utilities_dir=" $base_dir /utilities"
396392
397393# Base URL for node config files
398- if [ " $network " = " sanchonet-pig " ] || [ " $network " = " sanchonet-chicken " ]; then
394+ if [ " $network " = " sanchonet" ]; then
399395 config_base_url=" https://raw.githubusercontent.com/Hornan7/SanchoNet-Tutorials/refs/heads/main/genesis/"
400396else
401397 config_base_url=" https://book.play.dev.cardano.org/environments/$network /"
@@ -447,9 +443,18 @@ config_files=(
447443 " alonzo-genesis.json"
448444 " conway-genesis.json"
449445 " peer-snapshot.json"
450- " guardrails-script.plutus"
451446)
452447
448+ # add dijkstra-genesis.json for 10.6.2
449+ if [ " $node_version " = " 10.6.2" ]; then
450+ config_files+=(" dijkstra-genesis.json" )
451+ fi
452+
453+ # add checkpoints.json for preview and mainnet (not available for sanchonet or preprod)
454+ if [ " $network " = " preview" ] || [ " $network " = " mainnet" ]; then
455+ config_files+=(" checkpoints.json" )
456+ fi
457+
453458# Change directory to the config directory and download files
454459echo -e " ${CYAN} Downloading configuration files...${NC} "
455460cd " $config_dir " || exit
@@ -463,53 +468,6 @@ for file in "${config_files[@]}"; do
463468 curl --silent -O -J -L " ${config_base_url}${file} "
464469done
465470
466- # Create custom topology.json for sanchonet-chicken
467- if [ " $network " = " sanchonet-chicken" ]; then
468- echo -e " ${BLUE} Creating custom topology.json for sanchonet-chicken${NC} "
469- cat > topology.json << 'EOF '
470- {
471- "bootstrapPeers": [
472- {
473- "address": "sanchorelay1.intertreecryptoconsultants.com",
474- "port": 6002
475- }
476- ],
477- "localRoots": [
478- {
479- "accessPoints": [
480- {
481- "address": "sanchorelay1.intertreecryptoconsultants.com",
482- "port": 6002
483- },
484- {
485- "address": "9.tcp.eu.ngrok.io",
486- "port": 20802
487- },
488- {
489- "address": "34.19.153.32",
490- "port": 6002
491- },
492- {
493- "address": "relay.hephy.io",
494- "port": 9000
495- }
496- ],
497- "advertise": false,
498- "trustable": true,
499- "valency": 4
500- }
501- ],
502- "publicRoots": [
503- {
504- "accessPoints": [],
505- "advertise": false
506- }
507- ],
508- "useLedgerAfterSlot": -1
509- }
510- EOF
511- fi
512-
513471# Return to the base directory
514472cd " $base_dir " || exit
515473
0 commit comments