1
0
mirror of https://github.com/haiwen/seafile-server.git synced 2025-09-07 02:10:05 +00:00

Modify default user host to 127.0.0.1.

Add PYTHONPATH in setup mysql script.
This commit is contained in:
ly1217
2019-11-27 02:24:59 -08:00
parent f07e22dd2c
commit 9bb27886fe
2 changed files with 4 additions and 2 deletions

View File

@@ -381,7 +381,7 @@ class AbstractDBConfigurator(AbstractConfigurator):
self.seafile_mysql_user = '' self.seafile_mysql_user = ''
self.seafile_mysql_password = '' self.seafile_mysql_password = ''
self.seafile_mysql_userhost = 'localhost' self.seafile_mysql_userhost = '127.0.0.1'
self.root_password = '' self.root_password = ''
self.root_conn = '' self.root_conn = ''
@@ -1445,7 +1445,7 @@ def check_params(args):
if db_config.mysql_host != '127.0.0.1' and not mysql_user_host: if db_config.mysql_host != '127.0.0.1' and not mysql_user_host:
raise InvalidParams('mysql user host parameter is missing in creating new db mode') raise InvalidParams('mysql user host parameter is missing in creating new db mode')
if not mysql_user_host: if not mysql_user_host:
db_config.seafile_mysql_userhost = 'localhost' db_config.seafile_mysql_userhost = '127.0.0.1'
else: else:
db_config.seafile_mysql_userhost = db_config.validate_mysql_user_host(mysql_user_host) db_config.seafile_mysql_userhost = db_config.validate_mysql_user_host(mysql_user_host)

View File

@@ -53,4 +53,6 @@ check_python;
export PYTHON=$PYTHON export PYTHON=$PYTHON
export PYTHONPATH=${INSTALLPATH}/seafile/lib/python3.6/site-packages:${INSTALLPATH}/seafile/lib64/python3.6/site-packages:${INSTALLPATH}/seahub/thirdpart:$PYTHONPATH
exec $PYTHON "$python_script" "$@" exec $PYTHON "$python_script" "$@"