-
Notifications
You must be signed in to change notification settings - Fork 671
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
Update github action CI workflow #3199
Conversation
One more decision I made in this PR (that I did not use for testing) - the jobs all use the current model like this:
so i left it as-is. however, this does make it hard to make changes to the ci workflow since a push to master is required to get changes into github actions. during testing, i was using the local path to the action, ex:
Both methods have their pros/cons - I felt it was important to note that here in this PR. |
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.
Amazing work! It's already polished, but I left some comments for minor changes, questions, and alternative ideas in some places if interested.
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.
These changes look good to me -- I'll defer to Charlie and Jude for final approvals.
My only request is that you update the README.md (or add a RELEASING.md) with two instructions:
- How to tag a release (I think this is already kind of mentioned in the release checklist, but it could have it's own subsubsection in the README), and what happens automatically when the release is tagged (docker images pushed? binaries included in the git release? changelog?)
- How to trigger a "feature" build: if I have a PR, and I want to publish a docker image with a specific tag (not a version number) that doesn't create a new release, how can I do that? I think before these changes, that was done "automatically" on every
feat/...
PR, but with these changes, I think it requires a manual trigger, right?
sorry, i missed this comment when i was addressing other changes. I'll check and reply later, optionally with a commit to address the questions |
PR a branch to develop:
Merging a PR to develop:
Merging a PR develop to master:
Manually triggering workflow without tag (any branch):
Manually triggering workflow with tag (non-default branch):
Manually triggering workflow with tag on default branch (i.e. tag of
|
Can you add that info either to the |
Can do - will add a new file and bump the issue dealing with the readme updates |
|
@CharlieC3 i think there's one more change i have to make here that i missed in my tests. |
Why would merging a PR to develop (effectively making a commit to
Sometimes we create release-candidate Github tags off the |
there are a few typos in the comment i made updated here: https://github.com/wileyj/stacks-blockchain/blob/feat/update-ci/RELEASING.md however, your second point is correct and only something i noticed myself the other day (#3199 (comment) Once i get those changes committed, it will also update the RELEASING.md file. I'll ping you again when I think it's ready, it was a use case i wasn't thinking about when i sent this PR. |
related - #3559 |
testing the locally built packages/docker images is successful, this reverts those changes need for testing the resulting artifacts
moved this to |
use current settings from master branch
done, matching what's currently in the |
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 scanned through all the changes made and comments addressed since my last review, it looks great. There's a lot of changes being made here though, so catching any logical or functional errors is not easy and very time-consuming. Assuming it all works as described in the ci-release doc, I think we're good to go!
However, we may need to be prepared to make some quick followup adjustments after merging if we find something important is not quite right with the new processes.
* master: (108 commits) chore: add sip-024 text Chore - adding 2.4.0.0.0 to changelog sanitize-gate the depth check add epoch.truncate add comment to affirmation module explaining change update mainnet 2.4 height with sip-024 value fix: affirmation calc should skip any ops whose parent is <= first_block_height address PR feedback address PR feedback, enable sanitization in from-consensus-buff chore: improve comments fix: allow change of delegation data added more test coverage for epoch 2.4 more sanitization unit cases fix pox_3 auto_unlock tests feat: implement proposed SIP-024 sanitization logic for epoch-2.4 chore: update testnet 2.4 activation fixed test, added to gh workflow added epoch2.4 test chore: PR feedback (pox_3_first_cycle off-by-one) Revert "chore: PR feedback (pox_3_first_cycle off-by-one)" ...
* Updating Github Action - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * only run btc int tests on default branch * enable btc int test on develop * Feat/update ci (stacks-network#38) * Updating Github Action - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * only run btc int tests on default branch * final action test disabled a lot of the long-running tests * Update ci.yml * Update ci.yml * Update bitcoin-tests.yml * Update bitcoin-tests.yml * run on push to master (merge) * Update Github Actions - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * adding build features to dockerfiles * update repo org to stacks-network missed a ref to wileyj forked repo * addressing comments in pr 3199 see stacks-network#3199 for changes requested * cleaning up docker tags prevent overwriting of docker image branch tags * disabling audit workflow disabling this workflow until we can test further * Adding a release file * Update to trigger logic Updating the logic of how/when builds and releases happen based on comments in PR. Updated the RELEASING.md file to reflect these changes * chore: delete circle.yml CircleCI hasn't been used in 11+ months. Fixes stacks-network#3072 * switch repo&owner to var remove hardcoded value in favor or `GITHUB_REPOSITORY` * use local workflows * fix: don't assume that the bitcoin node always gives a non-zero number of headers * fix: add unit test and change log entry * fix: Exclude benchmarks from compilation * fix: Resolve conflicts and the remaining two errors * clean: remove benchmark files * fix: use explicit version number * minor update to reconcile diffs since some files were renamed, some minor changes had to be made manually here, i.e. fail_ci_if_error: false * hardcode some vals for testing * revert * use org/repo locations for jobs testing the locally built packages/docker images is successful, this reverts those changes need for testing the resulting artifacts * Moving file to docs dir * continue build if unit-tests fail use current settings from master branch * 3199 - minor updates for recent upstream changes --------- Co-authored-by: Diwaker Gupta <[email protected]> Co-authored-by: Jude Nelson <[email protected]> Co-authored-by: Stjepan Golemac <[email protected]>
* Updating Github Action - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * only run btc int tests on default branch * enable btc int test on develop * Feat/update ci (stacks-network#38) * Updating Github Action - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * only run btc int tests on default branch * final action test disabled a lot of the long-running tests * Update ci.yml * Update ci.yml * Update bitcoin-tests.yml * Update bitcoin-tests.yml * run on push to master (merge) * Update Github Actions - build all release images from binaries - create checksum of binary artifacts for release - adds clippy and crate advisory actions - update all dockerfiles to use ramdisk for building - separate actions to relevant files - adds arm64 binaries/docker image - update all debian builds to use bullseye (latest debian) * adding build features to dockerfiles * update repo org to stacks-network missed a ref to wileyj forked repo * addressing comments in pr 3199 see stacks-network#3199 for changes requested * cleaning up docker tags prevent overwriting of docker image branch tags * disabling audit workflow disabling this workflow until we can test further * Adding a release file * Update to trigger logic Updating the logic of how/when builds and releases happen based on comments in PR. Updated the RELEASING.md file to reflect these changes * chore: delete circle.yml CircleCI hasn't been used in 11+ months. Fixes stacks-network#3072 * switch repo&owner to var remove hardcoded value in favor or `GITHUB_REPOSITORY` * use local workflows * fix: don't assume that the bitcoin node always gives a non-zero number of headers * fix: add unit test and change log entry * fix: Exclude benchmarks from compilation * fix: Resolve conflicts and the remaining two errors * clean: remove benchmark files * fix: use explicit version number * minor update to reconcile diffs since some files were renamed, some minor changes had to be made manually here, i.e. fail_ci_if_error: false * hardcode some vals for testing * revert * use org/repo locations for jobs testing the locally built packages/docker images is successful, this reverts those changes need for testing the resulting artifacts * Moving file to docs dir * continue build if unit-tests fail use current settings from master branch * 3199 - minor updates for recent upstream changes --------- Co-authored-by: Diwaker Gupta <[email protected]> Co-authored-by: Jude Nelson <[email protected]> Co-authored-by: Stjepan Golemac <[email protected]>
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Updates the CI workflow
Applicable issues
Additional info
Lots of proposed changes here so I'll do my best to articulate them:
The workflow behaves similarly to how the existing workflow runs - manual execution with a tag will create a new release. on PR's, a simplified workflow is run.
The
./build-scripts
Dockerfiles are all updated to be resuable but also renamed to reflect how the arches appear in the build process, i.e.linux-glibc-arm64
.Clippy has been added, and right now it's set to run on PR's to develop - as of now this action is quite messy. Opinions here are welcome, it may be desired to remove entirely, or perhaps run it on a cron so the data is available. Using defaults, it's very pedantic but it can be adjusted to ignore trivial lint complaints.
A crate advisory action is also added (I believe it's something that should remain in some form to ensure we're keeping up with dependency updates) - currently this action is to be scheduled nightly at 0330 UTC, and will create a new issue if any crate has a listed advisory.
Last, the build process is changed slightly:
CHECKSUMS.txt
which is included in the github release./github/actions/dockerhub/**
is created to build the new images for both Alpine and DebianCaveats
bitcoin-tests.yml
is set to run only when PR's are opened to the master branch (this is debatable, but in testing i felt it was running too often)x.y.z-stretch
->x.y.z-debian
Examples of builds
2.05.0.2.3
: https://github.com/wileyj/stacks-blockchain/actions/runs/2673483049