minrigs.py 文件源码

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

项目:vultr_fabric 作者: jmunsch 项目源码 文件源码
def place_main_index_html():
    def template_index(index_html):
        host_string = env.get('host')
        okay = zip(configs.get('index_replace'), configs.get(host_string).get('index_replace_formats'))
        for item, replacer in okay:
            print(item, replacer.format(host_string))
            index_html = index_html.replace(item, replacer.format(host_string))
        index_html = StringIO(unicode(index_html))
        return index_html
    with open('./boiler/index.html') as f:
        index_html = f.read()
    put(template_index(index_html), '/usr/share/nginx/html/index.html')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号