mirror of
https://github.com/replicatedhq/troubleshoot.git
synced 2026-08-27 00:37:20 +00:00
Update the preflight secret label to troubleshoot.sh/kind (#1204)
Partial-fix: #1070 Changes the default label for preflights to troubleshoot.sh/kind: preflight
This commit is contained in:
@@ -34,7 +34,7 @@ type documentMetadata struct {
|
||||
}
|
||||
|
||||
type documentMetadataLabels struct {
|
||||
TroubleshootKind string `yaml:"troubleshoot.io/kind,omitempty"`
|
||||
TroubleshootKind string `yaml:"troubleshoot.sh/kind,omitempty"`
|
||||
}
|
||||
|
||||
type documentData struct {
|
||||
@@ -136,7 +136,7 @@ func (p *PreflightSpecs) Read(args []string) error {
|
||||
return types.NewExitCodeError(constants.EXIT_CODE_SPEC_ISSUES, errors.Wrap(err, "failed to parse yaml"))
|
||||
}
|
||||
|
||||
// We're going to look for either of "kind: Preflight" OR "kind: Secret" with the label "troubleshoot.io/kind: preflight"
|
||||
// We're going to look for either of "kind: Preflight" OR "kind: Secret" with the label "troubleshoot.sh/kind: preflight"
|
||||
|
||||
if parsedDocHead.Kind != "Preflight" && parsedDocHead.Kind != "Secret" {
|
||||
continue
|
||||
|
||||
@@ -11,7 +11,7 @@ metadata:
|
||||
app.kubernetes.io/instance: "release-name"
|
||||
app.kubernetes.io/version: 0.62.1
|
||||
helm.sh/chart: "troubleshoot-0.1.0"
|
||||
troubleshoot.io/kind: preflight
|
||||
troubleshoot.sh/kind: preflight
|
||||
name: "release-name-preflight-config"
|
||||
data:
|
||||
preflight.yaml: CmFwaVZlcnNpb246IHRyb3VibGVzaG9vdC5zaC92MWJldGEyCmtpbmQ6IFByZWZsaWdodAptZXRhZGF0YToKICBuYW1lOiBwcmVmbGlnaHQtc2FtcGxlCnNwZWM6CiAgCiAgYW5hbHl6ZXJzOgogICAgLSBub2RlUmVzb3VyY2VzOgogICAgICAgIGNoZWNrTmFtZTogTm9kZSBDb3VudCBDaGVjawogICAgICAgIG91dGNvbWVzOgogICAgICAgICAgLSBmYWlsOgogICAgICAgICAgICAgIHdoZW46ICdjb3VudCgpIDwgMycKICAgICAgICAgICAgICBtZXNzYWdlOiBUaGUgY2x1c3RlciBuZWVkcyBhIG1pbmltdW0gb2YgMyBub2Rlcy4KICAgICAgICAgIC0gcGFzczoKICAgICAgICAgICAgICBtZXNzYWdlOiBUaGVyZSBhcmUgbm90IGVub3VnaCBub2RlcyB0byBydW4gdGhpcyBhcHBsaWNhdGlvbiAoMyBvciBtb3JlKQogICAgLSBjbHVzdGVyVmVyc2lvbjoKICAgICAgICBvdXRjb21lczoKICAgICAgICAgIC0gZmFpbDoKICAgICAgICAgICAgICB3aGVuOiAiPCAxLjE2LjAiCiAgICAgICAgICAgICAgbWVzc2FnZTogVGhlIGFwcGxpY2F0aW9uIHJlcXVpcmVzIGF0IGxlYXN0IEt1YmVybmV0ZXMgMS4xNi4wLCBhbmQgcmVjb21tZW5kcyAxLjE4LjAuCiAgICAgICAgICAgICAgdXJpOiBodHRwczovL2t1YmVybmV0ZXMuaW8KICAgICAgICAgIC0gd2FybjoKICAgICAgICAgICAgICB3aGVuOiAiPCAxLjE4LjAiCiAgICAgICAgICAgICAgbWVzc2FnZTogWW91ciBjbHVzdGVyIG1lZXRzIHRoZSBtaW5pbXVtIHZlcnNpb24gb2YgS3ViZXJuZXRlcywgYnV0IHdlIHJlY29tbWVuZCB5b3UgdXBkYXRlIHRvIDEuMTguMCBvciBsYXRlci4KICAgICAgICAgICAgICB1cmk6IGh0dHBzOi8va3ViZXJuZXRlcy5pbwogICAgICAgICAgLSBwYXNzOgogICAgICAgICAgICAgIG1lc3NhZ2U6IFlvdXIgY2x1c3RlciBtZWV0cyB0aGUgcmVjb21tZW5kZWQgYW5kIHJlcXVpcmVkIHZlcnNpb25zIG9mIEt1YmVybmV0ZXMuCiAgICA=
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ metadata:
|
||||
app.kubernetes.io/instance: "release-name"
|
||||
app.kubernetes.io/version: 0.62.1
|
||||
helm.sh/chart: "troubleshoot-0.1.0"
|
||||
troubleshoot.io/kind: preflight
|
||||
troubleshoot.sh/kind: preflight
|
||||
name: "release-name-preflight-config"
|
||||
stringData:
|
||||
preflight.yaml: |
|
||||
|
||||
Reference in New Issue
Block a user