-
Notifications
You must be signed in to change notification settings - Fork 123
69 lines (58 loc) · 1.98 KB
/
windows-containerd-nightly.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: windows-containerd-nightly
on:
push:
branches: [ master ]
schedule:
- cron: '45 0 * * *' # Every day at 00:45 UTC
workflow_dispatch:
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Install Go
uses: actions/setup-go@v2
with:
go-version: 1.21.3
- name: Create drop folder
run: mkdir -p $GITHUB_WORKSPACE/output/bin
- name: Build hcsshim
env:
GOOS: windows
GOARCH: amd64
run: |
git clone https://github.com/Microsoft/hcsshim
cd hcsshim
go build -o $GITHUB_WORKSPACE/output/bin/containerd-shim-runhcs-v1.exe ./cmd/containerd-shim-runhcs-v1
git rev-parse HEAD | tee $GITHUB_WORKSPACE/output/bin/hcsshim-revision.txt
- name: Build containerd
env:
GOOS: windows
GOARCH: amd64
VERSION: v2.0.0+unknown
run: |
git clone https://github.com/containerd/containerd.git
cd containerd
make binaries
cp ./bin/containerd.exe $GITHUB_WORKSPACE/output/bin
cp ./bin/ctr.exe $GITHUB_WORKSPACE/output/bin
git rev-parse HEAD | tee $GITHUB_WORKSPACE/output/bin/containerd-revision.txt
- name: make windows-containerd zip
run: |
cd $GITHUB_WORKSPACE/output
tar cvf windows-containerd.tar.gz bin
# sometimes eine/tip@master fails to upload release artifacts and this leaves
# a stale tmp file on the release which causes future runs of this workflow to fail.
- name: delete tmp.* release artifacts
uses: mknejp/delete-release-assets@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: windows-containerd-nightly
fail-if-no-assets: false # do not fail if temp.windows-contaienrd.tar.gz does not exist
assets: tmp.windows-containerd.tar.gz
- uses: eine/tip@master
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: windows-containerd-nightly
files: |
./output/windows-containerd.tar.gz