diff --git a/docs/core-concepts/config.md b/docs/core-concepts/config.md index 27bfe9730..cb40c0a68 100644 --- a/docs/core-concepts/config.md +++ b/docs/core-concepts/config.md @@ -84,9 +84,11 @@ tools: ### State -The `state` section specifies where to store DevStream state. As of now (v0.5.0,) we only support local "backend" to store the DevStream state. AWS S3 backend is being supported and will be released soon. +The `state` section specifies where to store DevStream state. As of now (v0.5.0), we only support local backend. -The `state` section has some options. For example, `stateFile` is mandatory for local backend. +From v0.6.0 on, we will support both "local" and "s3" backend store the DevStream state. + +Read the section [The State Section in the Main Config](./stateconfig.md) for more details. ## Default Values diff --git a/docs/core-concepts/state.md b/docs/core-concepts/state.md deleted file mode 100644 index 22ab74f3e..000000000 --- a/docs/core-concepts/state.md +++ /dev/null @@ -1,20 +0,0 @@ -# The State Section in the Main Config - -In the main config, we can specify which "backend" to use to store DevStream state. Example: - -Main config file: - -```yaml -varFile: variables.yaml - -toolFile: tools.yaml - -state: - backend: local - options: - stateFile: devstream.state -``` - -The `state` section has a `backend` parameter. At the moment, the only supported backend is the `local` one. AWS S3 will be supported soon. - -For the `local` backend type, there is one option that is `stateFile`, which is the `path/to/the/state/file.state`. diff --git a/docs/core-concepts/stateconfig.md b/docs/core-concepts/stateconfig.md new file mode 100644 index 000000000..536e0021b --- /dev/null +++ b/docs/core-concepts/stateconfig.md @@ -0,0 +1,40 @@ +# The State Section in the Main Config + +In the main config, we can specify which "backend" to use to store DevStream state. + +We support the following types of backend: + +- local +- s3 + +## Local backend config example: + +```yaml +varFile: variables-gitops.yaml + +toolFile: tools-gitops.yaml + +state: + backend: local + options: + stateFile: devstream.state +``` + +The `stateFile` under the `options` section is mandatory for local backend. + +## S3 backend config example: + +```yaml +varFile: variables-gitops.yaml + +toolFile: tools-gitops.yaml + +state: + backend: s3 + options: + bucket: devstream-remote-state + region: ap-southeast-1 + key: devstream.state +``` + +The `bucket`, `region`, and `key` under the `ptions` section are all mandatory fields for s3 backend. diff --git a/mkdocs.yml b/mkdocs.yml index caf2c4484..c3b7f25c3 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -24,7 +24,7 @@ nav: - 'core-concepts/core-concepts.md' - 'core-concepts/config.md' - 'core-concepts/variables.md' - - 'core-concepts/state.md' + - 'core-concepts/stateconfig.md' - 'core-concepts/dependencies.md' - 'core-concepts/output.md' - Plugins: