-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: --redactors flag is dropped if no spec provided (#1611)
don't drop redactors when 0 positional arguments are provided
- Loading branch information
1 parent
7484b10
commit 0c63880
Showing
4 changed files
with
90 additions
and
4 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
28 changes: 28 additions & 0 deletions
28
testdata/supportbundle/labelled-bundle-unlabelled-redactor/redact-spec-1.yaml
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,28 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: unlabelled-redactor-spec-1 | ||
data: | ||
redactor-spec: | | ||
apiVersion: troubleshoot.sh/v1beta2 | ||
kind: Redactor | ||
metadata: | ||
name: unlabelled-redactor-spec-1 | ||
spec: | ||
redactors: | ||
- name: redact-text-1 | ||
removals: | ||
values: | ||
- REDACT FIRST TEXT PLEASE | ||
customer-redactor-spec: | | ||
apiVersion: troubleshoot.sh/v1beta2 | ||
kind: Redactor | ||
metadata: | ||
name: unlabelled-redactor-spec-1 | ||
spec: | ||
redactors: | ||
- name: redact-text-1 | ||
removals: | ||
values: | ||
- REDACT FIRST TEXT PLEASE | ||
garbagge: MWdRRTlBRi9YNzB3eUE2VEgvWjdhRFVUR1UvRmU3TXdUR3Q4cnE4Nkti |
28 changes: 28 additions & 0 deletions
28
testdata/supportbundle/labelled-bundle-unlabelled-redactor/sb-spec-1.yaml
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,28 @@ | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: labelled-support-bundle-1 | ||
labels: | ||
troubleshoot.io/kind: support-bundle | ||
stringData: | ||
support-bundle-spec: | | ||
apiVersion: troubleshoot.sh/v1beta2 | ||
kind: SupportBundle | ||
metadata: | ||
name: labelled-support-bundle-1 | ||
spec: | ||
collectors: | ||
- data: | ||
name: echo-hi-1 | ||
data: "I am labelled-support-bundle-1 REDACT FIRST TEXT PLEASE" | ||
custom-spec-key: | | ||
apiVersion: troubleshoot.sh/v1beta2 | ||
kind: SupportBundle | ||
metadata: | ||
name: custom-spec-key | ||
spec: | ||
collectors: | ||
- data: | ||
name: echo-hi-3 | ||
data: "I am custom-spec-key REDACT FIRST TEXT PLEASE" | ||
garbagge: MWdRRTlBRi9YNzB3eUE2VEgvWjdhRFVUR1UvRmU3TXdUR3Q4cnE4Nkti |