-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
📖 149 update docs for use in docsscscommunity (#150)
* fixed: md formatting causing docs build to fail Signed-off-by: Danny Eiselt <[email protected]> * added: updated quickstart.md Signed-off-by: Danny Eiselt <[email protected]> * added: overview.md Signed-off-by: Danny Eiselt <[email protected]> * changed: getting_started file Signed-off-by: Danny Eiselt <[email protected]> * added: deprecation note for how_to_use_csctl.md Signed-off-by: Danny Eiselt <[email protected]> * Update getting_started.md Signed-off-by: Jan Schoone <[email protected]> --------- Signed-off-by: Danny Eiselt <[email protected]> Signed-off-by: Jan Schoone <[email protected]> Co-authored-by: Jan Schoone <[email protected]>
- Loading branch information
Showing
4 changed files
with
105 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Overview | ||
|
||
## Introduction | ||
|
||
The [Cluster Stack Operator](https://github.com/SovereignCloudStack/cluster-stack-operator) facilitates the usage of [Cluster Stacks](https://github.com/SovereignCloudStack/cluster-stacks) by automating all steps that can be automated. It takes Cluster Stacks release assets that consist mainly of two Helm charts, one to deploy in the management cluster, the other one to deploy in the workload clusters, as well as provider-specific node image (build) information. | ||
|
||
Users can take existing releases of Cluster Stacks and the operator and will be able to create clusters easily. | ||
|
||
This project facilitates building node image artifacts and release assets that can be used with the Cluster Stack Operator. | ||
|
||
## What does csctl do? | ||
|
||
As a user, you can create clusters based on Cluster Stacks with the help of the Cluster Stack Operator. The operator needs certain files, e.g. to apply the required Helm charts, and to get the necessary information about the versions in the cluster stack. | ||
|
||
In order to not generate these files manually, this CLI tool takes a certain pre-defined directory structure, in which users can configure all necessary Helm charts and build scripts for node images, and generates the assets that the Cluster Stack Operator can process. | ||
|
||
Therefore, this tool can be used to configure Cluster Stacks and to test them with the Cluster Stack Operator. It can also be used to release stable releases of Cluster Stacks that can be published for a broader community. | ||
|
||
## Features of csctl | ||
1. Testing and quick iterations | ||
csctl is created with a single focus of building Cluster Stacks and testing them with Cluster Stack Operator quickly. This tool helps in doing quick iterations and facilitates testing Cluster Stacks. | ||
|
||
2. Versioning | ||
When configuring Cluster Stacks, it is necessary to put versions in the configuration, e.g. to version a Helm chart or node images. This process is facilitated by the csctl through its own templating and mechanism to generate the right version, based on the content hash (for testing) or on a previous version (stable or beta channel). Users only have to use the right templating and the csctl will do all the versioning automatically. | ||
|
||
3. Plugin mechanism for providers | ||
The plugin mechanism of csctl allows providers to implement all provider-specific steps that are needed for this provider. This can contain a fully automated building and uploading process for node images, which can be referenced in the Cluster Stack (using the templating logic for versioning). | ||
|
||
4. Automated testing of Cluster Stacks | ||
The csctl enables automated testing of Cluster Stacks if integrated in a CI process that first builds all necessary files as well as node images (if needed) and then uses them to create a workload cluster based on the Cluster Stack. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
# Quickstart | ||
|
||
## Installation | ||
To download `csctl` there are two ways. | ||
Go to https://github.com/SovereignCloudStack/csctl/releases/latest and then click on the binary. The name of the binary looks similar to this `csctl_0.0.3_linux_amd64.tar.gz` for Linux amd64 architecture. | ||
|
||
This will download the binary in your `~/Downloads` directory. Use the following commands to move it to your PATH. | ||
```bash | ||
tar xvzf ~/Downloads/csctl_<version>_linux_amd64.tar.gz | ||
chmod u+x ~/Downloads/csctl | ||
sudo mv ~/Downloads/csctl /usr/local/bin/csctl | ||
``` | ||
|
||
Alternative way of installing the binary is to use `[gh](https://github.com/cli/cli)` command line tool. | ||
Use the following command to download the latest binary from GitHub. | ||
```bash | ||
gh release download -p 'csctl_<version>_linux_amd64.tar.gz' -R SovereignCloudStack/csctl | ||
tar xvzf csctl_<version>_linux_amd64.tar.gz | ||
chmod u+x csctl | ||
sudo mv ./csctl /usr/local/bin/csctl | ||
``` | ||
For darwin based systems, the steps are similar, you'll have to choose darwin based binaries instead of linux one mentioned above. You'll also need to update your destination directory. | ||
|
||
## Creating Cluster Stacks | ||
|
||
The most important subcommand is `create`. This command takes a path to the directory where you configured your Cluster Stack and generates the necessary files in the output directory via the `--output` flag: | ||
|
||
```bash | ||
$ csctl create <path-to-cluster-stack-configuration-directory> --output <path-to-output-directory> | ||
``` | ||
|
||
You can specify your node image registry with the flag `--node-image-registry`. The plugin of your provider will update the node images in the respective container registry. | ||
|
||
You can use the `--mode` flag to specify the mode you want to use. | ||
|
||
For example: | ||
|
||
```bash | ||
$ csctl create <path-to-cluster-stack-directory> --output <path-to-output-directory> --mode hash --node-image-registry <url-of-registry> | ||
``` | ||
|
||
You have to be authenticated to your cloud provider and container registry to which you want to upload the node images. | ||
|
||
## Different modes of csctl | ||
|
||
The csctl has multiple modes that can be used for different use cases. | ||
|
||
### Hash mode | ||
|
||
This mode is the most used one, as it allows quick iterations and testing of a cluster stack. It takes the hash of the content of the cluster stack and generates a semver version on this. You can combine it with the `custom` channel of Cluster Stack Operator and test your Cluster Stacks easily! | ||
|
||
### Stable mode | ||
|
||
This mode checks for existing releases of cluster stacks and versions your cluster stack accordingly. If you have an existing release of "v1", then it would use "v2" for the new one. It also checks whether the node images and cluster addons have changed or not and will only update the versions if something actually changed. | ||
|
||
### Beta mode | ||
|
||
Similar to stable mode, but for a beta release channel. It versions according to "v0-beta.1", etc. | ||
|
||
### Custom mode | ||
|
||
The custom mode can be used to define your own version. You can input any semver version and your cluster stack will be versioned accordingly. |