-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Component TOMLs #14
Comments
refcell
added
C-feature
Category: Features
A-config
Area: configuration file crate
labels
Oct 2, 2023
LMK what y'all think @clabby @merklefruit. I'm not sure I like the inlined docker fields, but not sure as of yet how to do better. |
Looks good already! Just a few thoughts:
|
Merged
What do you think about putting the components in the same toml config but different keys? One key per op component [challenger]
[[metadata]]
name = "challenger-go"
version = "1.1.2"
[[command]]
git = "[email protected]:ethereum-optimism/optimism.git"
# Default test hardhat deploy key - not safe for production environments
deployer = "ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"
[[docker]]
# The remote docker url will be tried first to fetch the container.
remote = "<remote dockerhub container url>"
# If the remote field is not set, or the fetch fails, the local dockerfile will be referenced.
local = "./Dockerfile.challenger-go"
# Below are inlined docker-file specific fields that are only used if the above remote or local fields are not specified.
[[docker.build]]
base = "golang:1.19.0-alpine3.15"
dependencies = [
"make",
"gcc",
"musl-dev",
"linux-headers",
"git",
"jq",
"bash"
]
run = "make op-challenger GOOS=$TARGETOS GOARCH=$TARGETARCH"
[[docker.exec]]
base = "alpine:3.15"
command = ["/bin/sh", "/op-challenger-go-entrypoint.sh"]
[[flags]]
l1-eth-rpc = "http://l1:8545"
rollup-rpc = "http://rollup-client:8545"
l2oo-address = "$L2OO_ADDRESS"
dgf-address = "$DGF_ADDRESS" |
hmm I guess it would become quite long with a lot of containers, not sure which way is best |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
The
op_config
crate offers aConfig
TOML that allows you to configure the OP Stack.While this is useful for stack-wide configuration, op-up needs component-level TOML configs.
TOML is the config of choice to enable for configuration parsing into native rust so configs can be used as a library. This is a backwards-compatible alternative to defining custom dockerfiles for each component, and will allow for #3.
To make the TOMLs backwards-compatible, a field should allow for component TOMLs to reference base docker images or local Dockerfiles.
The TOML could look like the following
The text was updated successfully, but these errors were encountered: