forked from jbossdemocentral/bpms-baggage-delivery-demo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
init.bat
119 lines (105 loc) · 4.72 KB
/
init.bat
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
@ECHO OFF
setlocal
set PROJECT_HOME=%~dp0
set DEMO=Baggage Delivery Demo
set AUTHORS=Jason Milliron, Andrew Block, Eric D. Schabell
set [email protected]:jbossdemocentral/bpms-baggage-delivery-demo.git
set PRODUCT=JBoss BPM Suite
set JBOSS_HOME=%PROJECT_HOME%target\jboss-eap-6.1
set SERVER_DIR=%JBOSS_HOME%\standalone\deployments\
set SERVER_CONF=%JBOSS_HOME%\standalone\configuration\
set SERVER_BIN=%JBOSS_HOME%\bin
set SRC_DIR=%PROJECT_HOME%installs
set SUPPORT_DIR=%PROJECT_HOME%support
set PRJ_DIR=%PROJECT_HOME%projects
set BPMS=jboss-bpms-installer-6.0.3.GA-redhat-1.jar
set VERSION=6.0.3
REM wipe screen.
cls
echo.
echo #####################################################################
echo ## ##
echo ## Setting up the %DEMO% ##
echo ## ##
echo ## ##
echo ## #### #### # # ### # # ##### ##### ##### ##
echo ## # # # # # # # # # # # # # # ##
echo ## #### #### # # # ## # # # # ### ##
echo ## # # # # # # # # # # # ##
echo ## #### # # # ### ##### ##### # ##### ##
echo ## ##
echo ## ##
echo ## brought to you by, ##
echo ## %AUTHORS% ##
echo ## ##
echo ## %PROJECT% ##
echo ## ##
echo #####################################################################
echo.
REM make some checks first before proceeding.
if exist %SRC_DIR%\%BPMS% (
echo Product sources are present...
echo.
) else (
echo Need to download %BPMS% package from the Customer Support Portal
echo and place it in the %SRC_DIR% directory to proceed...
echo.
GOTO :EOF
)
REM remove existing install.
if exist %JBOSS_HOME% (
echo - existing JBoss product install removed...
echo.
rmdir /s /q target"
)
REM Run installer.
echo Product installer running now...
echo.
call java -jar %SRC_DIR%/%BPMS% %SUPPORT_DIR%\installation-bpms -variablefile %SUPPORT_DIR%\installation-bpms.variables
if not "%ERRORLEVEL%" == "0" (
echo Error Occurred During %PRODUCT% Installation!
echo.
GOTO :EOF
)
echo - setting up demo projects...
echo.
echo - enabling demo accounts role setup in application-roles.properties file...
echo.
xcopy /Y /Q "%SUPPORT_DIR%\application-roles.properties" "%SERVER_CONF%"
echo.
mkdir "%SERVER_BIN%\.niogit\"
xcopy /Y /Q /S "%SUPPORT_DIR%\bpm-suite-demo-niogit\*" "%SERVER_BIN%\.niogit\"
echo.
echo.
echo - setting up web services...
echo.
call mvn clean install -f %PRJ_DIR%\ZipCodeServices\pom.xml
xcopy /Y /Q "%PRJ_DIR%\ZipCodeServices\target\ZipCodeServices-1.0.war" "%SERVER_DIR%"
echo.
echo - setting up standalone.xml configuration adjustments...
echo.
xcopy /Y /Q "%SUPPORT_DIR%\standalone.xml" "%SERVER_CONF%"
echo.
REM Optional: uncomment this to install mock data for BPM Suite
REM
REM echo - setting up mock bpm dashboard data...
REM echo.
REM xcopy /Y /Q "%SUPPORT_DIR%\1000_jbpm_demo_h2.sql" "%SERVER_DIR%\dashbuilder.war\WEB-INF\etc\sql"
REM echo.
echo.
echo ========================================================================
echo = =
echo = You can now start the %PRODUCT% with: =
echo = =
echo = %SERVER_BIN%\standalone.bat =
echo = =
echo = Login into business central at: =
echo = =
echo = http://localhost:8080/business-central [u:erics / p:bpmsuite1!] =
echo = =
echo = See README.md for general details to run the various demo cases. =
echo = =
echo = %PRODUCT% %VERSION% %DEMO% Setup Complete. =
echo = =
echo ========================================================================
echo.