redhat-developer / devconsole-operator

Enable a developer-focused view in OpenShift 4 web console
24 stars 28 forks source link

Create make target to push operator to the quay app registry for tests. #174

Closed pmacik closed 5 years ago

pmacik commented 5 years ago

This PR:

openshift-ci-robot commented 5 years ago

Hi @pmacik. Thanks for your PR.

I'm waiting for a redhat-developer member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
pmacik commented 5 years ago

The changes look find - but make push-operator-app-registry results in a docker image being created for the operator.

@ldimaggi Yes, that is because the push-operator-image target is called before (as a dependency). The idea is to build fresh local operator image, tag it with the generated unique name - including the $(TAG) string - push it to the quay.io image repository and then reference this unique image in the operator manifest. That manifest is then used to package the operator application and push it to the app registry (in quay.io) with that unique name. Then, the unique operator application can be referenced in the OperatorSource.

This approach makes it possible to test the current state of the code of the operator - locally or automated in a "per-PR" manner.

baijum commented 5 years ago

/ok-to-test

ldimaggi commented 5 years ago

The "REPLACE_IMAGE" placeholder here must also be updated before the operator is pushed to quay.io:

https://github.com/redhat-developer/devconsole-operator/blob/master/manifests/devconsole/0.1.0/devconsole-operator.v0.1.0.clusterserviceversion.yaml#L82

pmacik commented 5 years ago

The "REPLACE_IMAGE" placeholder here must also be updated before the operator is pushed to quay.io:

@ldimaggi It is updated - the placeholder is already being replaced. That is what this line is for :)

ldimaggi commented 5 years ago

/approve

pmacik commented 5 years ago

/assign @sbose78

openshift-ci-robot commented 5 years ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: baijum, ldimaggi, sbose78

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: - ~~[OWNERS](https://github.com/redhat-developer/devconsole-operator/blob/master/OWNERS)~~ [baijum,sbose78] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
pmacik commented 5 years ago

Any luck with figuring out how to add secrets to openshift ci?

Haven't tried, yet.