diff --git a/docs/stackit_ske_credentials.md b/docs/stackit_ske_credentials.md index e49497fb5..8b7c6f4b9 100644 --- a/docs/stackit_ske_credentials.md +++ b/docs/stackit_ske_credentials.md @@ -29,7 +29,5 @@ stackit ske credentials [flags] * [stackit ske](./stackit_ske.md) - Provides functionality for SKE * [stackit ske credentials complete-rotation](./stackit_ske_credentials_complete-rotation.md) - Completes the rotation of the credentials associated to a SKE cluster -* [stackit ske credentials describe](./stackit_ske_credentials_describe.md) - Shows details of the credentials associated to a SKE cluster -* [stackit ske credentials rotate](./stackit_ske_credentials_rotate.md) - Rotates credentials associated to a SKE cluster * [stackit ske credentials start-rotation](./stackit_ske_credentials_start-rotation.md) - Starts the rotation of the credentials associated to a SKE cluster diff --git a/docs/stackit_ske_credentials_describe.md b/docs/stackit_ske_credentials_describe.md deleted file mode 100644 index 712453cd4..000000000 --- a/docs/stackit_ske_credentials_describe.md +++ /dev/null @@ -1,41 +0,0 @@ -## stackit ske credentials describe - -Shows details of the credentials associated to a SKE cluster - -### Synopsis - -Shows details of the credentials associated to a STACKIT Kubernetes Engine (SKE) cluster - -``` -stackit ske credentials describe CLUSTER_NAME [flags] -``` - -### Examples - -``` - Get details of the credentials associated to the SKE cluster with name "my-cluster" - $ stackit ske credentials describe my-cluster - - Get details of the credentials associated to the SKE cluster with name "my-cluster" in a table format - $ stackit ske credentials describe my-cluster --output-format pretty -``` - -### Options - -``` - -h, --help Help for "stackit ske credentials describe" -``` - -### Options inherited from parent commands - -``` - -y, --assume-yes If set, skips all confirmation prompts - --async If set, runs the command asynchronously - -o, --output-format string Output format, one of ["json" "pretty"] - -p, --project-id string Project ID -``` - -### SEE ALSO - -* [stackit ske credentials](./stackit_ske_credentials.md) - Provides functionality for SKE credentials - diff --git a/docs/stackit_ske_credentials_rotate.md b/docs/stackit_ske_credentials_rotate.md deleted file mode 100644 index ff3acb9a1..000000000 --- a/docs/stackit_ske_credentials_rotate.md +++ /dev/null @@ -1,38 +0,0 @@ -## stackit ske credentials rotate - -Rotates credentials associated to a SKE cluster - -### Synopsis - -Rotates credentials associated to a STACKIT Kubernetes Engine (SKE) cluster. The old credentials will be invalid after the operation. - -``` -stackit ske credentials rotate CLUSTER_NAME [flags] -``` - -### Examples - -``` - Rotate credentials associated to the SKE cluster with name "my-cluster" - $ stackit ske credentials rotate my-cluster -``` - -### Options - -``` - -h, --help Help for "stackit ske credentials rotate" -``` - -### Options inherited from parent commands - -``` - -y, --assume-yes If set, skips all confirmation prompts - --async If set, runs the command asynchronously - -o, --output-format string Output format, one of ["json" "pretty"] - -p, --project-id string Project ID -``` - -### SEE ALSO - -* [stackit ske credentials](./stackit_ske_credentials.md) - Provides functionality for SKE credentials - diff --git a/docs/stackit_ske_kubeconfig_create.md b/docs/stackit_ske_kubeconfig_create.md index fd73c5b76..39718071d 100644 --- a/docs/stackit_ske_kubeconfig_create.md +++ b/docs/stackit_ske_kubeconfig_create.md @@ -35,7 +35,7 @@ stackit ske kubeconfig create CLUSTER_NAME [flags] ``` -e, --expiration string Expiration time for the kubeconfig in seconds(s), minutes(m), hours(h), days(d) or months(M). Example: 30d. By default, expiration time is 1h - --filepath string Path to create the kubeconfig file. By default, the kubeconfig is created in the .kube folder, in the user's home directory. + --filepath string Path to create the kubeconfig file. By default, the kubeconfig is created as 'config' in the .kube folder, in the user's home directory. -h, --help Help for "stackit ske kubeconfig create" ``` diff --git a/internal/cmd/ske/credentials/describe/describe.go b/internal/cmd/ske/credentials/describe/describe.go index 01917510c..4bb2c7895 100644 --- a/internal/cmd/ske/credentials/describe/describe.go +++ b/internal/cmd/ske/credentials/describe/describe.go @@ -32,6 +32,12 @@ func NewCmd() *cobra.Command { Short: "Shows details of the credentials associated to a SKE cluster", Long: "Shows details of the credentials associated to a STACKIT Kubernetes Engine (SKE) cluster", Args: args.SingleArg(clusterNameArg, nil), + Deprecated: fmt.Sprintf("%s\n%s\n%s\n%s\n", + "and will be removed in a future release.", + "Please use the following command to obtain a kubeconfig file instead:", + " $ stackit ske kubeconfig create my-cluster", + "For more information, visit: https://docs.stackit.cloud/stackit/en/how-to-rotate-ske-credentials-200016334.html", + ), Example: examples.Build( examples.NewExample( `Get details of the credentials associated to the SKE cluster with name "my-cluster"`, diff --git a/internal/cmd/ske/credentials/rotate/rotate.go b/internal/cmd/ske/credentials/rotate/rotate.go index cba8ea31e..52b95b5dc 100644 --- a/internal/cmd/ske/credentials/rotate/rotate.go +++ b/internal/cmd/ske/credentials/rotate/rotate.go @@ -32,6 +32,13 @@ func NewCmd() *cobra.Command { Short: "Rotates credentials associated to a SKE cluster", Long: "Rotates credentials associated to a STACKIT Kubernetes Engine (SKE) cluster. The old credentials will be invalid after the operation.", Args: args.SingleArg(clusterNameArg, nil), + Deprecated: fmt.Sprintf("%s\n%s\n%s\n%s\n%s\n", + "and will be removed in a future release.", + "Please use the 2-step credential rotation flow instead, by running the commands:", + " $ stackit ske credentials start-rotation my-cluster", + " $ stackit ske credentials complete-rotation my-cluster", + "For more information, visit: https://docs.stackit.cloud/stackit/en/how-to-rotate-ske-credentials-200016334.html", + ), Example: examples.Build( examples.NewExample( `Rotate credentials associated to the SKE cluster with name "my-cluster"`,