-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-entrypoint.sh
executable file
·41 lines (35 loc) · 1.01 KB
/
docker-entrypoint.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
#!/bin/bash
set -eo pipefail
shopt -s nullglob
wantHelp=
for arg; do
case "$arg" in
-'?'|--help|--print-defaults|-V|--version)
wantHelp=1
break
;;
esac
done
if [[ ${ZEP_ADM_PASS} != "" ]]
then
echo " setting zeppelin admin password"
sed -i -e "s/password1/${ZEP_ADM_PASS}/g" /home/zeppelin/latest/conf/shiro.ini
sed -i -e "s/#admin/admin/g" /home/zeppelin/latest/conf/shiro.ini
fi
if [[ ${ZEP_USER1_PASS} != "" ]]
then
echo " setting zeppelin USER1 password"
sed -i -e "s/password2/${ZEP_USER1_PASS}/g" /home/zeppelin/latest/conf/shiro.ini
fi
if [[ ${ZEP_USER2_PASS} != "" ]]
then
echo " setting zeppelin USER2 password"
sed -i -e "s/password3/${ZEP_USER2_PASS}/g" /home/zeppelin/latest/conf/shiro.ini
fi
if [[ ${ZEP_USER3_PASS} != "" ]]
then
echo " setting zeppelin USER3 password"
sed -i -e "s/password4/${ZEP_USER3_PASS}/g" /home/zeppelin/latest/conf/shiro.ini
fi
sed 's/127.0.0.1/0.0.0.0/g' /home/zeppelin/latest/conf/zeppelin-site.xml.template > /home/zeppelin/latest/conf/zeppelin-site.xml
$@