Skip to content

Commit 44f652f

Browse files
committed
Merge branch 'stable' into testing
2 parents 4ef784f + 7ffa8c2 commit 44f652f

File tree

2 files changed

+320
-7
lines changed

2 files changed

+320
-7
lines changed

.github/workflows/cron.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Daily
22
on:
33
schedule:
4-
- cron: "45 3 * * *"
4+
- cron: "10 20 * * *"
55

66
jobs:
77
build:
@@ -41,7 +41,7 @@ jobs:
4141

4242
name: '${{ matrix.target.os }}-${{ matrix.target.cpu }} (Nim ${{ matrix.branch }})'
4343
runs-on: ${{ matrix.builder }}
44-
continue-on-error: ${{ matrix.branch }} == 'devel'
44+
continue-on-error: ${{ matrix.branch == 'devel' }}
4545
steps:
4646
- name: Checkout nimbus-eth2
4747
uses: actions/checkout@v2
@@ -151,6 +151,11 @@ jobs:
151151
brew install gnu-getopt
152152
brew link --force gnu-getopt
153153
154+
- name: Build Nim and Nimbus dependencies
155+
shell: bash
156+
run: |
157+
make -j ${ncpu} NIM_COMMIT=${{ matrix.branch }} ARCH_OVERRIDE=${PLATFORM} QUICK_AND_DIRTY_COMPILER=1 update
158+
154159
- name: Get latest fixtures commit hash
155160
id: fixtures_version
156161
shell: bash
@@ -173,11 +178,6 @@ jobs:
173178
run: |
174179
scripts/setup_official_tests.sh fixturesCache
175180
176-
- name: Build Nim and Nimbus dependencies
177-
shell: bash
178-
run: |
179-
make -j ${ncpu} NIM_COMMIT=${{ matrix.branch }} ARCH_OVERRIDE=${PLATFORM} QUICK_AND_DIRTY_COMPILER=1 update
180-
181181
- name: Smoke test the Beacon Node and Validator Client with all tracing enabled
182182
shell: bash
183183
run: |
Lines changed: 313 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,313 @@
1+
name: Nightly build
2+
on:
3+
schedule:
4+
- cron: "45 4 * * *"
5+
workflow_dispatch:
6+
#pull_request:
7+
8+
jobs:
9+
build-amd64:
10+
name: Linux AMD64 release asset
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v2
15+
with:
16+
ref: unstable
17+
18+
- name: Build project
19+
id: make_dist
20+
run: |
21+
make dist-amd64
22+
cd dist
23+
ARCHIVE=$(echo *.tar.gz)
24+
tar -xzf ${ARCHIVE}
25+
NEW_ARCHIVE_DIR="nimbus-eth2_Linux_amd64_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
26+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
27+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
28+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
29+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
30+
31+
- name: Upload archive artefact
32+
uses: actions/upload-artifact@v2
33+
with:
34+
name: Linux_amd64_archive
35+
path: ./dist/${{ steps.make_dist.outputs.archive }}
36+
retention-days: 2
37+
38+
- name: Upload checksum artefact
39+
uses: actions/upload-artifact@v2
40+
with:
41+
name: Linux_amd64_checksum
42+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
43+
retention-days: 2
44+
45+
build-arm64:
46+
name: Linux ARM64 release asset
47+
runs-on: ubuntu-latest
48+
steps:
49+
- name: Install packages
50+
env:
51+
DEBIAN_FRONTEND: "noninteractive"
52+
TZ: "Etc/UTC"
53+
run: |
54+
sudo apt-get -qq update
55+
sudo apt-get -qq -y install binfmt-support qemu-user-static
56+
57+
- name: Checkout code
58+
uses: actions/checkout@v2
59+
with:
60+
ref: unstable
61+
62+
- name: Build project
63+
id: make_dist
64+
run: |
65+
make dist-arm64
66+
cd dist
67+
ARCHIVE=$(echo *.tar.gz)
68+
tar -xzf ${ARCHIVE}
69+
NEW_ARCHIVE_DIR="nimbus-eth2_Linux_arm64v8_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
70+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
71+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
72+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
73+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
74+
75+
- name: Upload archive artefact
76+
uses: actions/upload-artifact@v2
77+
with:
78+
name: Linux_arm64_archive
79+
path: ./dist/${{ steps.make_dist.outputs.archive }}
80+
retention-days: 2
81+
82+
- name: Upload checksum artefact
83+
uses: actions/upload-artifact@v2
84+
with:
85+
name: Linux_arm64_checksum
86+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
87+
retention-days: 2
88+
89+
build-arm:
90+
name: Linux ARM release asset
91+
runs-on: ubuntu-latest
92+
steps:
93+
- name: Install packages
94+
env:
95+
DEBIAN_FRONTEND: "noninteractive"
96+
TZ: "Etc/UTC"
97+
run: |
98+
sudo apt-get -qq update
99+
sudo apt-get -qq -y install binfmt-support qemu-user-static
100+
101+
- name: Checkout code
102+
uses: actions/checkout@v2
103+
with:
104+
ref: unstable
105+
106+
- name: Build project
107+
id: make_dist
108+
run: |
109+
make dist-arm
110+
cd dist
111+
ARCHIVE=$(echo *.tar.gz)
112+
tar -xzf ${ARCHIVE}
113+
NEW_ARCHIVE_DIR="nimbus-eth2_Linux_arm32v7_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
114+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
115+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
116+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
117+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
118+
119+
- name: Upload archive artefact
120+
uses: actions/upload-artifact@v2
121+
with:
122+
name: Linux_arm_archive
123+
path: ./dist/${{ steps.make_dist.outputs.archive }}
124+
retention-days: 2
125+
126+
- name: Upload checksum artefact
127+
uses: actions/upload-artifact@v2
128+
with:
129+
name: Linux_arm_checksum
130+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
131+
retention-days: 2
132+
133+
build-win64:
134+
name: Windows AMD64 release asset
135+
runs-on: ubuntu-latest
136+
steps:
137+
- name: Checkout code
138+
uses: actions/checkout@v2
139+
with:
140+
ref: unstable
141+
142+
- name: Build project
143+
id: make_dist
144+
run: |
145+
make dist-win64
146+
cd dist
147+
ARCHIVE=$(echo *.tar.gz)
148+
tar -xzf ${ARCHIVE}
149+
NEW_ARCHIVE_DIR="nimbus-eth2_Windows_amd64_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
150+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
151+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
152+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
153+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
154+
155+
- name: Upload archive artefact
156+
uses: actions/upload-artifact@v2
157+
with:
158+
name: Windows_amd64_archive
159+
path: ./dist/${{ steps.make_dist.outputs.archive }}
160+
retention-days: 2
161+
162+
- name: Upload checksum artefact
163+
uses: actions/upload-artifact@v2
164+
with:
165+
name: Windows_amd64_checksum
166+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
167+
retention-days: 2
168+
169+
build-macos-amd64:
170+
name: macOS AMD64 release asset
171+
runs-on: ubuntu-latest
172+
steps:
173+
- name: Checkout code
174+
uses: actions/checkout@v2
175+
with:
176+
ref: unstable
177+
178+
- name: Build project
179+
id: make_dist
180+
run: |
181+
make dist-macos
182+
cd dist
183+
ARCHIVE=$(echo *.tar.gz)
184+
tar -xzf ${ARCHIVE}
185+
NEW_ARCHIVE_DIR="nimbus-eth2_macOS_amd64_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
186+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
187+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
188+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
189+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
190+
191+
- name: Upload archive artefact
192+
uses: actions/upload-artifact@v2
193+
with:
194+
name: macOS_amd64_archive
195+
path: ./dist/${{ steps.make_dist.outputs.archive }}
196+
retention-days: 2
197+
198+
- name: Upload checksum artefact
199+
uses: actions/upload-artifact@v2
200+
with:
201+
name: macOS_amd64_checksum
202+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
203+
retention-days: 2
204+
205+
build-macos-arm64:
206+
name: macOS ARM64 release asset
207+
runs-on: ubuntu-latest
208+
steps:
209+
- name: Checkout code
210+
uses: actions/checkout@v2
211+
with:
212+
ref: unstable
213+
214+
- name: Build project
215+
id: make_dist
216+
run: |
217+
make dist-macos-arm64
218+
cd dist
219+
ARCHIVE=$(echo *.tar.gz)
220+
tar -xzf ${ARCHIVE}
221+
NEW_ARCHIVE_DIR="nimbus-eth2_macOS_arm64_$(date +%Y%m%d)_$(git rev-parse --short=8 HEAD)"
222+
mv ${ARCHIVE%.tar.gz} ${NEW_ARCHIVE_DIR}
223+
tar -czf ${NEW_ARCHIVE_DIR}.tar.gz ${NEW_ARCHIVE_DIR}
224+
echo "::set-output name=archive::"${NEW_ARCHIVE_DIR}.tar.gz
225+
echo "::set-output name=archive_dir::"${NEW_ARCHIVE_DIR}
226+
227+
- name: Upload archive artefact
228+
uses: actions/upload-artifact@v2
229+
with:
230+
name: macOS_arm64_archive
231+
path: ./dist/${{ steps.make_dist.outputs.archive }}
232+
retention-days: 2
233+
234+
- name: Upload checksum artefact
235+
uses: actions/upload-artifact@v2
236+
with:
237+
name: macOS_arm64_checksum
238+
path: ./dist/${{ steps.make_dist.outputs.archive_dir }}/build/nimbus_beacon_node.sha512sum
239+
retention-days: 2
240+
241+
prepare-prerelease:
242+
name: Prepare pre-release
243+
needs: [build-amd64, build-arm64, build-arm, build-win64, build-macos-amd64, build-macos-arm64]
244+
runs-on: ubuntu-latest
245+
steps:
246+
- name: Checkout code
247+
uses: actions/checkout@v2
248+
with:
249+
ref: unstable
250+
251+
- name: Download artefacts
252+
uses: actions/download-artifact@v2
253+
254+
- name: Create release notes
255+
run: |
256+
cat > release_notes.md <<EOF
257+
## SHA512 checksums
258+
259+
\`\`\`text
260+
EOF
261+
echo '# Linux AMD64' >> release_notes.md
262+
cat Linux_amd64_checksum/* >> release_notes.md
263+
echo '# Linux ARM64' >> release_notes.md
264+
cat Linux_arm64_checksum/* >> release_notes.md
265+
echo '# Linux ARM' >> release_notes.md
266+
cat Linux_arm_checksum/* >> release_notes.md
267+
echo '# Windows AMD64' >> release_notes.md
268+
cat Windows_amd64_checksum/* >> release_notes.md
269+
echo '# macOS AMD64' >> release_notes.md
270+
cat macOS_amd64_checksum/* >> release_notes.md
271+
echo '# macOS ARM64' >> release_notes.md
272+
cat macOS_arm64_checksum/* >> release_notes.md
273+
echo '```' >> release_notes.md
274+
275+
- name: Delete tag
276+
uses: dev-drprasad/[email protected]
277+
with:
278+
delete_release: true
279+
tag_name: nightly
280+
env:
281+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
282+
283+
- name: Create prerelease
284+
run: |
285+
gh release create nightly --prerelease --target unstable \
286+
--title 'Nightly build ("unstable" branch)' --notes-file release_notes.md \
287+
Linux_amd64_archive/* \
288+
Linux_arm64_archive/* \
289+
Linux_arm_archive/* \
290+
Windows_amd64_archive/* \
291+
macOS_amd64_archive/* \
292+
macOS_arm64_archive/*
293+
env:
294+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
295+
296+
- name: Delete artefacts
297+
uses: geekyeggo/delete-artifact@v1
298+
with:
299+
failOnError: false
300+
name: |
301+
Linux_amd64_archive
302+
Linux_amd64_checksum
303+
Linux_arm64_archive
304+
Linux_arm64_checksum
305+
Linux_arm_archive
306+
Linux_arm_checksum
307+
Windows_amd64_archive
308+
Windows_amd64_checksum
309+
macOS_amd64_archive
310+
macOS_amd64_checksum
311+
macOS_arm64_archive
312+
macOS_arm64_checksum
313+

0 commit comments

Comments
 (0)