generated from intersystems-community/iris-rest-api-template
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile
29 lines (23 loc) · 1.22 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
FROM intersystems/iris-community:2024.1
WORKDIR /opt/registry
USER root
RUN chown irisowner:irisowner .
USER irisowner
COPY --chown=irisowner:irisowner . .
RUN \
VERSION=$(sed -n 's|.*<Version>\(.*\)</Version>.*|\1|p' module.xml | head -1) && \
sed -i 's|^Parameter VERSION .*$|Parameter VERSION = "'"$VERSION"'";|g' \
./src/cls/ZPM/Registry.cls && \
iris start ${ISC_PACKAGE_INSTANCENAME} && \
/bin/echo -e "" \
" zn \"%SYS\"" \
" do ##class(%SYSTEM.Process).CurrentDirectory(\"$PWD\")" \
" do ##class(%SYSTEM.OBJ).Load(\"Installer.cls\", \"ck\")" \
" set sc = ##class(ZPM.Installer).setup() " \
" if '\$Get(sc) { do ##class(%SYSTEM.Process).Terminate(, 1) }" \
" halt" \
| iris session ${ISC_PACKAGE_INSTANCENAME} -U %SYS && \
tail /usr/irissys/mgr/messages.log && \
iris stop ${ISC_PACKAGE_INSTANCENAME} quietly && \
rm -rf /usr/irissys/mgr/IRIS.WIJ && \
rm -rf /usr/irissys/mgr/journal/*