From 1ec77582ba55333a01583e0e204430166ea0f8c6 Mon Sep 17 00:00:00 2001 From: Jeremy Randolph Date: Tue, 28 Nov 2023 12:08:59 -0800 Subject: [PATCH] Add sample tompl file to root of repo --- common/config/config_test.go | 8 ++++++++ example-world.toml | 17 +++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 example-world.toml diff --git a/common/config/config_test.go b/common/config/config_test.go index 3d62192..e8a202f 100644 --- a/common/config/config_test.go +++ b/common/config/config_test.go @@ -258,3 +258,11 @@ DUPLICATE = 200 assert.Check(t, err != nil, "in %q", tc.name) } } + +func TestCanParseExampleConfig(t *testing.T) { + exampleConfig := "../../example-world.toml" + cfg, err := LoadConfig(exampleConfig) + assert.NilError(t, err) + assert.Equal(t, "my-world-1", cfg.DockerEnv["CARDINAL_NAMESPACE"]) + assert.Equal(t, "world-engine", cfg.DockerEnv["CHAIN_ID"]) +} diff --git a/example-world.toml b/example-world.toml new file mode 100644 index 0000000..380d6b8 --- /dev/null +++ b/example-world.toml @@ -0,0 +1,17 @@ +# By default, the root cardinal directory is the location of this config file. The root +# directory can be changed by uncommenting this line: +# root_dir="/path/to/cardinal/" + +[cardinal] +CARDINAL_NAMESPACE="my-world-1" + +[evm] +# this value must come from the celestia client. https://docs.celestia.org/developers/node-tutorial#auth-token +DA_AUTH_TOKEN="" +DA_BASE_URL="http://celestia-devnet:26658" +DA_NAMESPACE_ID="67480c4a88c4d12935d4" +CHAIN_ID="world-engine" + # this is a test mnemonic and should not be used in production. +KEY_MNEMONIC="enact adjust liberty squirrel bulk ticket invest tissue antique window thank slam unknown fury script among bread social switch glide wool clog flag enroll" +FAUCET_ADDR="xyzzy" +BLOCK_TIME=-1