Browse Source
Merge pull request #878 from janbols/master
Fix install_dev_db.sh by using sudo instead of su
pull/881/head
Igor Kulikov
8 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
2 additions and
2 deletions
-
application/src/main/scripts/install/install_dev_db.sh
|
|
|
@ -30,13 +30,13 @@ export SQL_DATA_FOLDER=${SQL_DATA_FOLDER:-/tmp} |
|
|
|
|
|
|
|
run_user=thingsboard |
|
|
|
|
|
|
|
su -s /bin/sh -c "java -cp ${jarfile} $JAVA_OPTS -Dloader.main=org.thingsboard.server.ThingsboardInstallApplication \ |
|
|
|
sudo -u "$run_user" -s /bin/sh -c "java -cp ${jarfile} $JAVA_OPTS -Dloader.main=org.thingsboard.server.ThingsboardInstallApplication \ |
|
|
|
-Dinstall.data_dir=${installDir} \ |
|
|
|
-Dinstall.load_demo=${loadDemo} \ |
|
|
|
-Dspring.jpa.hibernate.ddl-auto=none \ |
|
|
|
-Dinstall.upgrade=false \ |
|
|
|
-Dlogging.config=logback.xml \ |
|
|
|
org.springframework.boot.loader.PropertiesLauncher" "$run_user" |
|
|
|
org.springframework.boot.loader.PropertiesLauncher" |
|
|
|
|
|
|
|
if [ $? -ne 0 ]; then |
|
|
|
echo "ThingsBoard DB installation failed!" |
|
|
|
|