-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile.iris
39 lines (26 loc) · 1002 Bytes
/
Dockerfile.iris
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
FROM node:8-alpine AS web
WORKDIR /opt/blocks/
COPY web ./
RUN npm install \
&& export PATH="$PATH:./node_modules/.bin" \
&& webpack --mode production
FROM intersystemsdc/iris-community
WORKDIR /opt/blocks
USER root
RUN chown ${ISC_PACKAGE_MGRUSER}:${ISC_PACKAGE_IRISGROUP} ${PWD} && \
apt-get -y update && \
DEBIAN_FRONTEND=noninteractive apt-get -y install imagemagick --no-install-recommends && \
rm -rf /var/lib/apt/lists/*
USER irisowner
COPY ./server/src/ ./src
COPY --from=web /opt/blocks/build/ /usr/irissys/csp/blocks/
RUN iris start $ISC_PACKAGE_INSTANCENAME quietly \
&& /bin/echo -e "do ##class(%SYSTEM.OBJ).Load(\"/opt/blocks/src/DevInstaller.cls\",\"cdk\")\n" \
"set sc=##class(Blocks.DevInstaller).setupWithVars(\"/opt/blocks/\")\n" \
"do:'sc \$zu(4,\$j,1)\n" \
"Halt\n" \
| iris session ${ISC_PACKAGE_INSTANCENAME} \
&& iris stop $ISC_PACKAGE_INSTANCENAME quietly
VOLUME [ "/opt/blocks/db" ]
COPY entrypoint.sh /
ENTRYPOINT [ "/entrypoint.sh" ]