-
Notifications
You must be signed in to change notification settings - Fork 84
142 lines (134 loc) · 4.44 KB
/
tarballs-monthly.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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
name: Publish tarballs monthly
on:
schedule:
- cron: '0 0 1 * *'
workflow_dispatch:
env:
DEV_SSH_PUBLIC_KEY: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAhL37Q/xX95T3YDGskoZp8LeF/2p3AEPl9kfkLqYms9 GitHub Actions
jobs:
tarball:
runs-on: ubuntu-latest
strategy:
matrix:
recipe:
- base
- buildkit
- cinnamon
- container
- gnome
- kde
- mate
- server
- xfce
buildbot:
- Ry3950X
- kp920
- powernv
- Resonance
include:
- buildbot: Ry3950X
architecture: amd64
- buildbot: Ry3950X
recipe: base+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: base+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: base+nvidia390
architecture: amd64
- buildbot: Ry3950X
recipe: cinnamon+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: cinnamon+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: cinnamon+nvidia390
architecture: amd64
- buildbot: Ry3950X
recipe: gnome+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: gnome+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: gnome+nvidia390
architecture: amd64
- buildbot: Ry3950X
recipe: kde+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: kde+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: kde+nvidia390
architecture: amd64
- buildbot: Ry3950X
recipe: mate+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: mate+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: mate+nvidia390
architecture: amd64
- buildbot: Ry3950X
recipe: xfce+nvidia
architecture: amd64
- buildbot: Ry3950X
recipe: xfce+nvidia340
architecture: amd64
- buildbot: Ry3950X
recipe: xfce+nvidia390
architecture: amd64
- buildbot: kp920
architecture: arm64
- buildbot: powernv
architecture: ppc64el
- buildbot: Resonance
architecture: loongson3
fail-fast: false
max-parallel: 1
steps:
- name: Install buildbot configurations
env:
DEV_SSH_PRIVATE_KEY: ${{secrets.DEV_SSH_PRIVATE_KEY}}
run: |
curl -LSso ~/.ssh/config.d/aosc --create-dirs "https://cdn.jsdelivr.net/gh/AOSC-Dev/Buildbots/ssh_config"
curl -LSso ~/.ssh/known_hosts.d/aosc --create-dirs "https://cdn.jsdelivr.net/gh/AOSC-Dev/Buildbots/ssh_known_hosts"
cat << EOF >> ~/.ssh/config
Host *
Include config.d/*
EOF
echo $DEV_SSH_PRIVATE_KEY | base64 -d > ~/.ssh/id_ed25519
echo $DEV_SSH_PUBLIC_KEY > ~/.ssh/id_ed25519.pub
chmod 644 ~/.ssh/config ~/.ssh/config.d/aosc
chmod 600 ~/.ssh/id_ed25519
- name: Build and download tarball from buildbot
env:
RECIPE: ${{matrix.recipe}}
BUILDBOT: ${{matrix.buildbot}}
ARCH: ${{matrix.architecture}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
run: |
ssh -tt $BUILDBOT "
set -ex \
&& mkdir -p /buildroots/githubactions/$(echo -n $GITHUB_TOKEN | sha256sum | head -c 8) \
&& cd /buildroots/githubactions/$(echo -n $GITHUB_TOKEN | sha256sum | head -c 8) \
&& generate-releases $RECIPE"
sftp $BUILDBOT << EOF
get -R /buildroots/githubactions/$(echo -n $GITHUB_TOKEN | sha256sum | head -c 8)/os-$ARCH
EOF
- name: Upload tarball
uses: actions/upload-artifact@v4
with:
name: os-${{matrix.architecture}}_${{matrix.recipe}}
path: os-${{matrix.architecture}}/${{matrix.recipe}}
if-no-files-found: error
- name: Remove artifact
env:
BUILDBOT: ${{matrix.buildbot}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
if: always()
run: ssh $BUILDBOT "rm -r /buildroots/githubactions/$(echo -n $GITHUB_TOKEN | sha256sum | head -c 8)"