File tree 2 files changed +56
-17
lines changed
2 files changed +56
-17
lines changed Original file line number Diff line number Diff line change @@ -32,24 +32,27 @@ RUN ./build
32
32
#
33
33
# STAGE 2: CLIENT
34
34
#
35
- FROM node:18-bullseye-slim as client
36
-
37
- # install dependencies
38
- RUN set -eux; apt-get update; \
39
- apt-get install -y --no-install-recommends python2 build-essential
40
-
41
- WORKDIR /src
42
-
43
35
#
44
- # install dependencies
45
- COPY client/package*.json ./
46
- RUN npm install
47
-
36
+ # Because client builds fail in Github Actions, therefor we build it outside of Docker.
37
+ #
38
+ # FROM node:18-bullseye-slim as client
39
+ #
40
+ # # install dependencies
41
+ # RUN set -eux; apt-get update; \
42
+ # apt-get install -y --no-install-recommends python2 build-essential
43
+ #
44
+ # WORKDIR /src
45
+ #
46
+ # #
47
+ # # install dependencies
48
+ # COPY client/package*.json ./
49
+ # RUN npm install
50
+ #
51
+ # #
52
+ # # build client
53
+ # COPY client/ .
54
+ # RUN npm run build
48
55
#
49
- # build client
50
- COPY client/ .
51
- RUN npm run build
52
-
53
56
#
54
57
# STAGE 3: RUNTIME
55
58
#
@@ -134,7 +137,8 @@ ENV NEKO_BIND=:8080
134
137
#
135
138
# copy static files from previous stages
136
139
COPY --from=server /src/bin/neko /usr/bin/neko
137
- COPY --from=client /src/dist/ /var/www
140
+ # COPY --from=client /src/dist/ /var/www
141
+ COPY client/dist/ /var/www
138
142
139
143
HEALTHCHECK --interval=10s --timeout=5s --retries=8 \
140
144
CMD wget -O - http://localhost:${NEKO_BIND#*:}/health || exit 1
Original file line number Diff line number Diff line change 13
13
PLATFORMS : linux/arm64,linux/arm/v7
14
14
15
15
jobs :
16
+ build-client :
17
+ runs-on : ubuntu-latest
18
+ #
19
+ # do not run on forks
20
+ #
21
+ if : github.repository_owner == 'm1k1o'
22
+ steps :
23
+ -
24
+ name : Checkout
25
+ uses : actions/checkout@v2
26
+ -
27
+ name : Set up node
28
+ uses : actions/setup-node@v3
29
+ with :
30
+ node-version : 18.x
31
+ -
32
+ name : Build client
33
+ run : |
34
+ cd client
35
+ npm install
36
+ npm run build
37
+ -
38
+ name : Upload client dist
39
+ uses : actions/upload-artifact@v3
40
+ with :
41
+ name : client-dist
42
+ path : client/dist
43
+
16
44
build-base :
17
45
runs-on : ubuntu-latest
18
46
#
19
47
# do not run on forks
20
48
#
21
49
if : github.repository_owner == 'm1k1o'
50
+ needs : [ build-client ]
22
51
steps :
23
52
-
24
53
name : Checkout
25
54
uses : actions/checkout@v2
55
+ -
56
+ name : Download client dist
57
+ uses : actions/download-artifact@v3
58
+ with :
59
+ name : client-dist
60
+ path : client/dist
26
61
-
27
62
name : Set up QEMU
28
63
uses : docker/setup-qemu-action@v1
You can’t perform that action at this time.
0 commit comments