-
Notifications
You must be signed in to change notification settings - Fork 961
Repro nightly builds #7651
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
Merged
ShahanaFarooqui
merged 4 commits into
ElementsProject:master
from
s373nZ:7117-repro-nightly-builds
Nov 1, 2024
Merged
Repro nightly builds #7651
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
faeaa1b
make: Add a phony `version` target to output version string.
s373nZ d5e4542
build: Nightly repro build for Ubuntu Noble.
s373nZ 7ed7e09
build: Repro build matrix strategy for focal, jammy and noble. ([#7117])
s373nZ c7f89c3
repro: focal modded fix
ShahanaFarooqui 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,78 @@ | ||
| --- | ||
| # https://docs.corelightning.org/docs/repro | ||
| name: Repro Build Nightly | ||
| on: | ||
| # 05:00 Berlin, 03:00 UTC, 23:00 New York, 20:00 Los Angeles | ||
| schedule: | ||
| - cron: "0 3 * * *" | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| ubuntu: | ||
| name: "Ubuntu repro build: ${{ matrix.version }}" | ||
| runs-on: ubuntu-22.04 | ||
| strategy: | ||
| fail-fast: false # Let each build finish. | ||
| matrix: | ||
| version: ['focal', 'jammy', 'noble'] | ||
| steps: | ||
| - name: Git checkout | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Build environment setup | ||
| run: | | ||
| echo "Building base image for ${{ matrix.version }}" | ||
| sudo docker run --rm -v $(pwd):/build ubuntu:${{ matrix.version }} bash -c "\ | ||
| apt-get update && \ | ||
| apt-get install -y debootstrap && \ | ||
| debootstrap ${{ matrix.version }} /build/${{ matrix.version }}" | ||
| sudo tar -C ${{ matrix.version }} -c . | docker import - ${{ matrix.version }} | ||
|
|
||
| - name: Builder image setup | ||
| run: docker build -t cl-repro-${{ matrix.version }} - < contrib/reprobuild/Dockerfile.${{ matrix.version }} | ||
|
|
||
| - name: Build using the builder image and store Git state | ||
| run: | | ||
| # Create release directory. | ||
| mkdir $GITHUB_WORKSPACE/release | ||
|
|
||
| # Perform the repro build. | ||
| docker run --name cl-build -v $GITHUB_WORKSPACE:/repo -e FORCE_MTIME=$(date +%F) -t cl-repro-${{ matrix.version }} | ||
|
|
||
| # Commit the image in order to inspect the build later. | ||
| docker commit cl-build cl-release | ||
|
|
||
| # Inspect the version. | ||
| docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-release bash -c "make version > /repo/release/version.txt" | ||
|
|
||
| # Inspect the Git tree state. | ||
| docker run --rm -v $GITHUB_WORKSPACE:/repo -t cl-release bash -c "\ | ||
| git --no-pager status > /repo/release/git.log && \ | ||
| git --no-pager diff >> /repo/release/git.log" | ||
|
|
||
| # Change permissions on the release files for access by the runner environment. | ||
| sudo chown -R runner $GITHUB_WORKSPACE/release | ||
|
|
||
| - name: Assert clean version and release | ||
| run: | | ||
| echo 'Version:' | ||
| cat release/version.txt | ||
| echo -e | ||
|
|
||
| releasefile=$(ls release/clightning-*) | ||
| echo 'Release file:' | ||
| ls -al release/clightning-* | ||
| echo -e | ||
|
|
||
| if [ -n "$(cat release/version.txt | sed -n '/-modded/p')" ] || \ | ||
| [ -n "$(echo $releasefile | sed -n '/-modded/p')" ] | ||
| then | ||
| echo "Git Status and Diff:" | ||
| cat release/git.log | ||
| echo -e | ||
|
|
||
| echo 'Error: release modded / dirty tree.' | ||
| exit 1 | ||
| else | ||
| echo 'Success! Clean release.' | ||
| fi | ||
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.