-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
chore: add CLA check action #15917
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
base: 2.5
Are you sure you want to change the base?
chore: add CLA check action #15917
Conversation
0b222b9 to
9275216
Compare
|
Wow, that was fast. Thank you very much. @ywwg is in contact with @rryan to get access to the original sheet and form. We have confirmed in a Mixxx e.V. resolution that we want to collect the GitHub user name, and want to keep the text of the agreement as it is to not to have to deal with two version of the agreement. We have also identified that want to keep the manual conformance of new contributors in an PR comment that they have signed the CLA. This serves as a second factor for identification. We may later improve that later, but lets keep the scope here minimal. |
|
Just noticed this warning in the CI Log: |
|
How is this terraform part used? I wonder how the credentials to look up the CLA form can be shared into a users PR. How is this finally done? |
Yes, that makes sense. Note that this action perform as following so far:
I guess it is good to add a manual check, but this will require core members to have to access to this form. Or do we want to restrict
I used this terraform to configure the GCP project to drive the automation, which includes:
There is no password, we are using OIDC for that matter. This is the most secure way to authenticate to a cloud provider from a workflow, you may find more details here |
|
Can't an attacker just alter the workflow in his PR and read out the whole spreadsheet? |
This means that we will have this lable on every single RR. Maybe we can reduce the visual clutter by ommit this and have only to-do type labels? |
|
With the manual confirm, we mean that the contributor confirms that he has signed in a PR comment. This way we know the singer was him and not a random troll. |
|
No. The reason is that your OIDC claim will include the origin repo. For example, in your case, it would include Now, in order to enhance security, I'm planning to restrict the source branch to only be from I will push the last changes soon, with the correct event setup, when I get back to my keyboard, likely later in the weekend |
Sounds good. I will also add the action as "required" so it would properly flag it before merge, in case the action wasn't to run for any reasons. |
We could ask them to comment back in the auto-comment? Something like "I confirm I have signed the CLA", tho I believe they can always delete their message later so not long term proof |
|
Yeah that's what we talked about, checking that there's a comment authored by the correct username that confirms signing |
|
I have not understand how the security works. In PR builds we have no access to mixxxdj credentials. If the we forward them, the users can change the workflow in the PR and retrieve the full spreadsheet. How do we handle that his is not happen? |
This is correct. This action is to expected to run as a A second layer of security (regarding OIDC) is that, before using this Github OIDC token, you need to issue a token, which required
Note that this PR already ensured that the author is the one that have signed the CLA. If we wanted to check that follow up comment (e.g "hey I have signed now") was made by the initial author of this same PR, this would be very easy, tho I am not sure this was help much. If somebody was to signed a PR they have authored (e.g as a troll or somebody that would want something pending CLA merged), it would still not pass the CLA checks. Happy to jump on a call to explain further. |
|
Ah OK, that makes sense. A pull_request_target should work.
How is this done? For my understanding anyone can sign the form and enter the users GitHub name. |
The idea was to prove, that the CLA was signed by the GitHub user and not by a third-party who just entered this username in the google docs. |
|
Ah that makes sense. In this case I can add a check that makes sure the follow up comment or 👍 is indeed issue by the author. Should be straightforward! |
CLA checkThank you for signing the CLA! |
5fb2d0c to
46448af
Compare
46f8274 to
0367dcb
Compare
|
This is now ready for review. I have carried few more tests to confirm it should work. I would suggest we take this for a spin, as soon as we have access to the Google Sheet. |
0367dcb to
6e60fe9
Compare
|
|
||
| # Edit the notice to thank them for signing the CLA AND providing an ACK | ||
| - name: Update the comment after signing and acknowledgement | ||
| if: steps.notice_needed.outcome == 'skipped' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How is this step triggered?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Either:
- A maintainer issue
/check-cla - A push/sync is made to the PR
| ## CLA check | ||
|
|
||
| Thank you for signing the CLA! | ||
| edit-mode: replace |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should not delete the old comment. This keeps it better traceable what has happened.
We has the case that user expresses concerns. When we delete the original message this concerns comment looses context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Technically, the comment only gets edited so we keep the full history. I guess two comments isn't too noisy tho?
|
I have still not understand how the tf files come into play. What happens if we delete all of them? |
They are only a reflection on how I have setup GCP resources for the automation. They are a like a recipe to get cloud resources from zero to a ready state, without requiring any manual operation (knows as "clickops"). I would suggest to read about IaC.
Nothing. They are only here in case:
To make a simple parallel, think of it as our The TLDR is, no need to understand them now. But if I leave the project, you will have a clear vision of what is set and how. |
Work in progress action to auto detect if CLA has been completed by the contributor
TODO:
Cleanup and document IaCDocument automation