mirror of https://github.com/openspug/spug
U 改进update命令
parent
c6ca897bec
commit
dd63077c8b
|
@ -37,7 +37,7 @@ class Command(BaseCommand):
|
|||
# update api
|
||||
commands = [
|
||||
f'cd {settings.BASE_DIR}',
|
||||
'git fetch --tags',
|
||||
f'git fetch origin refs/tags/{version}:refs/tags/{version} --no-tags',
|
||||
f'git checkout {version}'
|
||||
]
|
||||
task = subprocess.Popen(' && '.join(commands), shell=True)
|
||||
|
@ -59,5 +59,6 @@ class Command(BaseCommand):
|
|||
call_command('migrate')
|
||||
|
||||
self.stdout.write(self.style.SUCCESS('''升级成功,请自行重启服务,如果通过官方文档安装一般重启命令为
|
||||
Docker: docker restart $CONTAINER_ID
|
||||
Centos: systemctl restart supervisord
|
||||
Ubuntu: systemctl restart supervisor'''))
|
||||
|
|
Loading…
Reference in New Issue