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

github: Add workflow to check ed25519 upstream #294

Merged
merged 1 commit into from
Oct 30, 2020

Conversation

jku
Copy link
Collaborator

@jku jku commented Oct 28, 2020

securesystemslib includes a vendored copy of https://github.com/pyca/ed25519.git . The upstream is not a very lively project by any means but we would like to know if something ever happens there (like a bug fix).

  • Add a script that checks if upstream master HEAD is unchanged. The script could be included in the workflow but is separate for two purposes:
    a) specifying the expected hash in git
    b) running the check on developers machine
  • Add a github workflow that once a day files an issue if the upstream master head has changed and if an issue is not open yet

The opened issue looks like this jku#3. I've tested this in my repo but unfortunately I think it won't be possible to test the workflow in securesystemslib repo before the file exists in master branch (after it exists, the workflow can be executed manually even from a branch).

@jku
Copy link
Collaborator Author

jku commented Oct 28, 2020

I did this as much to understand github workflows as for the actual purpose of having the automated upstream check -- so if you don't like it feel free to complain :)

Making this a github workflow seemed like more useful than a travis job: now it does not block other PRs and actually opens the issue which is what we want

@coveralls
Copy link

coveralls commented Oct 28, 2020

Coverage Status

Coverage remained the same at 98.868% when pulling 639c9ea on jku:check-upstream-ed25519 into d4fef67 on secure-systems-lab:master.

@jku
Copy link
Collaborator Author

jku commented Oct 28, 2020

I think I'll move the shell script to securesystemslib/_vendor/test-ed25519-upstream.sh: it really does not need to live in project root

@jku jku force-pushed the check-upstream-ed25519 branch from 6a362bd to 6a5bee8 Compare October 28, 2020 17:13
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

for those not familiar with Github actions: this uses-line refers to the Github repository "actions/checkout", where actions is an official Github organization -- so I'm not using any random action-repos here.

Copy link
Collaborator

@joshuagl joshuagl left a comment

Choose a reason for hiding this comment

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

Nice use of GitHub Actions, thanks @jku

.github/workflows/check-upstream-ed25519.yml Outdated Show resolved Hide resolved
.github/workflows/check-upstream-ed25519.yml Outdated Show resolved Hide resolved
})

if (issues.data.total_count > 0) {
console.log("Issue is already open, not creating.")
Copy link
Collaborator

Choose a reason for hiding this comment

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

Where do these log messages go?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

You can get to them from the actions tab, here's an example where master had changed but an open issue was already found: https://github.com/jku/securesystemslib/runs/1321303954

securesystemslib includes a vendored copy of
https://github.com/pyca/ed25519.git . The upstream is not a very lively
project by any means but we would like to know if something happens
there (like a bug fix).

* Add a script that checks if upstream master HEAD is unchanged
  (the expected commit is in the script)
* Add a github workflow that once a day files an issue if the upstream
  master head has changed and if an issue is not open yet
@jku jku force-pushed the check-upstream-ed25519 branch from 6a5bee8 to 639c9ea Compare October 30, 2020 09:55
@jku
Copy link
Collaborator Author

jku commented Oct 30, 2020

Amended the commit with suggested string fixes (thanks) and a whitespace fix.

Copy link
Member

@lukpueh lukpueh left a comment

Choose a reason for hiding this comment

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

Very cool stuff, @jku!

@lukpueh lukpueh merged commit 2006341 into secure-systems-lab:master Oct 30, 2020
@jku
Copy link
Collaborator Author

jku commented Oct 30, 2020

we should see if it works in about 50 minutes since ed25519 has today had its first commits in 7 years :)

@lukpueh lukpueh mentioned this pull request Nov 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants