【问题标题】:How can we deploy newer versions of code on the fly for Google Cloud Functions code?我们如何为 Google Cloud Functions 代码动态部署更新版本的代码?
【发布时间】:2019-01-31 06:59:12
【问题描述】:

有没有什么方法可以将其他 GCP 平台服务与云功能集成,从而满足我们的需求?

【问题讨论】:

  • 这些需求是什么?通过“动态部署更新版本的代码”,您指的是持续集成吗?如果是这种情况,您应该考虑使用 Cloud Build 而不是 Cloud Functions
  • 我想知道它的云函数代码。我已经编辑了我的问题。

标签: google-cloud-platform google-cloud-functions


【解决方案1】:

我假设您的目标是更新在 Cloud Functions 上运行的代码 - 如果我错了,或者这没有帮助,请纠正我。

通过 Cloud Build

正如 Guillermo 所说,您可以使用 Cloud Build 自动将更改部署到您的 Cloud Functions 代码。有关如何将 Cloud Functions 与 Cloud Build(以及您选择的版本控制系统)集成的信息,请参阅 this page

通过 API

如果您希望以编程方式更新您的 Cloud Functions 代码,请查看projects.locations.functions.create API 调用。

希望这会有所帮助!

【讨论】:

    猜你喜欢
    • 2021-03-09
    • 2018-03-18
    • 1970-01-01
    • 1970-01-01
    • 2019-03-19
    • 2019-03-03
    • 2017-05-18
    相关资源
    最近更新 更多