yaml_api.py 文件源码

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

项目:kuberdock-platform 作者: cloudlinux 项目源码 文件源码
def fill_template(template_id, plan_id, **params):
    app = PredefinedApp.get(template_id)
    filled = app.get_filled_template_for_plan(plan_id, params, as_yaml=True)
    return Response(filled, content_type='application/x-yaml')


# TODO Apps API instead of "/create/", "/switch/", and "/update/":
#     GET /apps/<app-id>/ - return list of pods (with only one pod, for now),
#       template id, plan id, version id, app variables, is update available,
#       is switching allowed, postDescriotion,..
#     POST /apps/ - {templateID, planID, [appVariables,] [start,] [owner,]} ->
#       instead of "/create/"
#     PUT /apps/<app-id>/ - {versionID or planID} for update or switching plan
#     DELETE /apps/<app-id>/ - delete all pods (only one pod, for now)
# for now, app_id may be equal to pod_id.
# apps = Blueprint('apps_api', __name__, url_prefix='/apps')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号