Skip to content

Commit d893269

Browse files
Dependabot/go modules/GitHub.com/stackitcloud/stackit sdk go/services/observability 0.16.1 (#1263)
* chore(deps): bump github.com/stackitcloud/stackit-sdk-go/services/observability Bumps [github.com/stackitcloud/stackit-sdk-go/services/observability](https://github.com/stackitcloud/stackit-sdk-go) from 0.15.1 to 0.16.1. - [Release notes](https://github.com/stackitcloud/stackit-sdk-go/releases) - [Changelog](https://github.com/stackitcloud/stackit-sdk-go/blob/main/CHANGELOG.md) - [Commits](stackitcloud/stackit-sdk-go@core/v0.15.1...services/mongodbflex/v0.16.1) --- updated-dependencies: - dependency-name: github.com/stackitcloud/stackit-sdk-go/services/observability dependency-version: 0.16.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * fix(observability) suppress linting error, add deprecation warnings * fix(observability) run generate-docs * fix(observability) remove show password from docs because deprecation * fix(docs) generate docs * fix(docs) remove superfluous format placeholder --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 parent b600032 commit d893269

File tree

4 files changed

+11
-15
lines changed

4 files changed

+11
-15
lines changed

docs/stackit_observability_grafana_describe.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ Shows details of the Grafana configuration of an Observability instance
66

77
Shows details of the Grafana configuration of an Observability instance.
88
The Grafana dashboard URL and initial credentials (admin user and password) will be shown in the "pretty" output format. These credentials are only valid for first login. Please change the password after first login. After changing, the initial password is no longer valid.
9-
The initial password is hidden by default, if you want to show it use the "--show-password" flag.
109

1110
```
1211
stackit observability grafana describe INSTANCE_ID [flags]
@@ -18,18 +17,14 @@ stackit observability grafana describe INSTANCE_ID [flags]
1817
Get details of the Grafana configuration of an Observability instance with ID "xxx"
1918
$ stackit observability grafana describe xxx
2019
21-
Get details of the Grafana configuration of an Observability instance with ID "xxx" and show the initial admin password
22-
$ stackit observability grafana describe xxx --show-password
23-
2420
Get details of the Grafana configuration of an Observability instance with ID "xxx" in JSON format
2521
$ stackit observability grafana describe xxx --output-format json
2622
```
2723

2824
### Options
2925

3026
```
31-
-h, --help Help for "stackit observability grafana describe"
32-
-s, --show-password Show password in output
27+
-h, --help Help for "stackit observability grafana describe"
3328
```
3429

3530
### Options inherited from parent commands

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ require (
270270
github.com/stackitcloud/stackit-sdk-go/services/logme v0.25.3
271271
github.com/stackitcloud/stackit-sdk-go/services/mariadb v0.25.3
272272
github.com/stackitcloud/stackit-sdk-go/services/objectstorage v1.4.5
273-
github.com/stackitcloud/stackit-sdk-go/services/observability v0.15.1
273+
github.com/stackitcloud/stackit-sdk-go/services/observability v0.16.1
274274
github.com/stackitcloud/stackit-sdk-go/services/rabbitmq v0.25.3
275275
github.com/stackitcloud/stackit-sdk-go/services/redis v0.25.3
276276
github.com/stackitcloud/stackit-sdk-go/services/sfs v0.3.0

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -632,8 +632,8 @@ github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.5.8 h1:S7t4wcT6SN
632632
github.com/stackitcloud/stackit-sdk-go/services/mongodbflex v1.5.8/go.mod h1:CdrhFUsBO7/iJleCc2yQjDChIbG6YaxKNBQRNCjgcF4=
633633
github.com/stackitcloud/stackit-sdk-go/services/objectstorage v1.4.5 h1:4gpvB6t7d2lLjInoTxcvjL9jCpBl5EDfYe5yUtR1MvA=
634634
github.com/stackitcloud/stackit-sdk-go/services/objectstorage v1.4.5/go.mod h1:Bdcd59sRySyhfSUCy+5BNkp5w9PECmrywdvt+ORMKnI=
635-
github.com/stackitcloud/stackit-sdk-go/services/observability v0.15.1 h1:zk+47GhutK2ajO4Yiek0laGm2PdXvY8BvFZc8yHFnSE=
636-
github.com/stackitcloud/stackit-sdk-go/services/observability v0.15.1/go.mod h1:vapb/sJqbHlf+c7pZWdE9GqrbyI8wesGvUc9o7oJ1Xk=
635+
github.com/stackitcloud/stackit-sdk-go/services/observability v0.16.1 h1:FKeW3uiMXRl6Oau3xE6yBriXh4t7CwPb8QH6PR0uQXM=
636+
github.com/stackitcloud/stackit-sdk-go/services/observability v0.16.1/go.mod h1:RiknJnL3OuU9wb2lyb80Hu+EnlyDQMG8vejDV7B9a5U=
637637
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.24.3 h1:CAgu3Wsmo8pA1/VWqnqLftMn7X26uDs5zctTci4WG7A=
638638
github.com/stackitcloud/stackit-sdk-go/services/opensearch v0.24.3/go.mod h1:VC3vqIQIDN+8SAzhlMdrK4eXeiSaNE1JtjIGFzpgiRI=
639639
github.com/stackitcloud/stackit-sdk-go/services/postgresflex v1.3.2 h1:uQIpj0phDRGrV78/vhtULwxaO2cBdHwqZcFKYUrH1Hs=

internal/cmd/observability/grafana/describe/describe.go

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ import (
2121
)
2222

2323
const (
24-
instanceIdArg = "INSTANCE_ID"
24+
instanceIdArg = "INSTANCE_ID"
25+
// Deprecated: showPasswordFlag is deprecated and will be removed on 2026-07-05.
2526
showPasswordFlag = "show-password"
2627
)
2728

@@ -35,19 +36,15 @@ func NewCmd(params *types.CmdParams) *cobra.Command {
3536
cmd := &cobra.Command{
3637
Use: fmt.Sprintf("describe %s", instanceIdArg),
3738
Short: "Shows details of the Grafana configuration of an Observability instance",
38-
Long: fmt.Sprintf("%s\n%s\n%s",
39+
Long: fmt.Sprintf("%s\n%s",
3940
"Shows details of the Grafana configuration of an Observability instance.",
4041
`The Grafana dashboard URL and initial credentials (admin user and password) will be shown in the "pretty" output format. These credentials are only valid for first login. Please change the password after first login. After changing, the initial password is no longer valid.`,
41-
`The initial password is hidden by default, if you want to show it use the "--show-password" flag.`,
4242
),
4343
Args: args.SingleArg(instanceIdArg, utils.ValidateUUID),
4444
Example: examples.Build(
4545
examples.NewExample(
4646
`Get details of the Grafana configuration of an Observability instance with ID "xxx"`,
4747
"$ stackit observability grafana describe xxx"),
48-
examples.NewExample(
49-
`Get details of the Grafana configuration of an Observability instance with ID "xxx" and show the initial admin password`,
50-
"$ stackit observability grafana describe xxx --show-password"),
5148
examples.NewExample(
5249
`Get details of the Grafana configuration of an Observability instance with ID "xxx" in JSON format`,
5350
"$ stackit observability grafana describe xxx --output-format json"),
@@ -86,6 +83,7 @@ func NewCmd(params *types.CmdParams) *cobra.Command {
8683

8784
func configureFlags(cmd *cobra.Command) {
8885
cmd.Flags().BoolP(showPasswordFlag, "s", false, "Show password in output")
86+
cobra.CheckErr(cmd.Flags().MarkDeprecated(showPasswordFlag, "This flag is deprecated and will be removed on 2026-07-05."))
8987
}
9088

9189
func parseInput(p *print.Printer, cmd *cobra.Command, inputArgs []string) (*inputModel, error) {
@@ -122,8 +120,10 @@ func outputResult(p *print.Printer, outputFormat string, showPassword bool, graf
122120
} else if grafanaConfigs == nil {
123121
return fmt.Errorf("grafanaConfigs is nil")
124122
}
123+
p.Warn("GrafanaAdminPassword and GrafanaAdminUser are deprecated and will be removed on 2026-07-05.")
125124

126125
return p.OutputResult(outputFormat, grafanaConfigs, func() error {
126+
//nolint:staticcheck // field is deprecated but still supported until 2026-07-05
127127
initialAdminPassword := utils.PtrString(instance.Instance.GrafanaAdminPassword)
128128
if !showPassword {
129129
initialAdminPassword = "<hidden>"
@@ -136,6 +136,7 @@ func outputResult(p *print.Printer, outputFormat string, showPassword bool, graf
136136
table.AddSeparator()
137137
table.AddRow("SINGLE SIGN-ON", utils.PtrString(grafanaConfigs.UseStackitSso))
138138
table.AddSeparator()
139+
//nolint:staticcheck // field is deprecated but still supported until 2026-07-05
139140
table.AddRow("INITIAL ADMIN USER (DEFAULT)", utils.PtrString(instance.Instance.GrafanaAdminUser))
140141
table.AddSeparator()
141142
table.AddRow("INITIAL ADMIN PASSWORD (DEFAULT)", initialAdminPassword)

0 commit comments

Comments
 (0)