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

Added CONTAINER_TOOL to set container tool for operator build (#6089) #6090

Conversation

stanislavulrych
Copy link

Implementation of #6089

@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 15, 2022 22:37 Inactive
@jmrodri
Copy link
Member

jmrodri commented Oct 15, 2022

@stanislavulrych if you don't mind adding a changelog for this PR. The contents of the PR looks great.

@stanislavulrych
Copy link
Author

@jmrodri Added. Please see the last commit.

Copy link
Contributor

@everettraven everettraven left a comment

Choose a reason for hiding this comment

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

Hi @stanislavulrych, thanks for the contribution! I really like this change since it gives an operator author more flexibility in the tooling they choose to use :)

I noticed a couple things:

  • A minor typo in the changelog
  • There are changes to the scaffolds, so that means we need to regenerate our testdata using make generate. This will help us keep the testdata up to date.

changelog/fragments/enable-setting-of-container-tool.yaml Outdated Show resolved Hide resolved
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 17:14 Inactive
stanislavulrych and others added 3 commits October 17, 2022 20:44
…or-framework#6089)

Signed-off-by: Stanislav Ulrych <stanislav.ulrych@getmanta.com>
…or-framework#6089)

Signed-off-by: Stanislav Ulrych <stanislav.ulrych@getmanta.com>
Co-authored-by: Bryce Palmer <everettraven@gmail.com>
Signed-off-by: Stanislav Ulrych <stanislav.ulrych@getmanta.com>
@stanislavulrych stanislavulrych requested review from everettraven and removed request for jmrodri and jberkhahn October 17, 2022 18:57
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 18:58 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych stanislavulrych temporarily deployed to deploy October 17, 2022 19:33 Inactive
@stanislavulrych
Copy link
Author

@everettraven originally, I intended to only implement this change for go based operators. But from the running of make generate, the changes is also propagated to ansible based operator, hence further changes. I also commit the generated tests.

However, I can still see there are docker targets hardcoded and the resulting test code is not as I expect it.

Specifically, there are targets using docker buildx. Unlike other docker commands, buildx does not have direct equivalent in podman, so this would require podman/buildah specific commands.

@everettraven
Copy link
Contributor

Hi @stanislavulrych I think it is fine for the changes to go into the ansible and helm operators as well, but now that I think about it the Go operator scaffolding is done via Kubebuilder. Operator SDK pulls in Kubebuilder's CLI in and extends it to add the ansible and helm plugins but the go/v3 plugin is maintained as part of the Kubebuilder source code.

Any changes to the scaffolds for a Go based operator would have to be done in https://github.com/kubernetes-sigs/kubebuilder (aside from the catalog-build and catalog-push targets you successfully modified here - those are maintained by us with the manifests plugin).

If you are still interested in continuing to contribute this functionality, we can hold this PR on the necessary changes being made in Kubebuilder and then updating this PR to contain the necessary changes for SDK (I presume that most of these changes will stay the same, but I would personally rather wait until the changes are merged into Kubebuilder and pulled into SDK before we commit these changes just in case something needs to be changed slightly).

Specifically, there are targets using docker buildx. Unlike other docker commands, buildx does not have direct equivalent in podman, so this would require podman/buildah specific commands.

This would also have to be a change made in Kubebuilder. There would likely need to be a bit more discussion as to how to handle this properly over there, but as a reviewer/maintainer in Kubebuilder I would be happy to help discuss any changes that need to be made.

@stanislavulrych
Copy link
Author

Hi @everettraven I agree and I will try to open a respective pull request in kubebuilder then.

@everettraven
Copy link
Contributor

@stanislavulrych Sounds good. I will go ahead and add a hold to this PR for the time being. Thanks for the contributions!

/hold

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Oct 20, 2022
@openshift-bot
Copy link

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@openshift-ci openshift-ci bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 19, 2023
@openshift-bot
Copy link

Stale issues rot after 30d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle rotten
/remove-lifecycle stale

@openshift-ci openshift-ci bot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Feb 18, 2023
@openshift-bot
Copy link

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

@openshift-ci openshift-ci bot closed this Mar 21, 2023
@openshift-ci
Copy link

openshift-ci bot commented Mar 21, 2023

@openshift-bot: Closed this PR.

In response to this:

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

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/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants