Skip to content

Instantly share code, notes, and snippets.

@leovct
Last active June 30, 2025 15:57
Show Gist options
  • Save leovct/4ba1e5fcc5bfaf8e072a40469b19b8d5 to your computer and use it in GitHub Desktop.
Save leovct/4ba1e5fcc5bfaf8e072a40469b19b8d5 to your computer and use it in GitHub Desktop.
Kurtosis CDK Cheat Sheets
############################################################
# ____ _____ ____ _ _____ __
# | _ \| ____| _ \| | / _ \ \ / /
# | | | | _| | |_) | | | | | \ V /
# | |_| | |___| __/| |__| |_| || |
# |____/|_____|_| |_____\___/ |_|
#
############################################################
# Deploy without cloning the repo.
kurtosis run --enclave cdk github.com/0xPolygon/kurtosis-cdk
kurtosis run --enclave cdk github.com/0xPolygon/kurtosis-cdk@main
kurtosis run --enclave cdk github.com/0xPolygon/[email protected]
# Deploy w/ default parameters.
kurtosis run --enclave cdk .
# Deploy w/ default parameters + on-the-fly custom args.
kurtosis run --enclave cdk . '{"deployment_stages": {"deploy_l1": false}}'
# Deploy w/ config file.
kurtosis run --enclave cdk --args-file params.yml .
# Default w/ config file + on-the-fly custom args.
# 🚨 Avoid using this method, as Kurtosis is unable to merge parameters from two different sources (the parameters file and on-the-fly arguments).
# The parameters file will not be used, and only the on-the-fly arguments will be considered.
kurtosis run --enclave cdk --args-file params.yml . '{"args": {"agglayer_image": "debian"}}'
# Similar to: kurtosis run --enclave cdk . '{"args": {"agglayer_image": "debian"}}'
# Clean up: remove all enclaves (stopped but also running).
kurtosis clean --all
# Restart the kurtosis engine.
# If this doesn't work, you may need to restart the docker daemon!
kurtosis engine restart
############################################################
# ____ _____ ____ _ _ ____
# | _ \| ____| __ )| | | |/ ___|
# | | | | _| | _ \| | | | | _
# | |_| | |___| |_) | |_| | |_| |
# |____/|_____|____/ \___/ \____|
#
############################################################
# View the state of the enclave, all the services and the endpoints.
kurtosis enclave inspect cdk
# Follow the logs of a service.
kurtosis service logs cdk cdk-erigon-sequencer-001 --follow
# Get a shell inside a service.
kurtosis service shell cdk cdk-erigon-sequencer-001
# Execute a command inside a service.
# Example: Get the output of the zkevm-contracts deployment on L1.
kurtosis service exec cdk contracts-001 'cat /opt/zkevm/combined.json' | tail -n +2 | jq
# Stop/Start a service.
kurtosis service stop cdk cdk-erigon-sequencer-001
kurtosis service start cdk cdk-erigon-sequencer-001
# Get a specific endpoint.
kurtosis port print cdk cdk-erigon-node-001 http-rpc
# Inspect a file artifact.
kurtosis files inspect cdk cdk-erigon-node-config-artifact-sequencer config.yaml
# Download a file artifact.
kurtosis files download cdk cdk-erigon-node-config-artifact
# Upload a file artifact.
kurtosis files upload cdk --name my-config-artifact ./my-config.yaml
############################################################
# _ ___ _ _ _____
# | | |_ _| \ | |_ _|
# | | | || \| | | |
# | |___ | || |\ | | |
# |_____|___|_| \_| |_|
#
############################################################
# Run kurtosis linter.
kurtosis lint --format .
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment