-
-
Notifications
You must be signed in to change notification settings - Fork 17
235 lines (218 loc) · 7.89 KB
/
on.scheduled.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
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
#
# Copyright (c) 2024 Elide Technologies, Inc.
#
# Licensed under the MIT license (the "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# https://opensource.org/license/mit/
#
# Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
# an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations under the License.
#
name: Checks
"on":
workflow_dispatch: {}
schedule:
- cron: "0 0-23/2 * * *"
env:
BUILDLESS_APIKEY: ${{ secrets.BUILDLESS_APIKEY }}
permissions:
contents: read
jobs:
##
## Job: Check Repo Pull-ability
##
check-repos:
name: "Repositories: Clone Test"
runs-on: "ubuntu-latest"
continue-on-error: true
permissions:
contents: "read"
id-token: "write"
checks: "write"
pull-requests: "write"
steps:
- name: "Setup: Harden Runner"
uses: step-security/harden-runner@0d381219ddf674d61a7572ddd19d7941e271515c # v2.9.0
with:
egress-policy: audit
- name: "Setup: Test Area"
run: mkdir -p repos
- name: "Clone: Elide"
run: git clone https://github.com/elide-dev/v3.git ./repos/elide
- name: "Clone: Runtime"
continue-on-error: true
run: git clone https://github.com/elide-dev/runtime.git ./repos/runtime
- name: "Clone: Build Tools"
run: git clone https://github.com/elide-dev/buildtools.git ./repos/buildtools
##
## Job: Check Image Pull-ability
##
check-images:
name: "Images: Pull Test"
runs-on: "ubuntu-latest"
permissions:
contents: "read"
id-token: "write"
checks: "write"
pull-requests: "write"
steps:
- name: "Setup: Harden Runner"
uses: step-security/harden-runner@0d381219ddf674d61a7572ddd19d7941e271515c # v2.9.0
with:
egress-policy: audit
- name: "Setup: Docker"
uses: docker/setup-buildx-action@aa33708b10e362ff993539393ff100fa93ed6a27 # v3.5.0
id: buildx
with:
install: true
## Image: CLI
- name: "Pull: CLI (DockerHub)"
run: docker pull elidetools/elide:latest
- name: "Pull: CLI (GitHub)"
run: docker pull ghcr.io/elide-dev/elide:latest
## Image: Base
- name: "Pull: Base (DockerHub)"
run: docker pull elidetools/base:latest
- name: "Pull: Base (GitHub)"
run: docker pull ghcr.io/elide-dev/base:latest
## Image: Base (Alpine)
- name: "Pull: Base - Alpine (DockerHub)"
run: docker pull elidetools/base-alpine:latest
- name: "Pull: Base - Alpine (GitHub)"
run: docker pull ghcr.io/elide-dev/base/alpine:latest
## Image: Runtime (JVM11)
- name: "Pull: Runtime - JVM11 (DockerHub)"
run: docker pull elidetools/jvm11:latest
- name: "Pull: Runtime - JVM11 (GitHub)"
run: docker pull ghcr.io/elide-dev/runtime/jvm11:latest
## Image: Runtime (JVM17)
- name: "Pull: Runtime - JVM17 (DockerHub)"
run: docker pull elidetools/jvm17:latest
- name: "Pull: Runtime - JVM17 (GitHub)"
run: docker pull ghcr.io/elide-dev/runtime/jvm17:latest
## Image: Runtime (JVM19)
- name: "Pull: Runtime - JVM19 (DockerHub)"
run: docker pull elidetools/jvm19:latest
- name: "Pull: Runtime - JVM19 (GitHub)"
run: docker pull ghcr.io/elide-dev/runtime/jvm19:latest
## Image: Runtime (Native)
- name: "Pull: Runtime - Native (DockerHub)"
run: docker pull elidetools/native:latest
- name: "Pull: Runtime - Native (GitHub)"
run: docker pull ghcr.io/elide-dev/runtime/native:latest
## Image: Runtime (Native Alpine)
- name: "Pull: Runtime - Native Alpine (DockerHub)"
run: docker pull elidetools/native-alpine:latest
- name: "Pull: Runtime - Native Alpine (GitHub)"
run: docker pull ghcr.io/elide-dev/runtime/native/alpine:latest
##
## Job: Check Cached Build
##
check-build:
name: "Quick-build"
runs-on: "ubuntu-latest"
permissions:
contents: "read"
id-token: "write"
checks: "write"
pull-requests: "write"
defaults:
run:
shell: bash
steps:
- name: "Setup: Harden Runner"
uses: step-security/harden-runner@0d381219ddf674d61a7572ddd19d7941e271515c # v2.9.0
with:
egress-policy: audit
- name: "Setup: Checkout"
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: "Setup: Rust"
uses: actions-rust-lang/setup-rust-toolchain@1fbea72663f6d4c03efaab13560c8a24cfd2a7cc # v1.9.0
with:
toolchain: nightly
components: clippy,rustfmt
rustflags: ""
- name: "Setup: SCCache"
uses: mozilla-actions/sccache-action@89e9040de88b577a072e3760aaf59f585da083af # v0.0.5
- name: "Setup: Rust Caching"
run: |
echo "SCCACHE_GHA_ENABLED=true" >> $GITHUB_ENV
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
- name: "Setup: GraalVM (Java 22)"
uses: graalvm/setup-graalvm@2911b2304bee2c2f59b9a67bf45f025a6b6de4b1 # v1.2.2
with:
distribution: "graalvm"
java-version: "22"
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: "Setup: Python (3.12)"
uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f # v5.1.1
with:
python-version: 3.12
- name: "Setup: Buildless"
if: false # temporarily disabled
uses: buildless/setup@30e82389418c7f17046606183bc4c78b2c8913e0 # v1.0.2
- name: "Setup: Node"
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
with:
node-version: 22
- name: "Setup: PNPM"
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
with:
version: "9.2.0"
run_install: |
- recursive: true
args: [--frozen-lockfile, --strict-peer-dependencies]
- name: "Setup: LLVM 18"
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 18 all
export LLVM_PATH=/usr/lib/llvm-18
export PATH="$LLVM_PATH/bin:$PATH"
export LD_LIBRARY_PATH="$LLVM_PATH/lib:$LD_LIBRARY_PATH"
export LLVM_CONFIG="$LLVM_PATH/bin/llvm-config"
echo LLVM_PATH=$LLVM_PATH >> $GITHUB_ENV
echo LD_LIBRARY_PATH=$LD_LIBRARY_PATH >> $GITHUB_ENV
echo LLVM_CONFIG=$LLVM_CONFIG >> $GITHUB_ENV
echo PATH=$PATH >> $GITHUB_ENV
- name: "Setup: Dependencies"
run: |
cargo install cargo-fuzz cargo-insta rustfilt
pnpm install -g [email protected]
python -m pip install uv
echo "Setting up venv..."
uv venv
echo "Installing dependencies via Pip..."
uv pip install -r requirements.txt
echo "Activating venv..."
. .venv/bin/activate
echo PATH=$PATH >> $GITHUB_ENV
- name: "Setup: Gradle"
uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 # v3.5.0
id: gradlebuild
continue-on-error: ${{ matrix.mode == 'labs' }}
env:
CI: true
with:
cache-read-only: true
- name: "🛠️ Build"
run: |
make setup natives && ./gradlew \
build \
-x check \
-x test \
-x jvmTest \
-x jsTest \
-x jsBrowserTest \
-x nativeCompile \
--scan \
--no-daemon \
--warning-mode=none \
--dependency-verification=lenient \
-Pelide.ci=true \
-PbuildSamples=false \
-PbuildDocs=false \
-Pversions.java.minimum=11 \
-Pversions.java.language=22