From 93c90814806cddcee32bcf181707517e23c89c0b Mon Sep 17 00:00:00 2001 From: Andrea Luzzardi Date: Mon, 14 Jun 2021 18:36:29 +0200 Subject: [PATCH] docs: fix sidebar collapsing and titles Signed-off-by: Andrea Luzzardi --- docs/administrator/_category_.json | 3 +- docs/administrator/operator.md | 4 - docs/introduction/_category_.json | 3 +- docs/introduction/vs.md | 1 - docs/programming/_category_.json | 3 +- docs/programming/guides/_category_.json | 3 +- docs/programming/guides/cloudformation.mdx | 158 ++++++++++----------- docs/reference/_category_.json | 3 +- docs/user/_category_.json | 3 +- docs/user/user.md | 2 - 10 files changed, 87 insertions(+), 96 deletions(-) diff --git a/docs/administrator/_category_.json b/docs/administrator/_category_.json index d5618c12..86f89975 100644 --- a/docs/administrator/_category_.json +++ b/docs/administrator/_category_.json @@ -1,4 +1,5 @@ { "label": "Administrator Manual", - "position": 6 + "position": 6, + "collapsed": false } diff --git a/docs/administrator/operator.md b/docs/administrator/operator.md index 37c76be4..d8e0a406 100644 --- a/docs/administrator/operator.md +++ b/docs/administrator/operator.md @@ -1,7 +1,3 @@ ---- -sidebar_position: 2 ---- - # Dagger Operator Manual ## Custom buildkit setup diff --git a/docs/introduction/_category_.json b/docs/introduction/_category_.json index fa1c06ac..096f399e 100644 --- a/docs/introduction/_category_.json +++ b/docs/introduction/_category_.json @@ -1,4 +1,5 @@ { "label": "Introduction", - "position": 1 + "position": 1, + "collapsed": false } diff --git a/docs/introduction/vs.md b/docs/introduction/vs.md index 68d68946..a970077a 100644 --- a/docs/introduction/vs.md +++ b/docs/introduction/vs.md @@ -1,7 +1,6 @@ --- sidebar_position: 2 slug: /vs -sidebar_label: Dagger vs. Other software --- # Dagger vs. Other Software diff --git a/docs/programming/_category_.json b/docs/programming/_category_.json index ff7ecfb9..c8ba1504 100644 --- a/docs/programming/_category_.json +++ b/docs/programming/_category_.json @@ -1,4 +1,5 @@ { "label": "Programming Manual", - "position": 4 + "position": 4, + "collapsed": false } diff --git a/docs/programming/guides/_category_.json b/docs/programming/guides/_category_.json index e7905087..c694eb5b 100644 --- a/docs/programming/guides/_category_.json +++ b/docs/programming/guides/_category_.json @@ -1,4 +1,5 @@ { "label": "Guides", - "position": 2 + "position": 2, + "collapsed": false } diff --git a/docs/programming/guides/cloudformation.mdx b/docs/programming/guides/cloudformation.mdx index 84057ef9..5f3e163f 100644 --- a/docs/programming/guides/cloudformation.mdx +++ b/docs/programming/guides/cloudformation.mdx @@ -1,8 +1,3 @@ ---- -sidebar_position: 3 -slug: /programming/cloudformation ---- - # Infra provisioning ## Integrating with AWS Cloudformation @@ -40,7 +35,7 @@ cd ./.dagger/env/s3-provisioning/plan/ #Personal preference to directly work ins 3. Create `main.cue` file with its corresponding `main` package -```bash +```bash touch main.cue -- ~/infra-provisioning/.dagger/env/s3-provisioning/plan/main.cue -- @@ -59,8 +54,8 @@ The idea here is to follow best practices in [S3 buckets](https://docs.aw The [template](https://docs.aws.amazon.com/fr_fr/AWSCloudFormation/latest/UserGuide/quickref-s3.html#scenario-s3-bucket-website) has far more outputs than necessary, as we just want to retrieve the bucket name: -import Tabs from '@theme/Tabs'; -import TabItem from '@theme/TabItem'; +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; -2. Some *"Pro tips"* +2. Some _"Pro tips"_ Double-checks at the template level can be done with manual uploads on Cloudformation's web interface or by executing the below command locally: ```bash aws cloudformation validate-template --template-body file://template.json ``` -> PS: The *"Full Base Template"* tab contains the base template used for the following parts of the guide +> PS: The _"Full Base Template"_ tab contains the base template used for the following parts of the guide ### JSON / YAML to Cue conversion @@ -320,7 +312,9 @@ data: """ ###### 2. Retrieve the Unmarshalled JSON + Then, still in the same folder, query the `point` value to retrieve the Unmarshalled result of `data`: + Cloudformation's relay](https://dagger.io/aws/cloudformation), let's dissect the expected inputs by gradually incorporating them in our plan. -| Name | Type | Description | -| ------------- |:-------------: |:-------------: | -|*config.region* | `string` |AWS region | -|*config.accessKey* | `dagger.#Secret` |AWS access key | -|*config.secretKey* | `dagger.#Secret` |AWS secret key | -|*source* | `string` |Source is the Cloudformation template (JSON/YAML string) | -|*stackName* | `string` |Stackname is the cloudformation stack | -|*onFailure* | `*"DO_NOTHING" \| "ROLLBACK" \| "DELETE"` |Behavior when failure to create/update the Stack | -|*timeout* | `*10 \| \>=0 & int` |Timeout for waiting for the stack to be created/updated (in minutes) | -|*neverUpdate* | `*false \| bool` |Never update the stack if already exists | +| Name | Type | Description | +| ------------------ | :---------------------------------------: | :------------------------------------------------------------------: | +| _config.region_ | `string` | AWS region | +| _config.accessKey_ | `dagger.#Secret` | AWS access key | +| _config.secretKey_ | `dagger.#Secret` | AWS secret key | +| _source_ | `string` | Source is the Cloudformation template (JSON/YAML string) | +| _stackName_ | `string` | Stackname is the cloudformation stack | +| _onFailure_ | `*"DO_NOTHING" \| "ROLLBACK" \| "DELETE"` | Behavior when failure to create/update the Stack | +| _timeout_ | `*10 \| \>=0 & int` | Timeout for waiting for the stack to be created/updated (in minutes) | +| _neverUpdate_ | `*false \| bool` | Never update the stack if already exists | 1. General insights As seen before in the documentation, values starting with `*` are default values. However, as a plan developer, we may face the need to add default values to inputs from relays that don't have one : Cue gives you this flexibility (cf. `config` value detailed below). ->WARNING: All inputs without a default option have to be filled for a proper execution of the relay. In our case: +> WARNING: All inputs without a default option have to be filled for a proper execution of the relay. In our case: > ->* *config.region* ->* *config.accessKey* ->* *config.secretKey* ->* *source* ->* *stackName* +> - _config.region_ +> - _config.accessKey_ +> - _config.secretKey_ +> - _source_ +> - _stackName_ 2. The config value @@ -515,7 +508,7 @@ awsConfig: aws.#Config & { // Assign an aws.#Config definition to a field named -*Pro tips: In order to check wether it worked or not, these two commands might help* +_Pro tips: In order to check wether it worked or not, these two commands might help_