Skip to content

Commit b214bda

Browse files
committed
MWE custom vs default runner
1 parent 3e0166d commit b214bda

File tree

4 files changed

+203
-0
lines changed

4 files changed

+203
-0
lines changed
Lines changed: 185 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,185 @@
1+
# This workflow showcases feature differences between
2+
# GitHub's default runner (actions/runner)
3+
# and
4+
# Antmicro's custom runner (antmicro/runner).
5+
6+
name: MWE custom vs default runner
7+
8+
on:
9+
push:
10+
pull_request:
11+
12+
jobs:
13+
14+
15+
# Supported on both actions/runner and antmicro/runner
16+
17+
# Non-local Composite Actions
18+
19+
Composite-Custom:
20+
container: ubuntu:bionic
21+
runs-on:
22+
- self-hosted
23+
- Linux
24+
- X64
25+
26+
env:
27+
MAX_CORES: 80
28+
GHA_EXTERNAL_DISK: "tools"
29+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
30+
31+
steps:
32+
33+
- uses: antmicro/f4pga-arch-defs/composite@umarcor/runner/mwes
34+
35+
Composite-Default:
36+
runs-on: ubuntu-latest
37+
38+
steps:
39+
40+
- uses: antmicro/f4pga-arch-defs/composite@umarcor/runner/mwes
41+
42+
43+
# Supported on actions/runner but not on antmicro/runner
44+
45+
# Local Composite Actions
46+
47+
CompositeLocal-Custom:
48+
container: ubuntu:bionic
49+
runs-on:
50+
- self-hosted
51+
- Linux
52+
- X64
53+
54+
env:
55+
MAX_CORES: 80
56+
GHA_EXTERNAL_DISK: "tools"
57+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
58+
59+
steps:
60+
61+
- uses: actions/checkout@v3
62+
- uses: ./composite
63+
64+
CompositeLocal-Default:
65+
runs-on: ubuntu-latest
66+
67+
steps:
68+
69+
- uses: actions/checkout@v3
70+
- uses: ./composite
71+
72+
# Actions inside Composite Actions
73+
74+
CompositeUses-Custom:
75+
container: ubuntu:bionic
76+
runs-on:
77+
- self-hosted
78+
- Linux
79+
- X64
80+
81+
env:
82+
MAX_CORES: 80
83+
GHA_EXTERNAL_DISK: "tools"
84+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
85+
86+
steps:
87+
88+
- uses: antmicro/f4pga-arch-defs/composite-uses@umarcor/runner/mwes
89+
90+
CompositeUses-Default:
91+
runs-on: ubuntu-latest
92+
93+
steps:
94+
95+
- uses: antmicro/f4pga-arch-defs/composite-uses@umarcor/runner/mwes
96+
97+
# Action actions/setup-python
98+
99+
SetupPython-Custom:
100+
container: ubuntu:bionic
101+
runs-on:
102+
- self-hosted
103+
- Linux
104+
- X64
105+
106+
env:
107+
MAX_CORES: 80
108+
GHA_EXTERNAL_DISK: "tools"
109+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
110+
111+
steps:
112+
113+
- name: '🐍 Setup Python'
114+
uses: actions/setup-python@v2
115+
with:
116+
python-version: '3.10'
117+
118+
SetupPython-Default:
119+
runs-on: ubuntu-latest
120+
121+
steps:
122+
123+
- name: '🐍 Setup Python'
124+
uses: actions/setup-python@v2
125+
with:
126+
python-version: '3.10'
127+
128+
# Docker steps
129+
130+
DockerStep-Custom:
131+
container: ubuntu:bionic
132+
runs-on:
133+
- self-hosted
134+
- Linux
135+
- X64
136+
137+
env:
138+
MAX_CORES: 80
139+
GHA_EXTERNAL_DISK: "tools"
140+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
141+
142+
steps:
143+
144+
- uses: docker://debian:bullseye-slim
145+
with:
146+
args: echo 'Hello world!'
147+
148+
DockerStep-Default:
149+
runs-on: ubuntu-latest
150+
151+
steps:
152+
153+
- uses: docker://debian:bullseye-slim
154+
with:
155+
args: echo 'Hello world!'
156+
157+
# Execute `docker` commands
158+
159+
DockerManual-Custom:
160+
container: ubuntu:bionic
161+
runs-on:
162+
- self-hosted
163+
- Linux
164+
- X64
165+
166+
env:
167+
MAX_CORES: 80
168+
GHA_EXTERNAL_DISK: "tools"
169+
GHA_SA: "gh-sa-f4pga-arch-defs-ci"
170+
171+
steps:
172+
173+
- run: docker pull debian:bullseye-slim
174+
175+
DockerManual-Default:
176+
runs-on: ubuntu-latest
177+
178+
steps:
179+
180+
- run: docker pull debian:bullseye-slim
181+
182+
183+
184+
185+

composite-uses/action.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
name: 'Action inside Composite Action'
2+
description: 'For testing purposes'
3+
runs:
4+
using: 'composite'
5+
steps:
6+
7+
- uses: actions/checkout@v3

composite/action.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
name: 'Composite Action'
2+
description: 'For testing purposes'
3+
runs:
4+
using: 'composite'
5+
steps:
6+
7+
- shell: bash
8+
run: '''${{ github.action_path }}/script.sh'''

composite/script.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/usr/bin/env bash
2+
3+
echo "Hello world!"

0 commit comments

Comments
 (0)