diff --git a/dev/local-environment/configurations/dolos/dolos.toml b/dev/local-environment/configurations/dolos/dolos.toml new file mode 100644 index 0000000000..dc8caba11b --- /dev/null +++ b/dev/local-environment/configurations/dolos/dolos.toml @@ -0,0 +1,51 @@ +[upstream] +peer_address = "cardano-node-1:32000" +network_magic = 42 +is_testnet = true + +[storage] +version = "v1" +path = "/data" +max_wal_history = 10000 +max_chain_history = 10000 + +[genesis] +byron_path = "/shared/byron/genesis.json" +shelley_path = "/shared/shelley/genesis.json" +alonzo_path = "/shared/shelley/genesis.alonzo.json" +conway_path = "/shared/conway/genesis.conway.json" + +[chain] +type = "cardano" + +[chain.track] +account_state = true +asset_state = true +pool_state = true +epoch_state = true +drep_state = true +proposal_logs = true +tx_logs = true +account_logs = true +pool_logs = true +epoch_logs = true + +[sync] +pull_batch_size = 100 + +[submit] +prune_height = 200 + +[serve.grpc] +listen_address = "[::]:50051" + +[serve.minibf] +listen_address = "[::]:3000" + +[logging] +max_level = "DEBUG" +include_tokio = true +include_pallas = true +include_grpc = true +include_trp = true +include_minibf = true diff --git a/dev/local-environment/configurations/dolos/entrypoint.sh b/dev/local-environment/configurations/dolos/entrypoint.sh new file mode 100644 index 0000000000..2f346818c4 --- /dev/null +++ b/dev/local-environment/configurations/dolos/entrypoint.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +echo "Waiting for Cardano chain to start..." + +while true; do + if [ -f "/shared/cardano.ready" ]; then + break + else + sleep 1 + fi +done + +echo "Cardano chain ready. Starting Dolos..." + +exec dolos daemon --config=/dolos.toml diff --git a/dev/local-environment/configurations/genesis/shelley/genesis.alonzo.json b/dev/local-environment/configurations/genesis/shelley/genesis.alonzo.json index f11bd7dcaf..9076c649d8 100644 --- a/dev/local-environment/configurations/genesis/shelley/genesis.alonzo.json +++ b/dev/local-environment/configurations/genesis/shelley/genesis.alonzo.json @@ -1,365 +1,381 @@ { - "collateralPercentage": 150, - "costModels": { - "PlutusV1": [ - 205665, - 812, - 1, - 1, - 1000, - 571, - 0, - 1, - 1000, - 24177, - 4, - 1, - 1000, - 32, - 117366, - 10475, - 4, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 100, - 100, - 23000, - 100, - 19537, - 32, - 175354, - 32, - 46417, - 4, - 221973, - 511, - 0, - 1, - 89141, - 32, - 497525, - 14068, - 4, - 2, - 196500, - 453240, - 220, - 0, - 1, - 1, - 1000, - 28662, - 4, - 2, - 245000, - 216773, - 62, - 1, - 1060367, - 12586, - 1, - 208512, - 421, - 1, - 187000, - 1000, - 52998, - 1, - 80436, - 32, - 43249, - 32, - 1000, - 32, - 80556, - 1, - 57667, - 4, - 1000, - 10, - 197145, - 156, - 1, - 197145, - 156, - 1, - 204924, - 473, - 1, - 208896, - 511, - 1, - 52467, - 32, - 64832, - 32, - 65493, - 32, - 22558, - 32, - 16563, - 32, - 76511, - 32, - 196500, - 453240, - 220, - 0, - 1, - 1, - 69522, - 11687, - 0, - 1, - 60091, - 32, - 196500, - 453240, - 220, - 0, - 1, - 1, - 196500, - 453240, - 220, - 0, - 1, - 1, - 806990, - 30482, - 4, - 1927926, - 82523, - 4, - 265318, - 0, - 4, - 0, - 85931, - 32, - 205665, - 812, - 1, - 1, - 41182, - 32, - 212342, - 32, - 31220, - 32, - 32696, - 32, - 43357, - 32, - 32247, - 32, - 38314, - 32, - 9462713, - 1021, - 10 - ], - "PlutusV2": [ - 205665, - 812, - 1, - 1, - 1000, - 571, - 0, - 1, - 1000, - 24177, - 4, - 1, - 1000, - 32, - 117366, - 10475, - 4, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 23000, - 100, - 100, - 100, - 23000, - 100, - 19537, - 32, - 175354, - 32, - 46417, - 4, - 221973, - 511, - 0, - 1, - 89141, - 32, - 497525, - 14068, - 4, - 2, - 196500, - 453240, - 220, - 0, - 1, - 1, - 1000, - 28662, - 4, - 2, - 245000, - 216773, - 62, - 1, - 1060367, - 12586, - 1, - 208512, - 421, - 1, - 187000, - 1000, - 52998, - 1, - 80436, - 32, - 43249, - 32, - 1000, - 32, - 80556, - 1, - 57667, - 4, - 1000, - 10, - 197145, - 156, - 1, - 197145, - 156, - 1, - 204924, - 473, - 1, - 208896, - 511, - 1, - 52467, - 32, - 64832, - 32, - 65493, - 32, - 22558, - 32, - 16563, - 32, - 76511, - 32, - 196500, - 453240, - 220, - 0, - 1, - 1, - 69522, - 11687, - 0, - 1, - 60091, - 32, - 196500, - 453240, - 220, - 0, - 1, - 1, - 196500, - 453240, - 220, - 0, - 1, - 1, - 1159724, - 392670, - 0, - 2, - 806990, - 30482, - 4, - 1927926, - 82523, - 4, - 265318, - 0, - 4, - 0, - 85931, - 32, - 205665, - 812, - 1, - 1, - 41182, - 32, - 212342, - 32, - 31220, - 32, - 32696, - 32, - 43357, - 32, - 32247, - 32, - 38314, - 32, - 35892428, - 10, - 9462713, - 1021, - 10, - 38887044, - 32947, - 10 - ] + "collateralPercentage": 150, + "costModels": { + "PlutusV1": { + "sha2_256-memory-arguments": 4, + "equalsString-cpu-arguments-constant": 1000, + "cekDelayCost-exBudgetMemory": 100, + "lessThanEqualsByteString-cpu-arguments-intercept": 103599, + "divideInteger-memory-arguments-minimum": 1, + "appendByteString-cpu-arguments-slope": 621, + "blake2b-cpu-arguments-slope": 29175, + "iData-cpu-arguments": 150000, + "encodeUtf8-cpu-arguments-slope": 1000, + "unBData-cpu-arguments": 150000, + "multiplyInteger-cpu-arguments-intercept": 61516, + "cekConstCost-exBudgetMemory": 100, + "nullList-cpu-arguments": 150000, + "equalsString-cpu-arguments-intercept": 150000, + "trace-cpu-arguments": 150000, + "mkNilData-memory-arguments": 32, + "lengthOfByteString-cpu-arguments": 150000, + "cekBuiltinCost-exBudgetCPU": 29773, + "bData-cpu-arguments": 150000, + "subtractInteger-cpu-arguments-slope": 0, + "unIData-cpu-arguments": 150000, + "consByteString-memory-arguments-intercept": 0, + "divideInteger-memory-arguments-slope": 1, + "divideInteger-cpu-arguments-model-arguments-slope": 118, + "listData-cpu-arguments": 150000, + "headList-cpu-arguments": 150000, + "chooseData-memory-arguments": 32, + "equalsInteger-cpu-arguments-intercept": 136542, + "sha3_256-cpu-arguments-slope": 82363, + "sliceByteString-cpu-arguments-slope": 5000, + "unMapData-cpu-arguments": 150000, + "lessThanInteger-cpu-arguments-intercept": 179690, + "mkCons-cpu-arguments": 150000, + "appendString-memory-arguments-intercept": 0, + "modInteger-cpu-arguments-model-arguments-slope": 118, + "ifThenElse-cpu-arguments": 1, + "mkNilPairData-cpu-arguments": 150000, + "lessThanEqualsInteger-cpu-arguments-intercept": 145276, + "addInteger-memory-arguments-slope": 1, + "chooseList-memory-arguments": 32, + "constrData-memory-arguments": 32, + "decodeUtf8-cpu-arguments-intercept": 150000, + "equalsData-memory-arguments": 1, + "subtractInteger-memory-arguments-slope": 1, + "appendByteString-memory-arguments-intercept": 0, + "lengthOfByteString-memory-arguments": 4, + "headList-memory-arguments": 32, + "listData-memory-arguments": 32, + "consByteString-cpu-arguments-intercept": 150000, + "unIData-memory-arguments": 32, + "remainderInteger-memory-arguments-minimum": 1, + "bData-memory-arguments": 32, + "lessThanByteString-cpu-arguments-slope": 248, + "encodeUtf8-memory-arguments-intercept": 0, + "cekStartupCost-exBudgetCPU": 100, + "multiplyInteger-memory-arguments-intercept": 0, + "unListData-memory-arguments": 32, + "remainderInteger-cpu-arguments-model-arguments-slope": 118, + "cekVarCost-exBudgetCPU": 29773, + "remainderInteger-memory-arguments-slope": 1, + "cekForceCost-exBudgetCPU": 29773, + "sha2_256-cpu-arguments-slope": 29175, + "equalsInteger-memory-arguments": 1, + "indexByteString-memory-arguments": 1, + "addInteger-memory-arguments-intercept": 1, + "chooseUnit-cpu-arguments": 150000, + "sndPair-cpu-arguments": 150000, + "cekLamCost-exBudgetCPU": 29773, + "fstPair-cpu-arguments": 150000, + "quotientInteger-memory-arguments-minimum": 1, + "decodeUtf8-cpu-arguments-slope": 1000, + "lessThanInteger-memory-arguments": 1, + "lessThanEqualsInteger-cpu-arguments-slope": 1366, + "fstPair-memory-arguments": 32, + "modInteger-memory-arguments-intercept": 0, + "unConstrData-cpu-arguments": 150000, + "lessThanEqualsInteger-memory-arguments": 1, + "chooseUnit-memory-arguments": 32, + "sndPair-memory-arguments": 32, + "addInteger-cpu-arguments-intercept": 197209, + "decodeUtf8-memory-arguments-slope": 8, + "equalsData-cpu-arguments-intercept": 150000, + "mapData-cpu-arguments": 150000, + "mkPairData-cpu-arguments": 150000, + "quotientInteger-cpu-arguments-constant": 148000, + "consByteString-memory-arguments-slope": 1, + "cekVarCost-exBudgetMemory": 100, + "indexByteString-cpu-arguments": 150000, + "unListData-cpu-arguments": 150000, + "equalsInteger-cpu-arguments-slope": 1326, + "cekStartupCost-exBudgetMemory": 100, + "subtractInteger-cpu-arguments-intercept": 197209, + "divideInteger-cpu-arguments-model-arguments-intercept": 425507, + "divideInteger-memory-arguments-intercept": 0, + "cekForceCost-exBudgetMemory": 100, + "blake2b-cpu-arguments-intercept": 2477736, + "remainderInteger-cpu-arguments-constant": 148000, + "tailList-cpu-arguments": 150000, + "encodeUtf8-cpu-arguments-intercept": 150000, + "equalsString-cpu-arguments-slope": 1000, + "lessThanByteString-memory-arguments": 1, + "multiplyInteger-cpu-arguments-slope": 11218, + "appendByteString-cpu-arguments-intercept": 396231, + "lessThanEqualsByteString-cpu-arguments-slope": 248, + "modInteger-memory-arguments-slope": 1, + "addInteger-cpu-arguments-slope": 0, + "equalsData-cpu-arguments-slope": 10000, + "decodeUtf8-memory-arguments-intercept": 0, + "chooseList-cpu-arguments": 150000, + "constrData-cpu-arguments": 150000, + "equalsByteString-memory-arguments": 1, + "cekApplyCost-exBudgetCPU": 29773, + "quotientInteger-memory-arguments-slope": 1, + "verifySignature-cpu-arguments-intercept": 3345831, + "unMapData-memory-arguments": 32, + "mkCons-memory-arguments": 32, + "sliceByteString-memory-arguments-slope": 1, + "sha3_256-memory-arguments": 4, + "ifThenElse-memory-arguments": 1, + "mkNilPairData-memory-arguments": 32, + "equalsByteString-cpu-arguments-slope": 247, + "appendString-cpu-arguments-intercept": 150000, + "quotientInteger-cpu-arguments-model-arguments-slope": 118, + "cekApplyCost-exBudgetMemory": 100, + "equalsString-memory-arguments": 1, + "multiplyInteger-memory-arguments-slope": 1, + "cekBuiltinCost-exBudgetMemory": 100, + "remainderInteger-memory-arguments-intercept": 0, + "sha2_256-cpu-arguments-intercept": 2477736, + "remainderInteger-cpu-arguments-model-arguments-intercept": 425507, + "lessThanEqualsByteString-memory-arguments": 1, + "tailList-memory-arguments": 32, + "mkNilData-cpu-arguments": 150000, + "chooseData-cpu-arguments": 150000, + "unBData-memory-arguments": 32, + "blake2b-memory-arguments": 4, + "iData-memory-arguments": 32, + "nullList-memory-arguments": 32, + "cekDelayCost-exBudgetCPU": 29773, + "subtractInteger-memory-arguments-intercept": 1, + "lessThanByteString-cpu-arguments-intercept": 103599, + "consByteString-cpu-arguments-slope": 1000, + "appendByteString-memory-arguments-slope": 1, + "trace-memory-arguments": 32, + "divideInteger-cpu-arguments-constant": 148000, + "cekConstCost-exBudgetCPU": 29773, + "encodeUtf8-memory-arguments-slope": 8, + "quotientInteger-cpu-arguments-model-arguments-intercept": 425507, + "mapData-memory-arguments": 32, + "appendString-cpu-arguments-slope": 1000, + "modInteger-cpu-arguments-constant": 148000, + "verifySignature-cpu-arguments-slope": 1, + "unConstrData-memory-arguments": 32, + "quotientInteger-memory-arguments-intercept": 0, + "equalsByteString-cpu-arguments-constant": 150000, + "sliceByteString-memory-arguments-intercept": 0, + "mkPairData-memory-arguments": 32, + "equalsByteString-cpu-arguments-intercept": 112536, + "appendString-memory-arguments-slope": 1, + "lessThanInteger-cpu-arguments-slope": 497, + "modInteger-cpu-arguments-model-arguments-intercept": 425507, + "modInteger-memory-arguments-minimum": 1, + "sha3_256-cpu-arguments-intercept": 0, + "verifySignature-memory-arguments": 1, + "cekLamCost-exBudgetMemory": 100, + "sliceByteString-cpu-arguments-intercept": 150000 }, - "executionPrices": { - "prMem": 5.77e-2, - "prSteps": 7.21e-5 + "PlutusV2": { + "addInteger-cpu-arguments-intercept": 205665, + "addInteger-cpu-arguments-slope": 812, + "addInteger-memory-arguments-intercept": 1, + "addInteger-memory-arguments-slope": 1, + "appendByteString-cpu-arguments-intercept": 1000, + "appendByteString-cpu-arguments-slope": 571, + "appendByteString-memory-arguments-intercept": 0, + "appendByteString-memory-arguments-slope": 1, + "appendString-cpu-arguments-intercept": 1000, + "appendString-cpu-arguments-slope": 24177, + "appendString-memory-arguments-intercept": 4, + "appendString-memory-arguments-slope": 1, + "bData-cpu-arguments": 1000, + "bData-memory-arguments": 32, + "blake2b_256-cpu-arguments-intercept": 117366, + "blake2b_256-cpu-arguments-slope": 10475, + "blake2b_256-memory-arguments": 4, + "cekApplyCost-exBudgetCPU": 23000, + "cekApplyCost-exBudgetMemory": 100, + "cekBuiltinCost-exBudgetCPU": 23000, + "cekBuiltinCost-exBudgetMemory": 100, + "cekConstCost-exBudgetCPU": 23000, + "cekConstCost-exBudgetMemory": 100, + "cekDelayCost-exBudgetCPU": 23000, + "cekDelayCost-exBudgetMemory": 100, + "cekForceCost-exBudgetCPU": 23000, + "cekForceCost-exBudgetMemory": 100, + "cekLamCost-exBudgetCPU": 23000, + "cekLamCost-exBudgetMemory": 100, + "cekStartupCost-exBudgetCPU": 100, + "cekStartupCost-exBudgetMemory": 100, + "cekVarCost-exBudgetCPU": 23000, + "cekVarCost-exBudgetMemory": 100, + "chooseData-cpu-arguments": 19537, + "chooseData-memory-arguments": 32, + "chooseList-cpu-arguments": 175354, + "chooseList-memory-arguments": 32, + "chooseUnit-cpu-arguments": 46417, + "chooseUnit-memory-arguments": 4, + "consByteString-cpu-arguments-intercept": 221973, + "consByteString-cpu-arguments-slope": 511, + "consByteString-memory-arguments-intercept": 0, + "consByteString-memory-arguments-slope": 1, + "constrData-cpu-arguments": 89141, + "constrData-memory-arguments": 32, + "decodeUtf8-cpu-arguments-intercept": 497525, + "decodeUtf8-cpu-arguments-slope": 14068, + "decodeUtf8-memory-arguments-intercept": 4, + "decodeUtf8-memory-arguments-slope": 2, + "divideInteger-cpu-arguments-constant": 196500, + "divideInteger-cpu-arguments-model-arguments-intercept": 453240, + "divideInteger-cpu-arguments-model-arguments-slope": 220, + "divideInteger-memory-arguments-intercept": 0, + "divideInteger-memory-arguments-minimum": 1, + "divideInteger-memory-arguments-slope": 1, + "encodeUtf8-cpu-arguments-intercept": 1000, + "encodeUtf8-cpu-arguments-slope": 28662, + "encodeUtf8-memory-arguments-intercept": 4, + "encodeUtf8-memory-arguments-slope": 2, + "equalsByteString-cpu-arguments-constant": 245000, + "equalsByteString-cpu-arguments-intercept": 216773, + "equalsByteString-cpu-arguments-slope": 62, + "equalsByteString-memory-arguments": 1, + "equalsData-cpu-arguments-intercept": 1060367, + "equalsData-cpu-arguments-slope": 12586, + "equalsData-memory-arguments": 1, + "equalsInteger-cpu-arguments-intercept": 208512, + "equalsInteger-cpu-arguments-slope": 421, + "equalsInteger-memory-arguments": 1, + "equalsString-cpu-arguments-constant": 187000, + "equalsString-cpu-arguments-intercept": 1000, + "equalsString-cpu-arguments-slope": 52998, + "equalsString-memory-arguments": 1, + "fstPair-cpu-arguments": 80436, + "fstPair-memory-arguments": 32, + "headList-cpu-arguments": 43249, + "headList-memory-arguments": 32, + "iData-cpu-arguments": 1000, + "iData-memory-arguments": 32, + "ifThenElse-cpu-arguments": 80556, + "ifThenElse-memory-arguments": 1, + "indexByteString-cpu-arguments": 57667, + "indexByteString-memory-arguments": 4, + "lengthOfByteString-cpu-arguments": 1000, + "lengthOfByteString-memory-arguments": 10, + "lessThanByteString-cpu-arguments-intercept": 197145, + "lessThanByteString-cpu-arguments-slope": 156, + "lessThanByteString-memory-arguments": 1, + "lessThanEqualsByteString-cpu-arguments-intercept": 197145, + "lessThanEqualsByteString-cpu-arguments-slope": 156, + "lessThanEqualsByteString-memory-arguments": 1, + "lessThanEqualsInteger-cpu-arguments-intercept": 204924, + "lessThanEqualsInteger-cpu-arguments-slope": 473, + "lessThanEqualsInteger-memory-arguments": 1, + "lessThanInteger-cpu-arguments-intercept": 208896, + "lessThanInteger-cpu-arguments-slope": 511, + "lessThanInteger-memory-arguments": 1, + "listData-cpu-arguments": 52467, + "listData-memory-arguments": 32, + "mapData-cpu-arguments": 64832, + "mapData-memory-arguments": 32, + "mkCons-cpu-arguments": 65493, + "mkCons-memory-arguments": 32, + "mkNilData-cpu-arguments": 22558, + "mkNilData-memory-arguments": 32, + "mkNilPairData-cpu-arguments": 16563, + "mkNilPairData-memory-arguments": 32, + "mkPairData-cpu-arguments": 76511, + "mkPairData-memory-arguments": 32, + "modInteger-cpu-arguments-constant": 196500, + "modInteger-cpu-arguments-model-arguments-intercept": 453240, + "modInteger-cpu-arguments-model-arguments-slope": 220, + "modInteger-memory-arguments-intercept": 0, + "modInteger-memory-arguments-minimum": 1, + "modInteger-memory-arguments-slope": 1, + "multiplyInteger-cpu-arguments-intercept": 69522, + "multiplyInteger-cpu-arguments-slope": 11687, + "multiplyInteger-memory-arguments-intercept": 0, + "multiplyInteger-memory-arguments-slope": 1, + "nullList-cpu-arguments": 60091, + "nullList-memory-arguments": 32, + "quotientInteger-cpu-arguments-constant": 196500, + "quotientInteger-cpu-arguments-model-arguments-intercept": 453240, + "quotientInteger-cpu-arguments-model-arguments-slope": 220, + "quotientInteger-memory-arguments-intercept": 0, + "quotientInteger-memory-arguments-minimum": 1, + "quotientInteger-memory-arguments-slope": 1, + "remainderInteger-cpu-arguments-constant": 196500, + "remainderInteger-cpu-arguments-model-arguments-intercept": 453240, + "remainderInteger-cpu-arguments-model-arguments-slope": 220, + "remainderInteger-memory-arguments-intercept": 0, + "remainderInteger-memory-arguments-minimum": 1, + "remainderInteger-memory-arguments-slope": 1, + "serialiseData-cpu-arguments-intercept": 1159724, + "serialiseData-cpu-arguments-slope": 392670, + "serialiseData-memory-arguments-intercept": 0, + "serialiseData-memory-arguments-slope": 2, + "sha2_256-cpu-arguments-intercept": 806990, + "sha2_256-cpu-arguments-slope": 30482, + "sha2_256-memory-arguments": 4, + "sha3_256-cpu-arguments-intercept": 1927926, + "sha3_256-cpu-arguments-slope": 82523, + "sha3_256-memory-arguments": 4, + "sliceByteString-cpu-arguments-intercept": 265318, + "sliceByteString-cpu-arguments-slope": 0, + "sliceByteString-memory-arguments-intercept": 4, + "sliceByteString-memory-arguments-slope": 0, + "sndPair-cpu-arguments": 85931, + "sndPair-memory-arguments": 32, + "subtractInteger-cpu-arguments-intercept": 205665, + "subtractInteger-cpu-arguments-slope": 812, + "subtractInteger-memory-arguments-intercept": 1, + "subtractInteger-memory-arguments-slope": 1, + "tailList-cpu-arguments": 41182, + "tailList-memory-arguments": 32, + "trace-cpu-arguments": 212342, + "trace-memory-arguments": 32, + "unBData-cpu-arguments": 31220, + "unBData-memory-arguments": 32, + "unConstrData-cpu-arguments": 32696, + "unConstrData-memory-arguments": 32, + "unIData-cpu-arguments": 43357, + "unIData-memory-arguments": 32, + "unListData-cpu-arguments": 32247, + "unListData-memory-arguments": 32, + "unMapData-cpu-arguments": 38314, + "unMapData-memory-arguments": 32, + "verifyEcdsaSecp256k1Signature-cpu-arguments": 35892428, + "verifyEcdsaSecp256k1Signature-memory-arguments": 10, + "verifyEd25519Signature-cpu-arguments-intercept": 57996947, + "verifyEd25519Signature-cpu-arguments-slope": 18975, + "verifyEd25519Signature-memory-arguments": 10, + "verifySchnorrSecp256k1Signature-cpu-arguments-intercept": 38887044, + "verifySchnorrSecp256k1Signature-cpu-arguments-slope": 32947, + "verifySchnorrSecp256k1Signature-memory-arguments": 10, + "integerToByteString-cpu-arguments-c0": 1292075, + "integerToByteString-cpu-arguments-c1": 24469, + "integerToByteString-cpu-arguments-c2": 74, + "integerToByteString-memory-arguments-intercept": 0, + "integerToByteString-memory-arguments-slope": 1, + "byteStringToInteger-cpu-arguments-c0": 936157, + "byteStringToInteger-cpu-arguments-c1": 49601, + "byteStringToInteger-cpu-arguments-c2": 237, + "byteStringToInteger-memory-arguments-intercept": 0, + "byteStringToInteger-memory-arguments-slope": 1 + } + }, + "executionPrices": { + "prSteps": { + "numerator": 721, + "denominator": 10000000 }, - "lovelacePerUTxOWord": 34482, - "maxBlockExUnits": { - "exUnitsMem": 62000000, - "exUnitsSteps": 40000000000 - }, - "maxCollateralInputs": 3, - "maxTxExUnits": { - "exUnitsMem": 14000000, - "exUnitsSteps": 10000000000 - }, - "maxValueSize": 5000 -} \ No newline at end of file + "prMem": { + "numerator": 577, + "denominator": 10000 + } + }, + "lovelacePerUTxOWord": 34482, + "maxBlockExUnits": { + "exUnitsMem": 62000000, + "exUnitsSteps": 40000000000 + }, + "maxCollateralInputs": 3, + "maxTxExUnits": { + "exUnitsMem": 14000000, + "exUnitsSteps": 10000000000 + }, + "maxValueSize": 5000 +} diff --git a/dev/local-environment/modules/dolos.txt b/dev/local-environment/modules/dolos.txt new file mode 100644 index 0000000000..80b12d340b --- /dev/null +++ b/dev/local-environment/modules/dolos.txt @@ -0,0 +1,23 @@ + + dolos: + container_name: dolos + image: ${DOLOS_IMAGE} + platform: linux/amd64 + entrypoint: ["/bin/bash", "/entrypoint.sh"] + environment: + - DOLOS_MINIBF_PORT=${DOLOS_MINIBF_PORT} + - DOLOS_GRPC_PORT=${DOLOS_GRPC_PORT} + volumes: + - shared-volume:/shared + - dolos-data:/data + - ./configurations/dolos/entrypoint.sh:/entrypoint.sh + - ./configurations/dolos/dolos.toml:/dolos.toml + ports: + - "${DOLOS_MINIBF_PORT}:${DOLOS_MINIBF_PORT}" + - "${DOLOS_GRPC_PORT}:${DOLOS_GRPC_PORT}" + restart: always + deploy: + resources: + limits: + cpus: ${CPU_DOLOS:-} + memory: ${MEM_DOLOS:-} diff --git a/dev/local-environment/modules/volumes.txt b/dev/local-environment/modules/volumes.txt index 5133574075..56bfe8b689 100644 --- a/dev/local-environment/modules/volumes.txt +++ b/dev/local-environment/modules/volumes.txt @@ -3,6 +3,7 @@ volumes: cardano-node-1-data: {} shared-volume: {} db-sync-state-dir: {} + dolos-data: {} partner-chains-node-1-data: {} partner-chains-node-2-data: {} partner-chains-node-3-data: {} diff --git a/dev/local-environment/setup.sh b/dev/local-environment/setup.sh index afd1124495..f4f81c32bf 100755 --- a/dev/local-environment/setup.sh +++ b/dev/local-environment/setup.sh @@ -3,6 +3,7 @@ PARTNER_CHAINS_NODE_IMAGE="ghcr.io/input-output-hk/partner-chains/partner-chains-node-unstable:latest" CARDANO_IMAGE="ghcr.io/intersectmbo/cardano-node:10.5.1" DBSYNC_IMAGE="ghcr.io/intersectmbo/cardano-db-sync:13.6.0.4" +DOLOS_IMAGE="ghcr.io/txpipe/dolos:1.0.0-beta.5" OGMIOS_IMAGE="cardanosolutions/ogmios:v6.13.0" POSTGRES_IMAGE="postgres:17.2" TESTS_IMAGE="python:3.12-slim" @@ -122,6 +123,23 @@ function validate_memory_limit() { done } +configure_dolos() { + echo "===== DOLOS CONFIGURATION ========" + read -p "Do you want to set a non-default gRPC port for Dolos? (Will default to 50051) (Y/N): " set_dolos_grpc_port + if [[ $set_dolos_grpc_port == [Yy]* ]]; then + dolos_grpc_port=$(validate_port "Enter gRPC port for Dolos: ") + else + dolos_grpc_port=50051 + fi + read -p "Do you want to set a non-default miniBF port for Dolos? (Will default to 3000) (Y/N): " set_dolos_minibf_port + if [[ $set_dolos_minibf_port == [Yy]* ]]; then + dolos_minibf_port=$(validate_port "Enter gRPC port for Dolos: ") + else + dolos_minibf_port=3000 + fi + echo +} + configure_ogmios() { echo "===== OGMIOS CONFIGURATION ========" read -p "Do you want to set a non-default port for Ogmios? (Will default to 1337) (Y/N): " set_ogmios_port @@ -239,6 +257,8 @@ configure_env() { cat <.env POSTGRES_PORT=5432 POSTGRES_PASSWORD=$db_password +DOLOS_MINIBF_PORT=3000 +DOLOS_GRPC_PORT=50051 OGMIOS_PORT=1337 CPU_PARTNER_CHAINS_NODE=0.000 MEM_PARTNER_CHAINS_NODE=1000G @@ -248,6 +268,8 @@ CPU_POSTGRES=0.000 MEM_POSTGRES=1000G CPU_DBSYNC=0.000 MEM_DBSYNC=1000G +CPU_DOLOS=0.000 +MEM_DOLOS=1000G CPU_OGMIOS=0.000 MEM_OGMIOS=1000G EOF @@ -255,6 +277,8 @@ EOF cat <.env POSTGRES_PORT=$db_port POSTGRES_PASSWORD=$db_password +DOLOS_MINIBF_PORT=$dolos_minibf_port +DOLOS_GRPC_PORT=$dolos_grpc_port OGMIOS_PORT=$ogmios_port CPU_PARTNER_CHAINS_NODE=$CPU_PARTNER_CHAINS_NODE MEM_PARTNER_CHAINS_NODE=$MEM_PARTNER_CHAINS_NODE @@ -264,6 +288,8 @@ CPU_POSTGRES=$cpu_postgres MEM_POSTGRES=$mem_postgres CPU_DBSYNC=$cpu_dbsync MEM_DBSYNC=$mem_dbsync +CPU_DOLOS=$cpu_dolos +MEM_DOLOS=$mem_dolos CPU_OGMIOS=$cpu_ogmios MEM_OGMIOS=$mem_ogmios EOF @@ -272,6 +298,7 @@ EOF cat <>.env CARDANO_IMAGE=$CARDANO_IMAGE DBSYNC_IMAGE=$DBSYNC_IMAGE +DOLOS_IMAGE=$DOLOS_IMAGE OGMIOS_IMAGE=$OGMIOS_IMAGE POSTGRES_IMAGE=$POSTGRES_IMAGE TESTS_IMAGE=$TESTS_IMAGE @@ -293,7 +320,8 @@ choose_deployment_option() { echo "3) Include Cardano testnet, Ogmios, DB-Sync and Postgres" echo "4) Deploy a single Partner Chains node with network_mode: "host" for external connections (adjust partner-chains-external-node.txt before running this script)" echo "5) Deploy a 3 node Partner Chain network using wizard" - read -p "Enter your choice (1/2/3/4/5): " deployment_option + echo "6) Include Cardano testnet, Ogmios, and Dolos" + read -p "Enter your choice (1/2/3/4/5/6): " deployment_option else deployment_option=0 fi @@ -321,11 +349,12 @@ create_docker_compose() { cat ./modules/ogmios.txt >> docker-compose.yml ;; 3) - echo -e "Including Cardano testnet, Ogmios, DB-Sync, and Postgres services.\n" + echo -e "Including Cardano testnet, Ogmios, Dolos, DB-Sync, and Postgres services.\n" cat ./modules/cardano.txt >> docker-compose.yml cat ./modules/ogmios.txt >> docker-compose.yml cat ./modules/db-sync.txt >> docker-compose.yml cat ./modules/postgres.txt >> docker-compose.yml + cat ./modules/dolos.txt >> docker-compose.yml ;; 4) echo -e "Including all services with external partner chain node.\n" @@ -333,6 +362,7 @@ create_docker_compose() { cat ./modules/ogmios.txt >> docker-compose.yml cat ./modules/db-sync.txt >> docker-compose.yml cat ./modules/postgres.txt >> docker-compose.yml + cat ./modules/dolos.txt >> docker-compose.yml cat ./modules/partner-chains-external-node.txt >> docker-compose.yml cat ./modules/partner-chains-setup.txt >> docker-compose.yml ;; @@ -342,14 +372,22 @@ create_docker_compose() { cat ./modules/ogmios.txt >> docker-compose.yml cat ./modules/db-sync.txt >> docker-compose.yml cat ./modules/postgres.txt >> docker-compose.yml + cat ./modules/dolos.txt >> docker-compose.yml cat ./modules/partner-chains-wizard.txt >> docker-compose.yml ;; + 6) + echo -e "Including Cardano testnet, Ogmios, and Dolos services.\n" + cat ./modules/cardano.txt >> docker-compose.yml + cat ./modules/ogmios.txt >> docker-compose.yml + cat ./modules/dolos.txt >> docker-compose.yml + ;; 0) echo -e "Including all services.\n" cat ./modules/cardano.txt >> docker-compose.yml cat ./modules/ogmios.txt >> docker-compose.yml cat ./modules/db-sync.txt >> docker-compose.yml cat ./modules/postgres.txt >> docker-compose.yml + cat ./modules/dolos.txt >> docker-compose.yml cat ./modules/partner-chains-nodes.txt >> docker-compose.yml cat ./modules/partner-chains-setup.txt >> docker-compose.yml ;; @@ -379,11 +417,11 @@ parse_arguments() { shift ;; -d|--deployment-option) - if [[ -n "$2" && "$2" =~ ^[1-5]$ ]]; then + if [[ -n "$2" && "$2" =~ ^[1-6]$ ]]; then deployment_option="$2" shift 2 else - echo "Error: Invalid deployment option '$2'. Valid options are 1, 2, 3, 4 or 5." + echo "Error: Invalid deployment option '$2'. Valid options are 1, 2, 3, 4, 5 or 6." exit 1 fi ;; @@ -454,6 +492,7 @@ main() { detect_os "interactive" backup_files "interactive" configure_postgres "interactive" + configure_dolos configure_ogmios resource_limits_setup