mirror of
https://github.com/ggogel/seafile-containerized.git
synced 2024-11-16 09:01:38 +00:00
Added more logging
This commit is contained in:
parent
a1d1369680
commit
4ebe259534
|
@ -15,7 +15,7 @@ import time
|
|||
|
||||
from utils import (
|
||||
call, get_conf, get_install_dir, get_script, get_command_output,
|
||||
render_template, wait_for_mysql
|
||||
render_template, wait_for_mysql, setup_logging
|
||||
)
|
||||
from upgrade import check_upgrade
|
||||
from bootstrap import init_seafile_server, is_https, init_letsencrypt, generate_local_nginx_conf
|
||||
|
@ -82,4 +82,5 @@ def main():
|
|||
sys.exit(0)
|
||||
|
||||
if __name__ == '__main__':
|
||||
setup_logging()
|
||||
main()
|
||||
|
|
|
@ -8,6 +8,7 @@ This script is used to run proper upgrade scripts automatically.
|
|||
import json
|
||||
import re
|
||||
import glob
|
||||
import logging
|
||||
import os
|
||||
from os.path import abspath, basename, exists, dirname, join, isdir
|
||||
import shutil
|
||||
|
@ -21,6 +22,7 @@ from utils import (
|
|||
|
||||
installdir = get_install_dir()
|
||||
topdir = dirname(installdir)
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
def collect_upgrade_scripts(from_version, to_version):
|
||||
"""
|
||||
|
@ -53,6 +55,7 @@ def parse_upgrade_script_version(script):
|
|||
return m.groups()
|
||||
|
||||
def run_script_and_update_version_stamp(script, new_version):
|
||||
logging.info('Running script %s', script)
|
||||
replace_file_pattern(script, 'read dummy', '')
|
||||
call(script)
|
||||
update_version_stamp(new_version)
|
||||
|
|
Loading…
Reference in a new issue