Skip to content

Commit 502e8bb

Browse files
authored
edit docs (#293)
1 parent c5e6f42 commit 502e8bb

File tree

4 files changed

+30
-20
lines changed

4 files changed

+30
-20
lines changed

AUTHENTICATION.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ This document describes how you can configure authentication for the STACKIT CLI
55
## Service account
66

77
You can use a [service account](https://docs.stackit.cloud/stackit/en/service-accounts-134415819.html) to authenticate to the STACKIT CLI.
8-
The CLI will search for service account credentials similarly to the [STACKIT SDK](https://github.com/stackitcloud/stackit-sdk-go) and [Terraform Provider](https://github.com/stackitcloud/terraform-provider-stackit), so if you have setup you environment previously for those tools, you can just run:
8+
The CLI will search for service account credentials similarly to the [STACKIT SDK](https://github.com/stackitcloud/stackit-sdk-go) and [STACKIT Terraform Provider](https://github.com/stackitcloud/terraform-provider-stackit), so if you have already set up your environment for those tools, you can just run:
99

1010
```bash
1111
$ stackit auth activate-service-account
@@ -15,7 +15,7 @@ You can also configure the service account credentials directly in the CLI. To g
1515

1616
### Overview
1717

18-
If you dont have a service account, create one in the STACKIT Portal an assign it the necessary permissions, e.g. `owner`. There are two ways to authenticate:
18+
If you don't have a service account, create one in the [STACKIT Portal](https://portal.stackit.cloud/) and assign the necessary permissions to it, e.g. `owner`. There are two ways to authenticate:
1919

2020
- Key flow (recommended)
2121
- Token flow
@@ -39,20 +39,20 @@ When setting up authentication, the CLI will always try to use the key flow firs
3939

4040
### Key flow
4141

42-
The following instructions assume that you have created a service account and assigned it the necessary permissions, e.g. `owner`.
42+
The following instructions assume that you have created a service account and assigned the necessary permissions to it, e.g. `owner`.
4343

4444
To use the key flow, you need to have a service account key, which must have an RSA key-pair attached to it.
4545

4646
When creating the service account key, a new RSA key-pair can be created automatically, which will be included in the service account key. This will make it much easier to configure the key flow authentication in the CLI, by just providing the service account key.
4747

48-
**Optionally**, you can provide your own private key when creating the service account key, which will then require you to also provide it explicitly to the CLI, additionaly to the service account key. Check the STACKIT Knowledge Base for an [example of how to create your own key-pair](https://docs.stackit.cloud/stackit/en/usage-of-the-service-account-keys-in-stackit-175112464.html#UsageoftheserviceaccountkeysinSTACKIT-CreatinganRSAkey-pair).
48+
**Optionally**, you can provide your own private key when creating the service account key, which will then require you to also provide it explicitly to the CLI, additionally to the service account key. Check the STACKIT Knowledge Base for an [example of how to create your own key-pair](https://docs.stackit.cloud/stackit/en/usage-of-the-service-account-keys-in-stackit-175112464.html#UsageoftheserviceaccountkeysinSTACKIT-CreatinganRSAkey-pair).
4949

5050
To configure the key flow, follow this steps:
5151

5252
1. Create a service account key:
5353

5454
- In the CLI, run `stackit service-account key create --email <SERVICE_ACCOUNT_EMAIL>`
55-
- As an alternative, use the STACKIT Portal: go to the `Service Accounts` tab, choose a `Service Account` and go to `Service Account Keys` to create a key. For more details, see [Create a service account key](https://docs.stackit.cloud/stackit/en/create-a-service-account-key-175112456.html)
55+
- As an alternative, use the [STACKIT Portal](https://portal.stackit.cloud/): go to the `Service Accounts` tab, choose a `Service Account` and go to `Service Account Keys` to create a key. For more details, see [Create a service account key](https://docs.stackit.cloud/stackit/en/create-a-service-account-key-175112456.html)
5656

5757
2. Save the content of the service account key by copying it and saving it in a JSON file.
5858

AUTOCOMPLETION.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ stackit completion zsh > "${fpath[1]}/_stackit"
4242
stackit completion zsh > $(brew --prefix)/share/zsh/site-functions/_stackit
4343
```
4444

45-
Additionaly, you might also need to run:
45+
Additionally, you might also need to run:
4646

4747
```shell
4848
source $(brew --prefix)/share/zsh/site-functions/_stackit >> ~/.zshrc

CONTRIBUTION.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,16 @@ The CLI commands are located under `internal/cmd`, where each folder includes th
3838

3939
### Implementing a new command
4040

41-
Let's suppose you want to want to implement a new command `bar`, that would be the direct child of an existing command `stackit foo` (meaning it would be invoked as `stackit foo bar`):
41+
Let's suppose you want to implement a new command `bar`, that would be the direct child of an existing command `stackit foo` (meaning it would be invoked as `stackit foo bar`):
4242

4343
1. You would start by creating a new folder `bar/` inside `internal/cmd/foo/`
4444
2. Following with the creation of a file `bar.go` inside your new folder `internal/cmd/foo/bar/`
4545
1. The Go package should be similar to the command usage, in this case `package bar` would be an adequate name
46-
2. Please refer to the [Command file structure](./CONTRIBUTION.md/#command-file-structure) section for details on the strcutre of the file itself
46+
2. Please refer to the [Command file structure](./CONTRIBUTION.md/#command-file-structure) section for details on the structure of the file itself
4747
3. To register the command `bar` as a child of the existing command `foo`, add `cmd.AddCommand(bar.NewCmd(p))` to the `addSubcommands` method of the constructor of the `foo` command
4848
1. In this case, `p` is the `printer` that is passed from the root command to all subcommands of the tree (refer to the [Outputs, prints and debug logs](./CONTRIBUTION.md/#outputs-prints-and-debug-logs) section for more details regarding the `printer`)
4949

50-
Please remeber to run `make generate-docs` after your changes to keep the commands' documentation updated.
50+
Please remember to run `make generate-docs` after your changes to keep the commands' documentation updated.
5151

5252
#### Command file structure
5353

@@ -212,7 +212,7 @@ If you want to add a command that uses a STACKIT service `foo` that was not yet
212212

213213
1. Add a `FooCustomEndpointKey` key in `internal/pkg/config/config.go` (and add it to `ConfigKeys` and set the to default to `""` using `viper.SetDefault`)
214214
2. Update the `stackit config unset` and `stackit config unset` commands by adding flags to set and unset a custom endpoint for the `foo` service API, respectively, and update their unit tests
215-
3. Setup the SDK client configuration, using the authentication method configured in the CLI
215+
3. Set up the SDK client configuration, using the authentication method configured in the CLI
216216

217217
1. This is done in `internal/pkg/services/foo/client/client.go`
218218
2. Below is an example of a typical `client.go` file structure:
@@ -291,6 +291,6 @@ If you would like to report a bug, please open a [GitHub issue](https://github.c
291291
To ensure we can provide the best support to your issue, follow these guidelines:
292292
293293
1. Go through the existing issues to check if your issue has already been reported.
294-
2. Make sure you are using the latest version of the provider, we will not provide bug fixes for older versions. Also, latest versions may have the fix for your bug.
295-
3. Please provide as much information as you can about your environment, e.g. your version of Go, your version of the provider, which operating system you are using and the corresponding version.
294+
2. Make sure you are using the latest version of the STACKIT CLI, we will not provide bug fixes for older versions. Also, latest versions may have the fix for your bug.
295+
3. Please provide as much information as you can about your environment, e.g. your version of Go, your version of the CLI, which operating system you are using and the corresponding version.
296296
4. Include in your issue the steps to reproduce it, along with code snippets and/or information about your specific use case. This will make the support process much easier and efficient.

README.md

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ Examples:
3333
- `stackit mongodbflex instance create --name my-instance --cpu 1 --ram 4 --acl 0.0.0.0/0 --assume-yes`
3434
- `stackit dns zone delete my-zone`
3535

36-
Some commands are implemented at the root, group or sub-group level:
36+
Some commands are implemented at the root, group or subgroup level:
3737

3838
- `stackit config` to define variables to be used in future commands.
3939
- `stackit ske enable` to enable the SKE engine on your project.
@@ -71,9 +71,9 @@ Below you can find a list of the STACKIT services already available in the CLI (
7171

7272
## Authentication
7373

74-
Most of the commands will require you to be authenticated. Currently it's possible to authenticate with your personal user or with a service account.
74+
Most of the commands will require you to be authenticated. Currently, it's possible to authenticate with your personal user or with a service account.
7575

76-
After successful authentication, the CLI stores credentials in your OS keychain. You won't need to login again for the duration of your session, which is 2h by default but configurable by providing the `--session-time-limit` flag on the `config set` command (see [Configuration](#configuration)).
76+
After successful authentication, the CLI stores credentials in your OS keychain. You won't need to log in again for the duration of your session, which is 2h by default but configurable by providing the `--session-time-limit` flag on the `config set` command (see [Configuration](#configuration)).
7777

7878
### Login with a personal user account
7979

@@ -91,7 +91,7 @@ To authenticate using a service account, run:
9191
stackit auth activate-service-account
9292
```
9393

94-
For more details on how to setup authentication using a service account, check our [authentication guide](./AUTHENTICATION.md).
94+
For more details on how to set up authentication using a service account, check our [authentication guide](./AUTHENTICATION.md).
9595

9696
## Configuration
9797

@@ -119,9 +119,9 @@ To remove it, you can run:
119119
stackit config unset --project-id
120120
```
121121

122-
Run the `config set` command with the flag `--help` to get a list of all of the available configuration options.
122+
Run the `config set` command with the flag `--help` to get a list of all the available configuration options.
123123

124-
You can lookup your current configuration by checking the configuration file or by running:
124+
You can look up your current configuration by checking the configuration file or by running:
125125

126126
```bash
127127
stackit config list
@@ -131,11 +131,11 @@ You can also edit the configuration file manually.
131131

132132
## Autocompletion
133133

134-
If you wish to setup command autocompletion in your shell for the STACKIT CLI, please refer to our [autocompletion guide](./AUTOCOMPLETION.md).
134+
If you wish to set up command autocompletion in your shell for the STACKIT CLI, please refer to our [autocompletion guide](./AUTOCOMPLETION.md).
135135

136136
## Reporting issues
137137

138-
If you encounter any issues or have suggestions for improvements, please reach out to the Developer Tools team or open a ticket through the [STACKIT Help Center](https://support.stackit.cloud/).
138+
If you encounter any issues or have suggestions for improvements, please open an issue in the [repository](https://github.com/stackitcloud/stackit-cli/issues).
139139

140140
## Contribute
141141

@@ -144,3 +144,13 @@ Your contribution is welcome! For more details on how to contribute, refer to ou
144144
## License
145145

146146
Apache 2.0
147+
148+
149+
## Useful Links
150+
- [STACKIT Portal](https://portal.stackit.cloud/)
151+
152+
- [STACKIT](https://www.stackit.de/en/)
153+
154+
- [STACKIT Knowledge Base](https://docs.stackit.cloud/stackit/en/knowledge-base-85301704.html)
155+
156+
- [STACKIT Terraform Provider](https://registry.terraform.io/providers/stackitcloud/stackit/latest/docs)

0 commit comments

Comments
 (0)