-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
41 lines (31 loc) · 1.24 KB
/
Dockerfile
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
FROM alpine:latest as stage
WORKDIR /opt/stage
RUN \
apk update \
&& apk add wget \
&& wget https://raw.githubusercontent.com/rfns/dotenv/master/cls/DotEnv/Parser.cls --quiet --output-document /opt/stage/dotenv-parser.cls \
&& wget https://raw.githubusercontent.com/rfns/dotenv/master/cls/DotEnv/Command.cls --quiet --output-document /opt/stage/dotenv-command.cls
COPY scripts/setup-iris.sh scripts/entrypoint.sh /opt/stage/scripts/
COPY ci ./
FROM docker.io/intersystemsdc/iris-community:latest
WORKDIR /opt/ci
COPY --from=stage /opt/stage /opt/ci
USER root
RUN mkdir -p /var/log/ci \
&& chmod -R +x /opt/ci/scripts \
&& chown -R irisowner:irisowner /var/log/ci /opt/ci
USER irisowner
SHELL ["/opt/ci/scripts/setup-iris.sh"]
RUN \
set f = ##class(%Stream.FileCharacter).%New() \
do f.LinkToFile("/opt/ci/ci.inc") \
set r = ##class(%RoutineMgr).%New("ci.inc") \
do r.Code.CopyFrom(f) \
do r.%Save() \
set (f, r) = "" \
do $System.OBJ.Load("/opt/ci/Configuration.cls", "c") \
do $System.OBJ.Load("/opt/ci/Orchestrator.cls", "c") \
do $System.OBJ.Load("/opt/ci/dotenv-parser.cls", "c") \
do $System.OBJ.Load("/opt/ci/dotenv-command.cls", "c")
CMD ["-l", "/usr/irissys/mgr/messages.log"]
ENTRYPOINT ["/opt/ci/scripts/entrypoint.sh"]