0

I'm trying to deploy the sample apiai-facts-about-google-nodejs on heroku. I've followed the instructions but when trying to start the app, in the logs, I get the error:

functions deploy factsAboutGoogle --trigger-http
sh: 1: functions: not found

This seems to be because the code was written for Google Cloud Functions. I think the command:

functions deploy xxxxxx --trigger-http

is GCF specific. Do I need to modify this code in some way to make it run on Heroku?

I saw this question/answer which seems to indicate it should just work as-is, but that's not what I'm seeing.

Bruce H
  • 321
  • 2
  • 7

2 Answers2

1

A previous version of the sample which worked on app engine was compatible with Heroku. The latest version is designed for Cloud functions and you will have modify the code (you could find the previous version in the Git history).

Leon Nicholls
  • 4,623
  • 2
  • 16
  • 17
1

As @leon-nicholls noted:

A previous version of the sample which worked on app engine was compatible with Heroku. The latest version is designed for Cloud functions and you will have modify the code

Here is a working with heroku version of the "Facts about Google" sample exemple: https://github.com/actions-on-google/apiai-facts-about-google-nodejs/tree/d1ac5ac5b3838569f1e55602e0103d8863971572

Quentin Dunand
  • 233
  • 2
  • 11