forked from neuvector/manager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
make_jar.sh
executable file
·70 lines (68 loc) · 1.77 KB
/
make_jar.sh
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
#!/bin/bash
export CHROME_BIN=/usr/bin/google-chrome
rm -rf admin/target
pushd admin/webapp/root/app_src
if [[ $# > 0 ]]; then
case $1 in
-d)
mkdir -p /root/.ivy2
ln -s /prebuild/manager/cache /root/.ivy2/cache
# ln -s /prebuild/manager/bower_components bower_components
# ln -s /prebuild/manager/node_modules node_modules
;;
*)
;;
esac
fi
npm i -g gulp-cli 2>&1
git config --global url."https://".insteadOf git://
npm install 2>&1
if [ $? -eq 0 ]; then
echo npm package installation SUCCEED
else
npm cache clean --force 2>&1
sleep 10
npm i -g gulp-cli 2>&1
npm install 2>&1
if [ $? -eq 0 ]; then
echo npm package installation SUCCEED
else
echo ================================
echo npm package installation FAILED
echo ================================
exit 1
fi
fi
npm install -g bower-npm-resolver
if [ $? -eq 0 ]; then
echo Bower resolver installation SUCCEED
else
echo ================================
echo Bower resolver installation FAILED
echo ================================
exit 1
fi
bower install --allow-root
if [ $? -eq 0 ]; then
echo Bower package installation SUCCEED
else
echo ================================
echo Bower package installation FAILED
echo ================================
exit 1
fi
gulp vendor:app 2>&1
gulp build 2>&1
if [ $? -eq 0 ]; then
echo UI build SUCCEED
else
echo ================================
echo UI build FAILED
echo ================================
exit 1
fi
npm run unittest
popd
env JAVA_OPTS="-Xms2g -Xmx3g" sbt admin/assembly
zip -d admin/target/scala-2.11/admin-assembly-1.0.jar rest-management-private-classpath\*
rm -rf admin/webapp/root/.sass-cache