forked from objectscript/cache-udl
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
changes for the development with docker container
- Loading branch information
Evgeny Shvarov
authored and
Evgeny Shvarov
committed
Feb 9, 2019
1 parent
b6a169c
commit 9f80ee6
Showing
3 changed files
with
58 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
FROM intersystems/iris:2019.1.0S.111.0 | ||
|
||
WORKDIR /opt/app | ||
|
||
COPY ./Installer.cls ./ | ||
COPY ./cls/ ./src/ | ||
|
||
RUN iris start $ISC_PACKAGE_INSTANCENAME quietly EmergencyId=sys,sys && \ | ||
/bin/echo -e "sys\nsys\n" \ | ||
" Do ##class(Security.Users).UnExpireUserPasswords(\"*\")\n" \ | ||
" Do ##class(Security.Users).AddRoles(\"admin\", \"%ALL\")\n" \ | ||
" Do \$system.OBJ.Load(\"/opt/app/Installer.cls\",\"ck\")\n" \ | ||
" Set sc = ##class(App.Installer).setup(, 3)\n" \ | ||
" If 'sc do \$zu(4, \$JOB, 1)\n" \ | ||
" halt" \ | ||
| iris session $ISC_PACKAGE_INSTANCENAME && \ | ||
/bin/echo -e "sys\nsys\n" \ | ||
| iris stop $ISC_PACKAGE_INSTANCENAME quietly | ||
|
||
CMD [ "-l", "/usr/irissys/mgr/messages.log" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
Class App.Installer | ||
{ | ||
|
||
XData MyInstall [ XMLNamespace = INSTALLER ] | ||
{ | ||
<Manifest> | ||
<Default Name="NAMESPACE" Value="TEST"/> | ||
<Default Name="DBNAME" Value="TEST"/> | ||
<Default Name="APPPATH" Dir="/opt/app/" /> | ||
<Default Name="SOURCESPATH" Dir="${APPPATH}src" /> | ||
<Default Name="RESOURCE" Value="%DB_${DBNAME}" /> | ||
|
||
<Namespace Name="${NAMESPACE}" Code="${DBNAME}-CODE" Data="${DBNAME}-DATA" Create="yes" Ensemble="0"> | ||
<Configuration> | ||
<Database Name="${DBNAME}-CODE" Dir="${APPPATH}${DBNAME}-CODE" Create="yes" Resource="${RESOURCE}"/> | ||
<Database Name="${DBNAME}-DATA" Dir="${APPPATH}${DBNAME}-DATA" Create="yes" Resource="${RESOURCE}"/> | ||
</Configuration> | ||
|
||
<Import File="${SOURCESPATH}" Recurse="1"/> | ||
</Namespace> | ||
|
||
</Manifest> | ||
} | ||
|
||
ClassMethod setup(ByRef pVars, pLogLevel As %Integer = 3, pInstaller As %Installer.Installer, pLogger As %Installer.AbstractLogger) As %Status [ CodeMode = objectgenerator, Internal ] | ||
{ | ||
Quit ##class(%Installer.Manifest).%Generate(%compiledclass, %code, "MyInstall") | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
version: '2.4' | ||
services: | ||
iris: | ||
build: . | ||
restart: always | ||
ports: | ||
- 52773:52773 | ||
volumes: | ||
- ~/iris.key:/usr/irissys/mgr/iris.key |