Skip to content

Restrict test log outputs - #1450

Merged
openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
jistr:f/restrict-log-output
Jul 24, 2026
Merged

Restrict test log outputs#1450
openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
jistr:f/restrict-log-output

Conversation

@jistr

@jistr jistr commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

This to avoid printing secrets into logs, as another layer of security, even though the CI environments are isolated and short-lived.

The change does the following:

  • Default use_no_log: true.

  • Add use_no_log onto more tasks.

  • Disable xtrace (set -x) on such tasks as another precaution. This is done via a new shell_header_no_xtrace variable so that the behavior is not hardcoded.

If debugging of the relevant tasks is necessary, it can be done by tweaking these variables for a testproject.

Assisted by: goose+gemini

This to avoid printing secrets into logs, as another layer of
security, even though the CI environments are isolated and
short-lived.

The change does the following:

* Default `use_no_log: true`.

* Add `use_no_log` onto more tasks.

* Disable xtrace (`set -x`) on such tasks as another precaution. This
  is done via a new `shell_header_no_xtrace` variable so that the
  behavior is not hardcoded.

If debugging of the relevant tasks is necessary, it can be done by
tweaking these variables for a testproject.

Assisted by: goose+gemini

@cjeanner cjeanner left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds a reasonable way to avoid leaking data. I love the way you allow to override the "set -x" set in the default shell_header. Maybe this needs to be properly documented though in the adoption documentation?

@jistr

jistr commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the reviews, i'll add the needed labels.

@openshift-ci

openshift-ci Bot commented Jul 24, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by:

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jistr

jistr commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

Re documentation, that automation and the variable is CI/tests only, we don't have set -x for end users.

@openshift-merge-bot
openshift-merge-bot Bot merged commit 794064a into openstack-k8s-operators:main Jul 24, 2026
5 checks passed
@jistr

jistr commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

/cherry-pick 18.0-fr6

@openshift-cherrypick-robot

Copy link
Copy Markdown

@jistr: new pull request created: #1457

Details

In response to this:

/cherry-pick 18.0-fr6

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@jistr

jistr commented Jul 28, 2026

Copy link
Copy Markdown
Contributor Author

/cherry-pick 18-stable

@openshift-cherrypick-robot

Copy link
Copy Markdown

@jistr: new pull request created: #1462

Details

In response to this:

/cherry-pick 18-stable

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants