Skip to content

.github/workflows: Add the unit and verify workflows #2096

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

Conversation

timflannagan
Copy link
Member

@timflannagan timflannagan commented Apr 13, 2021

Introduce two additional GH action workflows that match the existing
prow-based unit/verify jobs, with the intention of migrating off prow
entirely for master/4.8+ branch(es).

Description of the change:

Motivation for the change:

Reviewer Checklist

  • Implementation matches the proposed design, or proposal is updated to match implementation
  • Sufficient unit test coverage
  • Sufficient end-to-end test coverage
  • Docs updated or added to /doc
  • Commit messages sensible and descriptive

@timflannagan timflannagan force-pushed the add-unit-github-action branch 3 times, most recently from b4558e6 to a6bb8a8 Compare April 13, 2021 15:18
@timflannagan
Copy link
Member Author

/retest

@timflannagan timflannagan force-pushed the add-unit-github-action branch 10 times, most recently from c007061 to 471db81 Compare May 4, 2021 20:41
Introduce two additional GH action workflows that match the existing
prow-based unit/verify jobs, with the intention of migrating off prow
entirely for master/4.8+ branch(es).

Signed-off-by: timflannagan <[email protected]>
@timflannagan timflannagan force-pushed the add-unit-github-action branch from 471db81 to 275cbd8 Compare May 4, 2021 20:45
# The setup-go action does not set this value for us: https://github.com/actions/setup-go/issues/14.
- name: Run the verify target
run: |
export GOPATH=$(go env GOPATH)
Copy link
Member Author

Choose a reason for hiding this comment

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

I tried using the recommended environment files but the following error was produced when configuring the environment in a separate job:

$GOPATH/go.mod exists but should not
# Clients, listers, and informers
$GOPATH/go.mod exists but should not
./scripts/update_codegen.sh
$GOPATH/go.mod exists but should not
make: *** [Makefile:203: codegen] Error 1

@timflannagan timflannagan changed the title .github/workflows: Add a unit test workflow that mirrors the ci/prow/unit job .github/workflows: Introduce the unit and verify GH action workflows May 4, 2021
@timflannagan timflannagan changed the title .github/workflows: Introduce the unit and verify GH action workflows .github/workflows: Add the unit and verify workflows May 4, 2021
@timflannagan
Copy link
Member Author

Corresponding PR in o/release to remove those prow-based jobs entirely: openshift/release#18324.

@timflannagan
Copy link
Member Author

            	            	clusterroles.rbac.authorization.k8s.io "csv-role" already exists

/rerun-workflow unit

@timflannagan
Copy link
Member Author

/rerun-all

@timflannagan
Copy link
Member Author

/rerun-workflow e2e-tests

@@ -0,0 +1,25 @@
name: unit
Copy link
Member

Choose a reason for hiding this comment

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

nit: this ends up being called "unit/unit" and "verify/verify" on the github actions on the PR...could we have them be under "test/unit" or something instead?

Copy link
Member

Choose a reason for hiding this comment

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

same names as the registry github actions

Copy link
Member Author

Choose a reason for hiding this comment

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

That's how the registry GH actions are currently named, and I didn't see any evidence we have any consistent naming of workflows/jobs here. I don't have a strong opinion either way so I'm fine with renaming both of the workflow names to be test unless that's problematic having two separate workflows that share the same name.

Copy link
Member

Choose a reason for hiding this comment

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

Yes, I don't know if we have an explicit convention. Looks like our OLM github actions now are under "upstream-tests/" and "e2e-tests/" so maybe putting these under "upstream-tests/" for now makes sense.

That being said this is now solely the upstream repository so I feel like we could drop the "upstream-" in a follow-up PR.

Copy link
Member Author

Choose a reason for hiding this comment

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

@exdx There may be an existing upstream issue for this, or at least I mentioned it in removing the OCP manifests from the repository issue, but I plan on tackling some more updates to the CI pipeline once we migrate off of prow (note: but not tide), so I think it's fine to keep the current workflow/job names with the intention of trying to create a more generalized naming convention in a subsequent PR.

Copy link
Contributor

Choose a reason for hiding this comment

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

+1, let's revisit this topic since there isn't an existing convention. Also agreed that explicitly calling things "upstream" doesn't make sense as we migrate the downstream bits out of operator-framework.

@benluddy
Copy link
Contributor

benluddy commented May 6, 2021

/approve

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 6, 2021
Copy link
Member

@dinhxuanvu dinhxuanvu left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label May 6, 2021
@openshift-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: benluddy, dinhxuanvu, timflannagan

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-merge-robot openshift-merge-robot merged commit e65b9fb into operator-framework:master May 6, 2021
@timflannagan timflannagan deleted the add-unit-github-action branch May 6, 2021 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants