forked from diashenrique/iris-history-monitor
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathInstaller.cls
48 lines (36 loc) · 1.69 KB
/
Installer.cls
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
42
43
44
45
46
47
48
Include %occInclude
Class App.Installer
{
XData MyInstall [ XMLNamespace = INSTALLER ]
{
<Manifest>
<Default Name="NAMESPACE" Value="IRISMONITOR"/>
<Default Name="DBNAME" Value="IRISMONITOR"/>
<Default Name="APPPATH" Dir="/opt/app/" />
<Default Name="SOURCESPATH" Dir="${APPPATH}src" />
<Default Name="RESOURCE" Value="%DB_${DBNAME}" />
<Default Name="NAMESPACE2" Value="MSGVIEWER"/>
<Default Name="DBNAME2" Value="MSGVIEWER"/>
<Default Name="RESOURCE2" Value="%DB_${DBNAME2}" />
<Namespace Name="${NAMESPACE}" Code="${DBNAME}" Data="${DBNAME}" Create="yes" Ensemble="0">
<Configuration>
<Database Name="${DBNAME}" Dir="${APPPATH}${DBNAME}" Create="yes" Resource="${RESOURCE}"/>
</Configuration>
<CSPApplication Url="/csp/irismonitor" Directory="${APPPATH}Csp/" AuthenticationMethods="32" IsNamespaceDefault="true" Recurse="1" />
<Import File="${SOURCESPATH}" Recurse="1"/>
<LoadPage Dir="/csp/irismonitor" Flags="ck"/>
</Namespace>
<Namespace Name="${NAMESPACE2}" Code="${DBNAME2}" Data="${DBNAME2}" Create="yes" Ensemble="1">
<Configuration>
<Database Name="${DBNAME2}" Dir="${APPPATH}${DBNAME2}" Create="yes" Resource="${RESOURCE2}"/>
</Configuration>
<Import File="${SOURCESPATH}VAR/infra/util/InstallerProduction.cls" Recurse="1"/>
<Invoke Class="VAR.infra.util.InstallerProduction" Method="Install" CheckStatus="1" Return="status"/>
</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")
}
}