Google 没有 Google 云的家庭开发

Google Home Development without Google Cloud

有没有一种无需使用 Google 云或打开 API 到 public 互联网即可为 Google 家庭开发的方法?

我处在一个受限的环境中,不能在不跳过很多障碍的情况下向全世界开放服务器。如果我可以在内部完成这一切,就可以省去很多麻烦了。

您不需要 Google 云,但您需要 API 在 public 互联网上。您可以 运行 Web 服务器上的所有内容,但当然 Google 需要查看该服务器才能向您发送请求。

对于开发,我们有自己的开源工具集Bespoken Tools. It supports mainly Alexa for now but Google Assistant support is on the way. But from these tools, you can use the bst proxy to expose the server on your local machine inside the firewall (if your company lets you). A similar tool is nGrok

我从 Google 云开始,但部署过程对于快速开发而言花费的时间太长。相反,我一直在使用为 node.js and ngrok 制定的步骤 Google。开发速度要快得多,因为我可以更改代码并每次只需重新启动 node.js 服务器,只需 2 秒。

分步设置(简单): https://developers.google.com/actions/tools/ngrok

由于我们所处的商业环境,ngrok 之类的解决方案行不通(尽管对于个人事务,我可能会采用这种方法)。

我们最终使用 TDD 来编写针对测试场景的代码。这让我们大大加快了开发速度,因为每当我们在实际设备上进行实际测试时,99.9% 的东西第一次都能正常工作。