Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Konflux CEL expressions #250

Merged
merged 1 commit into from
Mar 8, 2024
Merged

Conversation

JasonPowr
Copy link
Contributor

This pr makes changes to the tekton cel expressions, this makes sure that the fbc images, the bundle and the operator can build independently.

Explanation (Copied from slack)

"I think having the operator and the bundle in the same application in Konflux causes some issues.When we generate an image for the operator-controller in Konflux, we then go back and update the bundle. When we update the bundle it generates a new image for the operator-controller, this means that when we release we use a snapshot that has an up to date controller image, but the image being used in the bundle isn’t the one in the snapshot, it's the one generated previously. If we were to separate them into different applications they could be built independently, wdyt? Or probably a better solution would be to add the cel expression to the operator pipelines?"

@JasonPowr JasonPowr requested a review from lance March 6, 2024 09:57
@openshift-ci openshift-ci bot requested review from sallyom and tommyd450 March 6, 2024 09:57
Copy link

openshift-ci bot commented Mar 6, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JasonPowr

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

The pull request process is described here

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

@openshift-ci openshift-ci bot added the approved label Mar 6, 2024
Copy link
Member

@lance lance left a comment

Choose a reason for hiding this comment

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

Can you add go.sum and Makefile to the operator pipelines?

@@ -7,7 +7,8 @@ metadata:
build.appstudio.redhat.com/pull_request_number: '{{pull_request_number}}'
build.appstudio.redhat.com/target_branch: '{{target_branch}}'
pipelinesascode.tekton.dev/max-keep-runs: "3"
pipelinesascode.tekton.dev/on-cel-expression: event == "pull_request" && target_branch == "main"
pipelinesascode.tekton.dev/on-cel-expression: |
event == "pull_request" && target_branch == "main" && (".tekton/rhtas-operator-pull-request.yaml".pathChanged() || "api/***".pathChanged() || "config/***".pathChanged() || "controllers/***".pathChanged() || "Dockerfile.rhtas-operator.rh".pathChanged() || "go.mod".pathChanged() || "main.go".pathChanged() )
Copy link
Member

Choose a reason for hiding this comment

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

I don't love this, since it won't catch new files or directories at the root. But I'm not sure what is a better way to handle it. You might add go.sum and Makefile to this list.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I get what your saying, but at the same time if a new directory or file is introduced that affects the build of the operator, there would be changes in the directories listed in the expression to reflect whatever changes are needed.

I've added go.sum and Makefile :)

.tekton/rhtas-operator-push.yaml Outdated Show resolved Hide resolved
@JasonPowr JasonPowr force-pushed the update-cel-expressions branch from be8f280 to 11e6382 Compare March 6, 2024 14:47
@JasonPowr JasonPowr requested a review from lance March 7, 2024 09:46
@lance
Copy link
Member

lance commented Mar 8, 2024

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Mar 8, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit 667f29b into main Mar 8, 2024
18 checks passed
@osmman osmman deleted the update-cel-expressions branch April 5, 2024 12:42
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.

2 participants