docs: describe DefaultInstance vs FirstInstance (#7487)

* docs: describe DefaultInstance vs FirstInstance

* link to docs

* add better searchable tip to the docs

* add better searchable tip to the docs

* add link
This commit is contained in:
Elio Bischof
2024-03-05 08:37:12 +01:00
committed by GitHub
parent 38777b478e
commit 3ae4e9e6cf
3 changed files with 15 additions and 0 deletions

View File

@@ -543,6 +543,11 @@ Eventstore:
# Maximum amount of push retries in case of primary key violation on the sequence # Maximum amount of push retries in case of primary key violation on the sequence
MaxRetries: 5 #ZITADEL_EVENTSTORE_MAXRETRIES MaxRetries: 5 #ZITADEL_EVENTSTORE_MAXRETRIES
# The DefaultInstance section defines the default values for each new virtual instance that is created.
# Check out https://zitadel.com/docs/concepts/structure/instance#multiple-virtual-instances for more information about virtual instances.
# For the initial setup, the default values are used to create the first instance.
# However, you might want to have your first instance created by the setup job to have a different configuration.
# To overwrite the default values for the initial setup, configure the FirstInstance yaml section and pass it using the --steps flag.
DefaultInstance: DefaultInstance:
InstanceName: ZITADEL # ZITADEL_DEFAULTINSTANCE_INSTANCENAME InstanceName: ZITADEL # ZITADEL_DEFAULTINSTANCE_INSTANCENAME
DefaultLanguage: en # ZITADEL_DEFAULTINSTANCE_DEFAULTLANGUAGE DefaultLanguage: en # ZITADEL_DEFAULTINSTANCE_DEFAULTLANGUAGE

View File

@@ -1,3 +1,4 @@
# By using the FirstInstance section, you can overwrite the DefaultInstance configuration for the first instance created by zitadel setup.
FirstInstance: FirstInstance:
# The machine key from the section FirstInstance.Org.Machine.MachineKey is written to the MachineKeyPath. # The machine key from the section FirstInstance.Org.Machine.MachineKey is written to the MachineKeyPath.
MachineKeyPath: # ZITADEL_FIRSTINSTANCE_MACHINEKEYPATH MachineKeyPath: # ZITADEL_FIRSTINSTANCE_MACHINEKEYPATH

View File

@@ -21,6 +21,11 @@ This guide assumes you are familiar with [running ZITADEL using the least amount
You can configure the runtime using the `--config` flag of the `zitadel` binary. You can configure the runtime using the `--config` flag of the `zitadel` binary.
Also, you can use the environment variables listed in the defaults.yaml. Also, you can use the environment variables listed in the defaults.yaml.
:::tip
For overwriting the default configuration for the first instance created by zitadel setup, use the FirstInstance section in the [database initialization file](#database-initialization-file).
:::
<details> <details>
<summary>defaults.yaml</summary> <summary>defaults.yaml</summary>
<CodeBlock language="yaml">{DefaultsYamlSource}</CodeBlock> <CodeBlock language="yaml">{DefaultsYamlSource}</CodeBlock>
@@ -32,6 +37,10 @@ ZITADEL uses a [different configuration file](https://github.com/zitadel/zitadel
Use the `--steps` flag of the `zitadel` binary to provide this configuration file. Use the `--steps` flag of the `zitadel` binary to provide this configuration file.
Also, you can use the environment variables listed in the steps.yaml. Also, you can use the environment variables listed in the steps.yaml.
:::tip
By using the FirstInstance section, you can overwrite the [DefaultInstance configuration](#runtime-configuration-file) for the first instance created by zitadel setup.
:::
<details> <details>
<summary>steps.yaml</summary> <summary>steps.yaml</summary>
<CodeBlock language="yaml">{StepsYamlSource}</CodeBlock> <CodeBlock language="yaml">{StepsYamlSource}</CodeBlock>