-
Notifications
You must be signed in to change notification settings - Fork 23
Build toolchain on GitHub Actions #31
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
Open
zwass
wants to merge
19
commits into
master
Choose a base branch
from
zwass-gh-actions
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+58
−3
Open
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
ac10515
Build toolchain on GitHub Actions
zwass 47b81f8
Add dependencies installation step in workflow
zwass 9959188
Simplify dependencies installation in workflow
zwass 7782810
Update ZLIB version and checksum in config
zwass f1b6a21
Update ZLIB version and URL in config
zwass 6db2694
Upload artifacts and pin actions
zwass 375aa91
Rename paths for output artifact
zwass 923ff44
Update build workflow to handle versioning correctly
zwass 3234d1c
Remove output spinner and fix artifact upload path
zwass 2e539ab
Revert attempt to remove progress spinner
zwass d45afd9
Turn off CI log progress spinner
zwass 4d02161
Disable progress bar in x86_64 build
zwass 3352333
Disable progress bar in aarch64 build
zwass 84e8441
Remove CT_LOG_PROGRESS_BAR setting from config
zwass bb46376
Add versioning to build artifact naming
zwass 04348cf
Fix typo in uname command for VERSION assignment
zwass 36a125e
Update GitHub Actions workflow to use matrix strategy
zwass 1a5c31b
Upload release on tag
zwass 82979d0
Simplify version setting in build workflow
zwass File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
| name: Build Toolchain | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ "master" ] | ||
| tags: [ "*" ] | ||
| pull_request: | ||
| branches: [ "master" ] | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| build: | ||
| permissions: | ||
| contents: write | ||
| strategy: | ||
| matrix: | ||
| os: [ubuntu-22.04, ubuntu-22.04-arm] | ||
| runs-on: ${{ matrix.os }} | ||
|
|
||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 | ||
|
|
||
| - name: Set Version | ||
| run: echo "VERSION=$(git describe --tags --always --dirty)-$(uname -m)" >> "$GITHUB_ENV" | ||
|
|
||
| - name: Dependencies | ||
| run: | | ||
| sudo apt-get update | ||
| sudo apt-get install help2man libtool-bin libncurses-dev ninja-build texinfo xz-utils gawk -y | ||
|
|
||
| - name: Build | ||
| run: ./build.sh "/opt/osquery-toolchain" | ||
|
|
||
| - name: Archive | ||
| run: | | ||
| cd /opt/osquery-toolchain/final | ||
| mv sysroot osquery-toolchain | ||
| tar -pcvJf osquery-toolchain-${VERSION}.tar.xz osquery-toolchain | ||
|
|
||
| - name: Upload Artifact | ||
| uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f #v6.0.0 | ||
| with: | ||
| name: osquery-toolchain-${{ env.VERSION }} | ||
| path: /opt/osquery-toolchain/final/osquery-toolchain-${{ env.VERSION }}.tar.xz | ||
|
|
||
| - name: Upload Release Asset | ||
| if: ${{ github.ref_type == 'tag' }} | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
| run: | | ||
| gh release upload "${GITHUB_REF_NAME}" \ | ||
| "/opt/osquery-toolchain/final/osquery-toolchain-${VERSION}.tar.xz" \ | ||
| --repo "${GITHUB_REPOSITORY}" | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
We should rename this to main while you're tinkering
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'd prefer to address that separately, and through all the osquery repos when we do it.