diff --git a/files/configs/musashi/alonzo-genesis.json b/files/configs/musashi/alonzo-genesis.json new file mode 100644 index 000000000..7aa503ddb --- /dev/null +++ b/files/configs/musashi/alonzo-genesis.json @@ -0,0 +1,188 @@ +{ + "collateralPercentage": 150, + "costModels": { + "PlutusV1": [ + 197209, + 0, + 1, + 1, + 396231, + 621, + 0, + 1, + 150000, + 1000, + 0, + 1, + 150000, + 32, + 2477736, + 29175, + 4, + 29773, + 100, + 29773, + 100, + 29773, + 100, + 29773, + 100, + 29773, + 100, + 29773, + 100, + 100, + 100, + 29773, + 100, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 1000, + 0, + 1, + 150000, + 32, + 150000, + 1000, + 0, + 8, + 148000, + 425507, + 118, + 0, + 1, + 1, + 150000, + 1000, + 0, + 8, + 150000, + 112536, + 247, + 1, + 150000, + 10000, + 1, + 136542, + 1326, + 1, + 1000, + 150000, + 1000, + 1, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 1, + 1, + 150000, + 1, + 150000, + 4, + 103599, + 248, + 1, + 103599, + 248, + 1, + 145276, + 1366, + 1, + 179690, + 497, + 1, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 148000, + 425507, + 118, + 0, + 1, + 1, + 61516, + 11218, + 0, + 1, + 150000, + 32, + 148000, + 425507, + 118, + 0, + 1, + 1, + 148000, + 425507, + 118, + 0, + 1, + 1, + 2477736, + 29175, + 4, + 0, + 82363, + 4, + 150000, + 5000, + 0, + 1, + 150000, + 32, + 197209, + 0, + 1, + 1, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 150000, + 32, + 3345831, + 1, + 1 + ] + }, + "executionPrices": { + "priceMemory": 0.0577, + "priceSteps": 0.0000721 + }, + "lovelacePerUTxOWord": 34482, + "maxBlockExUnits": { + "exUnitsMem": 72000000, + "exUnitsSteps": 20000000000 + }, + "maxCollateralInputs": 3, + "maxTxExUnits": { + "exUnitsMem": 16500000, + "exUnitsSteps": 10000000000 + }, + "maxValueSize": 5000 +} diff --git a/files/configs/musashi/byron-genesis.json b/files/configs/musashi/byron-genesis.json new file mode 100644 index 000000000..28436a743 --- /dev/null +++ b/files/configs/musashi/byron-genesis.json @@ -0,0 +1,43 @@ +{ + "avvmDistr": {}, + "blockVersionData": { + "heavyDelThd": "300000000000", + "maxBlockSize": "2000000", + "maxHeaderSize": "2000000", + "maxProposalSize": "700", + "maxTxSize": "4096", + "mpcThd": "20000000000000", + "scriptVersion": 0, + "slotDuration": "20000", + "softforkRule": { + "initThd": "900000000000000", + "minThd": "600000000000000", + "thdDecrement": "50000000000000" + }, + "txFeePolicy": { + "multiplier": "43946000000", + "summand": "155381000000000" + }, + "unlockStakeEpoch": "18446744073709551615", + "updateImplicit": "10000", + "updateProposalThd": "100000000000000", + "updateVoteThd": "1000000000000" + }, + "bootStakeholders": { + "fa162b170225a4fbcf529680a328e098532321d558c8c11ab90ad467": 1 + }, + "heavyDelegation": { + "fa162b170225a4fbcf529680a328e098532321d558c8c11ab90ad467": { + "cert": "5f18bcc1638406d3176cae2c1c9a6f5bc4e8faade50d300aa38bcf50d91fe1181d010034a48f1165e611c1de88b7ec40ef8903ddd7615e65617c6b4fa73aaf0c", + "delegatePk": "YzWnXOTnYqqsdl2WZkUyqkFtx2yG+/oJKdHT0jBKzcnSMc59D/+lxjPD4kXGJYNiEluBV3QzoEh4BVi3Ibg60Q==", + "issuerPk": "CZqZfPb4AbPYsKhL072/29M9e28YFiOb8PEkScD1BcjG/k32X/8C8MakfeyR+ZJ9Ha1k4Ra0mJEDE25/ly640w==", + "omega": 0 + } + }, + "nonAvvmBalances": {}, + "protocolConsts": { + "k": 432, + "protocolMagic": 164 + }, + "startTime": 1780012800 +} diff --git a/files/configs/musashi/config.json b/files/configs/musashi/config.json new file mode 100644 index 000000000..86bfa18f2 --- /dev/null +++ b/files/configs/musashi/config.json @@ -0,0 +1,194 @@ +{ + "AlonzoGenesisFile": "/opt/cardano/cnode/files/alonzo-genesis.json", + "ByronGenesisFile": "/opt/cardano/cnode/files/byron-genesis.json", + "ConsensusMode": "PraosMode", + "ConwayGenesisFile": "/opt/cardano/cnode/files/conway-genesis.json", + "DijkstraGenesisFile": "/opt/cardano/cnode/files/dijkstra-genesis.json", + "ExperimentalHardForksEnabled": true, + "ExperimentalProtocolsEnabled": true, + "LastKnownBlockVersion-Alt": 0, + "LastKnownBlockVersion-Major": 3, + "LastKnownBlockVersion-Minor": 1, + "LedgerDB": { + "Backend": "V2InMemory", + "QueryBatchSize": 100000, + "Snapshots": { + "MaxDelay": 600, + "MinDelay": 300, + "NumOfDiskSnapshots": 2, + "RateLimit": 600, + "SnapshotInterval": 864 + } + }, + "LeiosDbConfig": { + "Backend": "SQLite", + "Filepath": "/opt/cardano/cnode/guild-db/leios.db" + }, + "MempoolCapacityBytesOverride": 67108864, + "MinNodeVersion": "11.1.0-prototype-2026w27", + "Protocol": "Cardano", + "RequiresNetworkMagic": "RequiresMagic", + "ShelleyGenesisFile": "/opt/cardano/cnode/files/shelley-genesis.json", + "TestAllegraHardForkAtEpoch": 0, + "TestAlonzoHardForkAtEpoch": 0, + "TestBabbageHardForkAtEpoch": 0, + "TestConwayHardForkAtEpoch": 0, + "TestMaryHardForkAtEpoch": 0, + "TestShelleyHardForkAtEpoch": 0, + "TraceOptionForwarder": { + "connQueueSize": 64, + "disconnQueueSize": 128, + "maxReconnectDelay": 30 + }, + "TraceOptionMetricsPrefix": "cardano.node.metrics.", + "TraceOptionResourceFrequency": 1000, + "TraceOptions": { + "": { + "backends": [ + "PrometheusSimple suffix 127.0.0.1 12798", + "Stdout MachineFormat" + ], + "detail": "DNormal", + "severity": "Notice" + }, + "BlockFetch.Client.CompletedBlockFetch": { + "severity": "Info", + "maxFrequency": 4 + }, + "BlockFetch.Decision": { + "severity": "Info" + }, + "BlockFetch.Client.SendFetchRequest": { + "severity": "Info" + }, + "ChainDB": { + "severity": "Info" + }, + "ChainDB.ImmDbEvent": { + "severity": "Warning" + }, + "ChainDB.AddBlockEvent.AddBlockValidation": { + "severity": "Silence" + }, + "ChainDB.AddBlockEvent.AddBlockValidation.ValidCandidate": { + "maxFrequency": 2 + }, + "ChainDB.AddBlockEvent.AddedBlockToQueue": { + "maxFrequency": 2 + }, + "ChainDB.AddBlockEvent.AddedBlockToVolatileDB": { + "maxFrequency": 2 + }, + "ChainDB.AddBlockEvent.AddedToCurrentChain": { + "maxFrequency": 2 + }, + "ChainDB.AddBlockEvent.SwitchedToAFork": { + "severity": "Info" + }, + "ChainDB.ImmDbEvent.ChunkValidation.ValidatedChunk": { + "severity": "Info" + }, + "ChainDB.CopyToImmutableDBEvent.CopiedBlockToImmutableDB": { + "maxFrequency": 2 + }, + "ChainDB.LedgerEvent.Replay": { + "severity": "Info", + "maxFrequency": 0.0668 + }, + "ChainDB.LedgerEvent.Forker": { + "severity": "Silence" + }, + "ChainSync.Client": { + "severity": "Warning" + }, + "ChainSync.Client.DownloadedHeader": { + "severity": "Info", + "maxFrequency": 14 + }, + "Forge.Loop": { + "severity": "Info" + }, + "Forge.Loop.NodeNotLeader": { + "severity": "Silence" + }, + "Forge.Loop.StartLeadershipCheck": { + "severity": "Silence" + }, + "Forge.StateInfo": { + "severity": "Info", + "maxFrequency": 0.0002783 + }, + "Mempool": { + "severity": "Silence" + }, + "Net.AcceptPolicy.ConnectionRateLimiting": { + "severity": "Info", + "maxFrequency": 0.0167 + }, + "Net.AcceptPolicy.ConnectionLimitResume": { + "severity": "Info", + "maxFrequency": 0.0167 + }, + "Net.ConnectionManager.Remote": { + "severity": "Info" + }, + "Net.ErrorPolicy": { + "severity": "Info" + }, + "Net.InboundGovernor": { + "severity": "Warning" + }, + "Net.InboundGovernor.Remote.InboundGovernorCounters": { + "severity": "Info", + "maxFrequency": 0.0167 + }, + "Net.InboundGovernor.Remote": { + "severity": "Info" + }, + "Net.Mux.Remote": { + "severity": "Info" + }, + "Net.PeerSelection": { + "severity": "Info" + }, + "Net.PeerSelection.Actions.ConnectionError": { + "severity": "Silence" + }, + "Resources": { + "severity": "Info", + "maxFrequency": 0.0167 + }, + "Startup": { + "severity": "Info" + }, + "Consensus.LeiosKernel": { + "maxFrequency": 0, + "severity": "Debug" + }, + "Consensus.LeiosPeer": { + "maxFrequency": 0, + "severity": "Debug" + }, + "LeiosFetch.Remote": { + "maxFrequency": 0, + "severity": "Debug" + }, + "LeiosNotify.Remote": { + "maxFrequency": 0, + "severity": "Debug" + }, + "Mempool.AttemptAdd": { + "severity": "Silence" + }, + "Mempool.SyncNotNeeded": { + "severity": "Silence" + }, + "Startup.DiffusionInit": { + "severity": "Info" + } + }, + "TurnOnLogMetrics": true, + "TurnOnLogging": true, + "UseTraceDispatcher": true, + "TraceOptionNodeName": "cnode" +} diff --git a/files/configs/musashi/conway-genesis.json b/files/configs/musashi/conway-genesis.json new file mode 100644 index 000000000..03b86c6d1 --- /dev/null +++ b/files/configs/musashi/conway-genesis.json @@ -0,0 +1,299 @@ +{ + "committee": { + "members": { + "keyHash-0104305319ac0db0b79488982e6f0529e97326606d9fe060fb3d7f48": 293, + "keyHash-82027345b779d2735d01034626ad60f493c198dc9d30e689c087f4d2": 293, + "keyHash-90ef1da09e08cf6660e833ca057b06a4f30cca5f972683f189a8b587": 293 + }, + "threshold": { + "denominator": 3, + "numerator": 2 + } + }, + "committeeMaxTermLength": 293, + "committeeMinSize": 3, + "constitution": { + "anchor": { + "dataHash": "2a61e2f4b63442978140c77a70daab3961b22b12b63b13949a390c097214d1c5", + "url": "ipfs://bafkreiazhhawe7sjwuthcfgl3mmv2swec7sukvclu3oli7qdyz4uhhuvmy" + }, + "script": "fa24fb305126805cf2164c161d852a0e7330cf988f1fe558cf7d4a64" + }, + "dRepActivity": 20, + "dRepDeposit": 500000000, + "dRepVotingThresholds": { + "committeeNoConfidence": 0.6, + "committeeNormal": 0.67, + "hardForkInitiation": 0.6, + "motionNoConfidence": 0.67, + "ppEconomicGroup": 0.67, + "ppGovGroup": 0.75, + "ppNetworkGroup": 0.67, + "ppTechnicalGroup": 0.67, + "treasuryWithdrawal": 0.67, + "updateToConstitution": 0.75 + }, + "govActionDeposit": 100000000000, + "govActionLifetime": 30, + "minFeeRefScriptCostPerByte": 15, + "plutusV3CostModel": [ + 100788, + 420, + 1, + 1, + 1000, + 173, + 0, + 1, + 1000, + 59957, + 4, + 1, + 11183, + 32, + 201305, + 8356, + 4, + 16000, + 100, + 16000, + 100, + 16000, + 100, + 16000, + 100, + 16000, + 100, + 16000, + 100, + 100, + 100, + 16000, + 100, + 94375, + 32, + 132994, + 32, + 61462, + 4, + 72010, + 178, + 0, + 1, + 22151, + 32, + 91189, + 769, + 4, + 2, + 85848, + 123203, + 7305, + -900, + 1716, + 549, + 57, + 85848, + 0, + 1, + 1, + 1000, + 42921, + 4, + 2, + 24548, + 29498, + 38, + 1, + 898148, + 27279, + 1, + 51775, + 558, + 1, + 39184, + 1000, + 60594, + 1, + 141895, + 32, + 83150, + 32, + 15299, + 32, + 76049, + 1, + 13169, + 4, + 22100, + 10, + 28999, + 74, + 1, + 28999, + 74, + 1, + 43285, + 552, + 1, + 44749, + 541, + 1, + 33852, + 32, + 68246, + 32, + 72362, + 32, + 7243, + 32, + 7391, + 32, + 11546, + 32, + 85848, + 123203, + 7305, + -900, + 1716, + 549, + 57, + 85848, + 0, + 1, + 90434, + 519, + 0, + 1, + 74433, + 32, + 85848, + 123203, + 7305, + -900, + 1716, + 549, + 57, + 85848, + 0, + 1, + 1, + 85848, + 123203, + 7305, + -900, + 1716, + 549, + 57, + 85848, + 0, + 1, + 955506, + 213312, + 0, + 2, + 270652, + 22588, + 4, + 1457325, + 64566, + 4, + 20467, + 1, + 4, + 0, + 141992, + 32, + 100788, + 420, + 1, + 1, + 81663, + 32, + 59498, + 32, + 20142, + 32, + 24588, + 32, + 20744, + 32, + 25933, + 32, + 24623, + 32, + 43053543, + 10, + 53384111, + 14333, + 10, + 43574283, + 26308, + 10, + 16000, + 100, + 16000, + 100, + 962335, + 18, + 2780678, + 6, + 442008, + 1, + 52538055, + 3756, + 18, + 267929, + 18, + 76433006, + 8868, + 18, + 52948122, + 18, + 1995836, + 36, + 3227919, + 12, + 901022, + 1, + 166917843, + 4307, + 36, + 284546, + 36, + 158221314, + 26549, + 36, + 74698472, + 36, + 333849714, + 1, + 254006273, + 72, + 2174038, + 72, + 2261318, + 64571, + 4, + 207616, + 8310, + 4, + 1293828, + 28716, + 63, + 0, + 1, + 1006041, + 43623, + 251, + 0, + 1 + ], + "poolVotingThresholds": { + "committeeNoConfidence": 0.51, + "committeeNormal": 0.51, + "hardForkInitiation": 0.51, + "motionNoConfidence": 0.51, + "ppSecurityGroup": 0.51 + } +} diff --git a/files/configs/musashi/db-sync-config.json b/files/configs/musashi/db-sync-config.json new file mode 100644 index 000000000..ec3f644f4 --- /dev/null +++ b/files/configs/musashi/db-sync-config.json @@ -0,0 +1,139 @@ +{ + "EnableFutureGenesis": true, + "EnableLogMetrics": false, + "EnableLogging": true, + "NetworkName": "musashi", + "NodeConfigFile": "/opt/cardano/cnode/files/config.json", + "PrometheusPort": 8080, + "RequiresNetworkMagic": "RequiresMagic", + "defaultBackends": [ + "KatipBK" + ], + "defaultScribes": [ + [ + "StdoutSK", + "stdout" + ] + ], + "insert_options": { + "tx_out": { + "value": "consumed", + "use_address_table": true + }, + "ledger": "enable", + "shelley": { + "enable": true + }, + "multi_asset": { + "enable": true + }, + "metadata": { + "enable": true + }, + "plutus": { + "enable": true + }, + "governance": "enable", + "json_type": "text", + "offchain_pool_data": "enable", + "offchain_vote_data": "enable", + "pool_stat": "enable", + "tx_cbor": "enable" + }, + "ledger_backend": "inmemory", + "snapshot_interval": { + "near_tip_epoch": 1216 + }, + "minSeverity": "Info", + "options": { + "cfokey": { + "value": "Release-1.0.0" + }, + "mapBackends": {}, + "mapSeverity": { + "db-sync-node": "Info", + "db-sync-node.Mux": "Error", + "db-sync-node.Subscription": "Error" + }, + "mapSubtrace": { + "#ekgview": { + "contents": [ + [ + { + "contents": "cardano.epoch-validation.benchmark", + "tag": "Contains" + }, + [ + { + "contents": ".monoclock.basic.", + "tag": "Contains" + } + ] + ], + [ + { + "contents": "cardano.epoch-validation.benchmark", + "tag": "Contains" + }, + [ + { + "contents": "diff.RTS.cpuNs.timed.", + "tag": "Contains" + } + ] + ], + [ + { + "contents": "#ekgview.#aggregation.cardano.epoch-validation.benchmark", + "tag": "StartsWith" + }, + [ + { + "contents": "diff.RTS.gcNum.timed.", + "tag": "Contains" + } + ] + ] + ], + "subtrace": "FilterTrace" + }, + "#messagecounters.aggregation": { + "subtrace": "NoTrace" + }, + "#messagecounters.ekgview": { + "subtrace": "NoTrace" + }, + "#messagecounters.katip": { + "subtrace": "NoTrace" + }, + "#messagecounters.monitoring": { + "subtrace": "NoTrace" + }, + "#messagecounters.switchboard": { + "subtrace": "NoTrace" + }, + "benchmark": { + "contents": [ + "GhcRtsStats", + "MonotonicClock" + ], + "subtrace": "ObservableTrace" + }, + "cardano.epoch-validation.utxo-stats": { + "subtrace": "NoTrace" + } + } + }, + "setupBackends": [ + "AggregationBK", + "KatipBK" + ], + "setupScribes": [ + { + "scFormat": "ScText", + "scKind": "StdoutSK", + "scName": "stdout", + "scRotation": null + } + ] +} diff --git a/files/configs/musashi/dijkstra-genesis.json b/files/configs/musashi/dijkstra-genesis.json new file mode 100644 index 000000000..d73d2ab2c --- /dev/null +++ b/files/configs/musashi/dijkstra-genesis.json @@ -0,0 +1,6 @@ +{ + "maxRefScriptSizePerBlock": 1048576, + "maxRefScriptSizePerTx": 204800, + "refScriptCostMultiplier": 1.2, + "refScriptCostStride": 25600 +} diff --git a/files/configs/musashi/peer-snapshot.json b/files/configs/musashi/peer-snapshot.json new file mode 100644 index 000000000..b6ccde2ad --- /dev/null +++ b/files/configs/musashi/peer-snapshot.json @@ -0,0 +1,40 @@ +{ + "NetworkMagic": 164, + "NodeToClientVersion": 23, + "Point": { + "blockPointHash": "3ad6691278480d96db28f28f6c6ff07aba2bc207c817be5d96f0ba3f4748f598", + "blockPointSlot": 173878 + }, + "bigLedgerPools": [ + { + "accumulatedStake": 0.3548387096774194, + "relativeStake": 0.3548387096774194, + "relays": [ + { + "address": "leios-node.play.dev.cardano.org", + "port": 3001 + } + ] + }, + { + "accumulatedStake": 0.6774193548387096, + "relativeStake": 0.3225806451612903, + "relays": [ + { + "address": "leios-node.play.dev.cardano.org", + "port": 3001 + } + ] + }, + { + "accumulatedStake": 1, + "relativeStake": 0.3225806451612903, + "relays": [ + { + "address": "leios-node.play.dev.cardano.org", + "port": 3001 + } + ] + } + ] +} diff --git a/files/configs/musashi/shelley-genesis.json b/files/configs/musashi/shelley-genesis.json new file mode 100644 index 000000000..dd8098e33 --- /dev/null +++ b/files/configs/musashi/shelley-genesis.json @@ -0,0 +1,78 @@ +{ + "activeSlotsCoeff": 0.050, + "epochLength": 86400, + "genDelegs": { + "247729d400e71eb811fde803ecc6ddb1e82cc15f38dea24ea6b77724": { + "delegate": "c999fea0b813f2ec4f773e46d5d3acbc7def593e24d115902b515bb6", + "vrf": "708757d2d09053edf401c668c4af2fae3e8979acd3caa90fc6bb6fc9fcbea687" + }, + "61c3dc01a3af5ec417b7c72c0993ad10f2c9195ee1d8f44ae51baf22": { + "delegate": "f94c5360b9e8a4f9f9dc20710e9159871ecf0d3f44b1ff7c2a20b33b", + "vrf": "d98d049e2d0504544bff85db06c87777f734ba9132c0531ea423b31cc09334cf" + }, + "e5e238cb081c4b930a0438fbdfea28c108b2c572b54ca5f0bc4f449f": { + "delegate": "555fb39dca1b668fd95eb39b7dd79dfb76a96dac43f68a1c536048cd", + "vrf": "0492690e529498ccdb45174d90eb8aab7ce02c963e1f59cbaeb90fb41f2b502b" + } + }, + "initialFunds": { + "004b27a251d23c51a361ca99fc6cf088e723cda9ff10cf49b1dfc858f55e83190aa60e7892f18628a79fda535ef804b8e927ce7463224aa567": 900000000, + "60353dfa8f7a333c0f4428730951eb48a0e194a4725616752a079127dd": 30000000000000000 + }, + "maxKESEvolutions": 62, + "maxLovelaceSupply": 45000000000000000, + "networkId": "Testnet", + "networkMagic": 164, + "protocolParams": { + "a0": 0.3, + "decentralisationParam": 1, + "eMax": 18, + "extraEntropy": { + "tag": "NeutralNonce" + }, + "keyDeposit": 2000000, + "maxBlockBodySize": 90112, + "maxBlockHeaderSize": 1100, + "maxTxSize": 16384, + "minFeeA": 44, + "minFeeB": 155381, + "minPoolCost": 170000000, + "minUTxOValue": 1000000, + "nOpt": 150, + "poolDeposit": 500000000, + "protocolVersion": { + "major": 11, + "minor": 0 + }, + "rho": 0.0030, + "tau": 0.2 + }, + "securityParam": 432, + "slotLength": 1, + "slotsPerKESPeriod": 129600, + "staking": { + "pools": { + "3da8d5ba744b36249e8f9c9afa4ac27dbc1d2725223f197e90cbbe11": { + "accountAddress": { + "credential": { + "keyHash": "e01bfa9397ff5c737a394e635ce15b17455fdd42405bfbc4044d9b4a" + }, + "network": "Testnet" + }, + "cost": 0, + "margin": 0, + "metadata": null, + "owners": [], + "pledge": 0, + "poolId": "3da8d5ba744b36249e8f9c9afa4ac27dbc1d2725223f197e90cbbe11", + "relays": [], + "vrf": "adab17419d1f92c9c4e79f50a821256e272b0d7a1461d3c102b6b9a6fcf27916" + } + }, + "stake": { + "5e83190aa60e7892f18628a79fda535ef804b8e927ce7463224aa567": "3da8d5ba744b36249e8f9c9afa4ac27dbc1d2725223f197e90cbbe11" + } + }, + "systemStart": "2026-05-29T00:00:00Z", + "updateQuorum": 3 +} diff --git a/files/configs/musashi/submitapi.json b/files/configs/musashi/submitapi.json new file mode 100644 index 000000000..fb8645283 --- /dev/null +++ b/files/configs/musashi/submitapi.json @@ -0,0 +1,36 @@ +{ + "EnableLogMetrics": false, + "EnableLogging": true, + "TraceOptions": { + "": { + "backends": [ + "EKGBackend", + "Stdout HumanFormatColoured" + ], + "detail": "DNormal", + "severity": "Info" + } + }, + "defaultBackends": [ + "KatipBK" + ], + "defaultScribes": [ + [ + "StdoutSK", + "stdout" + ] + ], + "setupBackends": [ + "KatipBK" + ], + "minSeverity": "Trace", + "options": {}, + "setupScribes": [ + { + "scFormat": "ScText", + "scKind": "StdoutSK", + "scName": "stdout", + "scRotation": null + } + ] +} diff --git a/files/configs/musashi/topology.json b/files/configs/musashi/topology.json new file mode 100644 index 000000000..ae68d0fd9 --- /dev/null +++ b/files/configs/musashi/topology.json @@ -0,0 +1,41 @@ +{ + "bootstrapPeers": [ + { + "address": "leios-node.play.dev.cardano.org", + "port": 3001 + } + ], + "localRoots": [ + { + "accessPoints": [ + { + "address": "127.0.0.1", + "port": 6000, + "description": "replace-this-with-BP" + }, + { + "address": "127.0.0.1", + "port": 6001, + "description": "replace-this-with-relay" + } + ], + "advertise": false, + "trustable": true, + "hotValency": 2 + }, + { + "accessPoints": [], + "advertise": false, + "trustable": false, + "valency": 1 + } + ], + "peerSnapshotFile": "peer-snapshot.json", + "publicRoots": [ + { + "accessPoints": [], + "advertise": false + } + ], + "useLedgerAfterSlot": 1000 +} diff --git a/files/docker/node/addons/entrypoint.sh b/files/docker/node/addons/entrypoint.sh index 677812a93..921b2eca2 100755 --- a/files/docker/node/addons/entrypoint.sh +++ b/files/docker/node/addons/entrypoint.sh @@ -56,11 +56,11 @@ if [[ -n "${NETWORK}" ]] ; then load_configs fi else - echo "Please set a NETWORK environment variable to one of: mainnet / preview / preprod / guild-mainnet / guild" + echo "Please set a NETWORK environment variable to one of: mainnet / preview / preprod / guild-mainnet / guild / musashi" echo "mount a '$CNODE_HOME/priv/files' volume containing: mainnet-config.json, mainnet-shelley-genesis.json, mainnet-byron-genesis.json, and mainnet-topology.json " echo "for active nodes set POOL_DIR environment variable where op.cert, hot.skey and vrf.skey files reside. (usually under '${CNODE_HOME}/priv/pool/$POOL_NAME' ) " echo "or just set POOL_NAME environment variable (for default path). " fi customise \ -&& exec "$CNODE_HOME/scripts/$ENTRYPOINT_PROCESS" "$@" \ No newline at end of file +&& exec "$CNODE_HOME/scripts/$ENTRYPOINT_PROCESS" "$@" diff --git a/scripts/cnode-helper-scripts/env b/scripts/cnode-helper-scripts/env index b1342c581..8254bf2ce 100644 --- a/scripts/cnode-helper-scripts/env +++ b/scripts/cnode-helper-scripts/env @@ -1121,18 +1121,21 @@ if ! command -v "jq" &>/dev/null; then fi read -ra CONFIG_CONTENTS <<<"$(jq -r '[ .AlonzoGenesisFile //"null", .ByronGenesisFile //"null", .ShelleyGenesisFile //"null", .Protocol //"Cardano", -.ConwayGenesisFile //"null"]| @tsv' "${CONFIG}" 2>/dev/null)" +.ConwayGenesisFile //"null", .DijkstraGenesisFile //"null"]| @tsv' "${CONFIG}" 2>/dev/null)" +DIJKSTRA_GENESIS_JSON="${CONFIG_CONTENTS[5]}" CONWAY_GENESIS_JSON="${CONFIG_CONTENTS[4]}" ALONZO_GENESIS_JSON="${CONFIG_CONTENTS[0]}" BYRON_GENESIS_JSON="${CONFIG_CONTENTS[1]}" GENESIS_JSON="${CONFIG_CONTENTS[2]}" # if relative path is used, assume same parent dir as config +[[ ${DIJKSTRA_GENESIS_JSON} != "null" && ! ${DIJKSTRA_GENESIS_JSON} =~ ^/ ]] && DIJKSTRA_GENESIS_JSON="$(dirname "${CONFIG}")/${DIJKSTRA_GENESIS_JSON}" [[ ! ${CONWAY_GENESIS_JSON} =~ ^/ ]] && CONWAY_GENESIS_JSON="$(dirname "${CONFIG}")/${CONWAY_GENESIS_JSON}" [[ ! ${ALONZO_GENESIS_JSON} =~ ^/ ]] && ALONZO_GENESIS_JSON="$(dirname "${CONFIG}")/${ALONZO_GENESIS_JSON}" [[ ! ${BYRON_GENESIS_JSON} =~ ^/ ]] && BYRON_GENESIS_JSON="$(dirname "${CONFIG}")/${BYRON_GENESIS_JSON}" [[ ! ${GENESIS_JSON} =~ ^/ ]] && GENESIS_JSON="$(dirname "${CONFIG}")/${GENESIS_JSON}" # if genesis files not found, exit with rc 1 +[[ ${DIJKSTRA_GENESIS_JSON} != "null" && ! -f "${DIJKSTRA_GENESIS_JSON}" ]] && echo "Dijkstra genesis file not found: ${DIJKSTRA_GENESIS_JSON}" && return 1 [[ ! -f "${CONWAY_GENESIS_JSON}" ]] && echo "Conway genesis file not found: ${CONWAY_GENESIS_JSON}" && return 1 [[ ! -f "${ALONZO_GENESIS_JSON}" ]] && echo "Alonzo genesis file not found: ${ALONZO_GENESIS_JSON}" && return 1 [[ ! -f "${BYRON_GENESIS_JSON}" ]] && echo "Byron genesis file not found: ${BYRON_GENESIS_JSON}" && return 1 @@ -1194,6 +1197,9 @@ case ${NWMAGIC} in [[ -z ${NETWORK_NAME} ]] && NETWORK_NAME="Preview" [[ -z ${SHELLEY_TRANS_EPOCH} ]] && SHELLEY_TRANS_EPOCH=0 [[ -z ${KOIOS_API} ]] && KOIOS_API="https://preview.koios.rest/api/v1";; + 164) + [[ -z ${NETWORK_NAME} ]] && NETWORK_NAME="Musashi" + [[ -z ${SHELLEY_TRANS_EPOCH} ]] && SHELLEY_TRANS_EPOCH=0;; *) [[ -z ${NETWORK_NAME} ]] && NETWORK_NAME="Custom" [[ -z ${SHELLEY_TRANS_EPOCH} ]] && SHELLEY_TRANS_EPOCH=0 diff --git a/scripts/cnode-helper-scripts/guild-deploy.sh b/scripts/cnode-helper-scripts/guild-deploy.sh index 0d1fc39ee..200e2ab80 100644 --- a/scripts/cnode-helper-scripts/guild-deploy.sh +++ b/scripts/cnode-helper-scripts/guild-deploy.sh @@ -22,6 +22,7 @@ #UPDATE_CHECK='Y' # Check if there is an updated version of guild-deploy.sh script to download #SUDO='Y' # Used by docker builds to disable sudo, leave unchanged if unsure. #SKIP_DBSYNC_DOWNLOAD='N' # When using -i d switch, used by docker builds or users who might not want to download dbsync binary +#LEIOS_NODE_VERSION='latest' # Leios prototype release tag used for NETWORK=musashi with -s d. Set to 'latest' to resolve newest release. ###################################### # Do NOT modify code below # ###################################### @@ -159,7 +160,7 @@ err_exit() { usage() { cat <<-EOF >&2 - Usage: $(basename "$0") [-n ] [-p path] [-t ] [-b ] [-u] [-s [p][b][l][m][d][c][o][w][x][f][s]] + Usage: $(basename "$0") [-n ] [-p path] [-t ] [-b ] [-u] [-s [p][b][l][m][d][c][o][w][x][f][s]] Set up dependencies for building/using common tools across cardano ecosystem. The script will always update dynamic content from existing scripts retaining existing user variables @@ -173,7 +174,7 @@ usage() { b Install OS level dependencies for tools required while building cardano-node/cardano-db-sync components (Default: skip) l Build and Install libsodium fork from IO repositories (Default: skip) m Download latest (released) binaries for mithril-signer, mithril-client (Default: skip) - d Download latest (released) binaries for bech32, cardano-address, cardano-node, cardano-cli, cardano-db-sync and cardano-submit-api (Default: skip) + d Download latest (released) binaries for bech32, cardano-address, cardano-node, cardano-cli, cardano-db-sync and cardano-submit-api; for musashi, download Leios cardano-node/cardano-cli only (Default: skip) c Download latest (released) binaries for CNCLI (Default: skip) o Download latest (released) binaries for Ogmios (Default: skip) w Download latest (released) binaries for Cardano Hardware CLI (Default: skip) @@ -207,6 +208,7 @@ set_defaults() { [[ -z ${SKIP_DBSYNC_DOWNLOAD} ]] && SKIP_DBSYNC_DOWNLOAD='N' [[ -z ${SUDO} ]] && SUDO='Y' [[ -z "${BRANCH}" ]] && BRANCH="master" + [[ "${NETWORK}" == "musashi" && -z "${LEIOS_NODE_VERSION}" ]] && LEIOS_NODE_VERSION="latest" [[ "${SUDO}" = 'Y' ]] && sudo="sudo" || sudo="" [[ "${SUDO}" = 'Y' && $(id -u) -eq 0 ]] && err_exit "Please run as non-root user." [[ -z "${CARDANO_NODE_VERSION}" ]] && CARDANO_NODE_VERSION="$(curl -sfk "https://raw.githubusercontent.com/${G_ACCOUNT}/guild-operators/${BRANCH}/files/docker/node/release-versions/cardano-node-latest.txt" || echo "10.6.2")" @@ -590,6 +592,43 @@ download_cnodebins() { log_ok "Deployed cardano-address" "${CADDR_VERSION}" } +resolve_leios_node_version() { + [[ "${LEIOS_NODE_VERSION}" != "latest" ]] && return 0 + log_progress "Resolving latest Leios node release" + LEIOS_NODE_VERSION="$(curl -s -f -m ${CURL_TIMEOUT} https://api.github.com/repos/input-output-hk/ouroboros-leios/releases | jq -r ' + [.[] | + select(.draft == false) | + select(.tag_name | test("^prototype-[0-9]{4}w[0-9]+$")) | + select(any(.assets[]?; .name == "cardano-node-leios-x86_64-linux.tar.gz")) + ][0].tag_name // empty + ' 2>/dev/null)" + [[ -n "${LEIOS_NODE_VERSION}" ]] || err_exit "Could not resolve latest Leios release with a Linux x86_64 node archive from GitHub." + log_ok "Resolved Leios node release" "${LEIOS_NODE_VERSION}" +} + +download_leios_cnodebins() { + [[ -z ${ARCH##*aarch64*} ]] && err_exit "The Leios pre-built Linux binary is only available for x86_64; use the Leios Nix flow or build it manually on ARM." + local leios_archive="cardano-node-leios-x86_64-linux.tar.gz" + resolve_leios_node_version + local leios_release_url="https://github.com/input-output-hk/ouroboros-leios/releases/download/${LEIOS_NODE_VERSION}/${leios_archive}" + pushd "${HOME}"/tmp >/dev/null || err_exit "Could not enter temporary directory: ${HOME}/tmp" + rm -rf leios-node-bin && mkdir leios-node-bin + pushd leios-node-bin >/dev/null || err_exit "Could not enter temporary Leios binary directory." + log_progress "Downloading Leios cardano-node/cardano-cli" "${LEIOS_NODE_VERSION}" + curl -m 200 -sfL "${leios_release_url}" -o "${leios_archive}" || err_exit "Could not download Leios node release ${LEIOS_NODE_VERSION} from GitHub." + tar zxf "${leios_archive}" &>/dev/null || err_exit "Could not extract Leios node release ${LEIOS_NODE_VERSION}." + leios_node_path="$(find . -type f -name cardano-node | head -n 1)" + leios_cli_path="$(find . -type f -name cardano-cli | head -n 1)" + [[ -n "${leios_node_path}" ]] || err_exit "Leios archive downloaded, but binary 'cardano-node' was not found after extraction." + [[ -n "${leios_cli_path}" ]] || err_exit "Leios archive downloaded, but binary 'cardano-cli' was not found after extraction." + mv -f "${leios_node_path}" "${HOME}"/.local/bin/cardano-node + mv -f "${leios_cli_path}" "${HOME}"/.local/bin/cardano-cli + chmod +x "${HOME}"/.local/bin/cardano-node "${HOME}"/.local/bin/cardano-cli + log_ok "Deployed Leios cardano-node" "${LEIOS_NODE_VERSION}" + log_ok "Deployed Leios cardano-cli" "${LEIOS_NODE_VERSION}" + log_info "Leios does not currently provide supported cardano-submit-api or cardano-db-sync binaries; config files are deployed for future use." +} + # Download CNCLI download_cncli() { [[ -z ${ARCH##*aarch64*} ]] && err_exit "The CNCLI pre-compiled binary is not available for ARM; build it manually instead." @@ -841,34 +880,45 @@ populate_cnode() { #NWCONFURL="https://raw.githubusercontent.com/input-output-hk/cardano-playground/main/static/book.play.dev.cardano.org/environments" NWCONFURL="${URL_RAW}/files/configs/${NETWORK}/" #CHKPTURL="https://book.play.dev.cardano.org/environments/${NETWORK}/checkpoints.json" - if [[ ${NETWORK} =~ ^(mainnet|preprod|preview|guild)$ ]]; then + if [[ ${NETWORK} =~ ^(mainnet|preprod|preview|guild|musashi)$ ]]; then curl -sL -f -m ${CURL_TIMEOUT} -o alonzo-genesis.json.tmp "${NWCONFURL}/alonzo-genesis.json" || err_exit "${err_msg} alonzo-genesis.json" curl -sL -f -m ${CURL_TIMEOUT} -o byron-genesis.json.tmp "${NWCONFURL}/byron-genesis.json" || err_exit "${err_msg} byron-genesis.json" curl -sL -f -m ${CURL_TIMEOUT} -o conway-genesis.json.tmp "${NWCONFURL}/conway-genesis.json" || err_exit "${err_msg} conway-genesis.json" curl -sL -f -m ${CURL_TIMEOUT} -o shelley-genesis.json.tmp "${NWCONFURL}/shelley-genesis.json" || err_exit "${err_msg} shelley-genesis.json" + if [[ ${NETWORK} == "musashi" ]]; then + curl -sL -f -m ${CURL_TIMEOUT} -o dijkstra-genesis.json.tmp "${NWCONFURL}/dijkstra-genesis.json" || err_exit "${err_msg} dijkstra-genesis.json" + curl -sL -f -m ${CURL_TIMEOUT} -o peer-snapshot.json.tmp "${NWCONFURL}/peer-snapshot.json" || err_exit "${err_msg} peer-snapshot.json" + fi curl -sL -f -m ${CURL_TIMEOUT} -o topology.json.tmp "${NWCONFURL}/topology.json" || err_exit "${err_msg} topology.json" curl -sL -f -m ${CURL_TIMEOUT} -o config.json.tmp "${NWCONFURL}/config.json" || err_exit "${err_msg} config.json" curl -sL -f -m ${CURL_TIMEOUT} -o dbsync.json.tmp "${NWCONFURL}/db-sync-config.json" || err_exit "${err_msg} dbsync-sync-config.json" curl -sL -f -m ${CURL_TIMEOUT} -o submitapi.json "${NWCONFURL}/submitapi.json" || err_exit "${err_msg} submitapi.json" #curl -sL -m ${CURL_TIMEOUT} -o checkpoints.json "${CHKPTURL}" || err_exit "${err_msg} checkpoints.json" else - err_exit "Unknown network specified! Kindly re-check the network name, valid options are: mainnet, guild, preprod, or preview." + err_exit "Unknown network specified! Kindly re-check the network name, valid options are: mainnet, guild, preprod, preview, or musashi." fi log_ok "Network configuration downloaded" "${NETWORK}" sed -e "s@/opt/cardano/cnode@${CNODE_HOME}@g" -i ./*.json.tmp sed -e "s@\"TraceOptionNodeName\": \"cnode\"@\"TraceOptionNodeName\": \"${CNODE_NAME}\"@" -i ./config.json.tmp + local missing_config="N" + [[ ! -f byron-genesis.json || ! -f shelley-genesis.json || ! -f alonzo-genesis.json || ! -f topology.json || ! -f config.json || ! -f dbsync.json ]] && missing_config="Y" + [[ ${NETWORK} == "musashi" && ( ! -f dijkstra-genesis.json || ! -f peer-snapshot.json ) ]] && missing_config="Y" if [[ ${FORCE_OVERWRITE} = 'Y' ]]; then [[ -f topology.json ]] && cp -f topology.json "topology.json_bkp$(date +%s)" [[ -f config.json ]] && cp -f config.json "config.json_bkp$(date +%s)" [[ -f dbsync.json ]] && cp -f dbsync.json "dbsync.json_bkp$(date +%s)" + [[ -f dijkstra-genesis.json ]] && cp -f dijkstra-genesis.json "dijkstra-genesis.json_bkp$(date +%s)" + [[ -f peer-snapshot.json ]] && cp -f peer-snapshot.json "peer-snapshot.json_bkp$(date +%s)" log_info "Backed up existing topology/config/dbsync files before overwrite." fi log_progress "Applying network configuration" "${NETWORK}" - if [[ ${FORCE_OVERWRITE} = 'Y' || ! -f byron-genesis.json || ! -f shelley-genesis.json || ! -f alonzo-genesis.json || ! -f topology.json || ! -f config.json || ! -f dbsync.json ]]; then + if [[ ${FORCE_OVERWRITE} = 'Y' || ${missing_config} = 'Y' ]]; then mv -f byron-genesis.json.tmp byron-genesis.json mv -f shelley-genesis.json.tmp shelley-genesis.json mv -f alonzo-genesis.json.tmp alonzo-genesis.json mv -f conway-genesis.json.tmp conway-genesis.json + [[ ${NETWORK} == "musashi" ]] && mv -f dijkstra-genesis.json.tmp dijkstra-genesis.json + [[ ${NETWORK} == "musashi" ]] && mv -f peer-snapshot.json.tmp peer-snapshot.json mv -f topology.json.tmp topology.json mv -f config.json.tmp config.json mv -f dbsync.json.tmp dbsync.json @@ -877,6 +927,8 @@ populate_cnode() { rm -f shelley-genesis.json.tmp rm -f alonzo-genesis.json.tmp rm -f conway-genesis.json.tmp + rm -f dijkstra-genesis.json.tmp + rm -f peer-snapshot.json.tmp rm -f topology.json.tmp rm -f config.json.tmp rm -f dbsync.json.tmp @@ -951,7 +1003,13 @@ main_flow() { [[ "${LIBSODIUM_FORK}" == "Y" ]] && run_step "libsodium" "-s l" build_libsodium [[ "${INSTALL_MITHRIL}" == "Y" ]] && run_step "Mithril binaries" "-s m" download_mithril [[ "${POPULATE_CNODE}" == "Y" ]] && run_step "Scripts and configuration" "default/-s f/s" populate_cnode - [[ "${INSTALL_CNODEBINS}" == "Y" ]] && run_step "Cardano node binaries" "-s d" download_cnodebins + if [[ "${INSTALL_CNODEBINS}" == "Y" ]]; then + if [[ "${NETWORK}" == "musashi" ]]; then + run_step "Cardano Leios node binaries" "-s d" download_leios_cnodebins + else + run_step "Cardano node binaries" "-s d" download_cnodebins + fi + fi [[ "${INSTALL_CNCLI}" == "Y" ]] && run_step "CNCLI" "-s c" download_cncli [[ "${INSTALL_OGMIOS}" == "Y" ]] && run_step "Ogmios" "-s o" download_ogmios [[ "${INSTALL_CWHCLI}" == "Y" ]] && run_step "Cardano hardware CLI" "-s w" download_cardanohwcli