-
Notifications
You must be signed in to change notification settings - Fork 3
236 lines (218 loc) · 6.33 KB
/
build.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
236
name: Java+Docker CI
on:
pull_request:
push:
release:
jobs:
#
# Build jobs
#
install-alma-lib:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
# Install alma-lib
- name: build, test, and install alma-lib
run: pwd && whoami && gradle --info -b alma-lib/build.gradle clean build test publishToMavenLocal
# Upload alma-lib artifact
- uses: actions/upload-artifact@v2
with:
name: alma-lib
path: /home/runner/.m2/repository/org/opencadc/alma-lib
# BUILD UNPUBLISHED LIBRARIES. REMOVE WHEN PUBLISHED! #
install-cadc-conesearch:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 11
# Install cadc-conesearch
- name: build, test, and install cadc-conesearch
run: cd ../ && git clone -b conesearch https://github.com/at88mph/dal.git && cd dal && ./gradlew --info -b cadc-dali/build.gradle clean build install && ./gradlew --info -b cadc-conesearch/build.gradle clean build install
# Upload cadc-conesearch artifact
- uses: actions/upload-artifact@v2
with:
name: cadc-dali
path: /home/runner/.m2/repository/org/opencadc/cadc-dali
- uses: actions/upload-artifact@v2
with:
name: cadc-conesearch
path: /home/runner/.m2/repository/org/opencadc/cadc-conesearch
# END BUILD UNPUBLISHED LIBRARIES. REMOVE WHEN PUBLISHED! #
# Temporarily depends on unpublished cadc-dali and cadc-conesearch libraries.
build-cone:
needs:
- install-alma-lib
- install-cadc-conesearch
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
- uses: actions/download-artifact@v2
with:
name: alma-lib
path: /home/runner/.m2/repository/org/opencadc/alma-lib
- uses: actions/download-artifact@v2
with:
name: cadc-dali
path: /home/runner/.m2/repository/org/opencadc/cadc-dali
- uses: actions/download-artifact@v2
with:
name: cadc-conesearch
path: /home/runner/.m2/repository/org/opencadc/cadc-conesearch
- name: build and test cone
run: gradle --info -b cone/build.gradle clean build test
# Upload WAR artifact
- uses: actions/upload-artifact@v2
with:
name: cone-artifact
path: ./cone/build/libs/cone.war
build-datalink:
needs: install-alma-lib
uses: ./.github/workflows/gradle.yml
with:
name: datalink
artifact-name: datalink
build-sia:
needs: install-alma-lib
uses: ./.github/workflows/gradle.yml
with:
name: sia
artifact-name: sia2
# Temporarily depends on unpublished cadc-tap-server-oracle library.
build-tap:
needs:
- install-alma-lib
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
- uses: actions/download-artifact@v2
with:
name: alma-lib
path: /home/runner/.m2/repository/org/opencadc/alma-lib
- name: build and test tap
run: gradle --info -b tap/build.gradle clean build test
# Upload WAR artifact
- uses: actions/upload-artifact@v2
with:
name: tap-artifact
path: ./tap/build/libs/tap.war
build-soda:
needs: install-alma-lib
uses: ./.github/workflows/gradle.yml
with:
name: soda
artifact-name: soda
build-reg:
needs: install-alma-lib
uses: ./.github/workflows/gradle.yml
with:
name: reg
artifact-name: reg
build-data:
needs: install-alma-lib
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
# This will install WCSLib 5.15 to include WCS cutouts. This is a very old version, but it's what is deployed on
# the NGAS nodes.
- name: install WCSLIB (libwcs5-15)
run: |
sudo apt-get update && sudo apt-get install -y curl gcc make \
&& curl -Lv -o /tmp/wcslib.tar.bz2 https://launchpad.net/ubuntu/+archive/primary/+sourcefiles/wcslib/5.15-1/wcslib_5.15.orig.tar.bz2 \
&& cd /tmp/ \
&& tar jxvf wcslib.tar.bz2 \
&& cd wcslib-5.15 \
&& ./configure --prefix=/usr \
&& make && sudo make install
- uses: actions/download-artifact@v2
with:
name: alma-lib
path: /home/runner/.m2/repository/org/opencadc/alma-lib
- name: build and test data
run: gradle --info -b data/build.gradle clean build test
# Upload WAR artifact
- uses: actions/upload-artifact@v2
with:
name: data-artifact
path: data/build/libs/data.war
#
# End Build jobs
#
#
# Package jobs
#
package-cone:
needs: build-cone
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: cone
artifact-name: cone
package-datalink:
needs: build-datalink
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: datalink
artifact-name: datalink
package-sia:
needs: build-sia
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: sia
artifact-name: sia2
package-tap:
needs: build-tap
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: tap
artifact-name: tap
package-soda:
needs: build-soda
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: soda
artifact-name: soda
package-reg:
needs: build-reg
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: reg
artifact-name: reg
package-data:
needs: build-data
uses: ./.github/workflows/docker.yml
secrets: inherit
with:
name: data
artifact-name: data
#
# End Package Jobs
#