fabfile.py 文件源码

python
阅读 17 收藏 0 点赞 0 评论 0

项目:combine 作者: llllllllll 项目源码 文件源码
def update():
    rsync_project(
        '/home/%s/combine' % env.user,
        '.',
        exclude=(
            '.git',
            'data',
            'config.yml',
        ),
    )

    with cd('combine'), venv('combine'):
        run('mv config.yml{.prd,}')

        run('pip install -r etc/requirements.txt')
        run('pip install -e .')

        put_systemd_services()

        mkdir('/var/run/gunicorn')
        systemctl_start('combine-uploader')
        systemctl_start('combine-irc')

        mkdir('/var/run/watch-ip')
        systemctl_start('watch-ip.timer')
        systemctl_start('watch-ip.service')

        run('systemctl is-active combine-uploader')
        run('systemctl is-active combine-irc')

    restart_nginx()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号