forked from mj-xmr/SolOptXMR
-
Notifications
You must be signed in to change notification settings - Fork 0
174 lines (167 loc) · 5.55 KB
/
minimal.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
name: minimal
on:
push:
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
# The below variables reduce repetitions across similar targets
env:
APT_SET_CONF: |
echo "Acquire::Retries \"3\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
echo "Acquire::http::Timeout \"120\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
echo "Acquire::ftp::Timeout \"120\";" | sudo tee -a /etc/apt/apt.conf.d/80-custom
jobs:
build-ubuntu:
runs-on: ubuntu-latest
env:
CCACHE_TEMPDIR: /tmp/.ccache-temp
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
# Volatile cache
- name: ccache
uses: actions/cache@v2
with:
path: ~/.ccache
key: ccache01-${{ runner.os }}-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.linkage }}-build-${{ github.sha }}
restore-keys: ccache01-${{ runner.os }}-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.linkage }}-build-
# Less volatile cache
- name: data cache
uses: actions/cache@v2
with:
path: externals/tsqsim/build/data/data/txt
key: data-${{ hashFiles('externals/tsqsim/data/data/txt/**/*') }}
restore-keys: data-${{ hashFiles('externals/tsqsim/data/data/txt/**/*') }}
# Expendable, volatile & large cache
- name: diff cache
uses: actions/cache@v2
with:
path: /tmp/diff_XMR.pkl
key: data-diff-01-${{ github.sha }}
restore-keys: |
data-diff-01-${{ github.sha }}
data-diff-01
# - name: deps cache
# uses: actions/cache@v2
# with:
# path: build/deps/dload
# key: deps-${{ hashFiles('build/deps/dload/*') }}
# restore-keys: deps-${{ hashFiles('build/deps/dload/*') }}
- name: prepare environment
run: util/prep-env.sh
- name: set apt conf
run: ${{env.APT_SET_CONF}}
- name: install dependencies
run: util/deps-pull.sh
- name: build & install the unmanaged dependencies
run: util/deps-build.sh
- name: Configure your rig
run: util/config.sh
- name: build generic
run: ./util/ci.sh 1
- uses: actions/upload-artifact@v3
with:
name: SolOptXMR-ubuntu-latest
path: /home/runner/work/SolOptXMR/SolOptXMR/build/*.png
test-ubuntu-offline:
needs: build-ubuntu
runs-on: ubuntu-latest
env:
CCACHE_TEMPDIR: /tmp/.ccache-temp
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
# Volatile cache
- name: ccache
uses: actions/cache@v2
with:
path: ~/.ccache
key: ccache01-${{ runner.os }}-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.linkage }}-build-${{ github.sha }}
restore-keys: ccache01-${{ runner.os }}-${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.linkage }}-build-
# Less volatile cache
- name: data cache
uses: actions/cache@v2
with:
path: externals/tsqsim/build/data/data/txt
key: data-${{ hashFiles('externals/tsqsim/data/data/txt/**/*') }}
restore-keys: data-${{ hashFiles('externals/tsqsim/data/data/txt/**/*') }}
# Expendable, volatile & large cache
- name: diff cache
uses: actions/cache@v2
with:
path: /tmp/diff_XMR.pkl
key: data-diff-01-${{ github.sha }}
restore-keys: |
data-diff-01-${{ github.sha }}
data-diff-01
# - name: deps cache
# uses: actions/cache@v2
# with:
# path: build/deps/dload
# key: deps-${{ hashFiles('build/deps/dload/*') }}
# restore-keys: deps-${{ hashFiles('build/deps/dload/*') }}
- name: prepare environment
run: util/prep-env.sh
- name: set apt conf
run: ${{env.APT_SET_CONF}}
- name: install dependencies
run: util/deps-pull.sh
- name: build & install the unmanaged dependencies
run: util/deps-build.sh
- name: Configure your rig
run: util/config.sh
- name: build generic
run: ./util/ci.sh 1
- name: Run production
run: python3 ./src/prod.py --offline-force
- uses: actions/upload-artifact@v3
with:
name: SolOptXMR-ubuntu-latest
path: /home/runner/work/SolOptXMR/SolOptXMR/build/*.png
build-macos:
runs-on: macOS-latest
env:
CCACHE_TEMPDIR: /tmp/.ccache-temp
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
# Volatile cache
- name: ccache
uses: actions/cache@v2
with:
path: /Users/runner/Library/Caches/ccache
key: ccache03-${{ runner.os }}-${{ matrix.os }}-build-${{ github.sha }}
restore-keys: ccache03-${{ runner.os }}-${{ matrix.os }}-build-
# Less volatile cache
- name: data cache
uses: actions/cache@v2
with:
path: build/data/data/txt
key: data-${{ hashFiles('build/data/data/txt/**/*') }}
restore-keys: data-${{ hashFiles('build/data/data/txt/**/*') }}
# Expendable, volatile & large cache
- name: diff cache
uses: actions/cache@v2
with:
path: /tmp/diff_XMR.pkl
key: data-diff-01-${{ github.sha }}
restore-keys: |
data-diff-01-${{ github.sha }}
data-diff-01
- name: prepare environment
run: util/prep-env.sh
- name: install dependencies
run: util/deps-pull.sh
- name: build & install the unmanaged dependencies
run: util/deps-build.sh
- name: build generic
run: ./util/ci.sh 1