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.
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).
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
Related
I'm new using App Engine, and I would appreciate if someone can clarify this doubt:
How can I be sure that AppEngine in the cloud have the correct version of go I need to have in the cloud?
I have read some articles about installing and downloading the SDK for google on my local machine (and of course, I am able to install the version I need on my machine); but once I have generated my app in Go and I want to deploy it to App Engine in the cloud, how can I be sure Google infrastructure has the correct version?
I want to install Iris Web framework as part of the stack but it requires to go vers 1.14 or superior, Google App Engine standard only provides support for Google 1.11 and 1.12+ so I think I would need to go for the Google App Engine Flexible option, if that were the case, how can I be sure it has or support the Go version I need?... Or Is there some procedure to follow to install it ?
Thanks in advance for your support
You can use the standard environment. The documentation for the standard environment says:
The Go 1.12+ runtime supports the following major versions: Go 1.12, Go 1.13, Go 1.14, Go 1.15, and Go 1.16. Your app uses the latest stable release of the version that is specified in your app.yaml file. App Engine automatically updates to new patch revisions, but will not automatically update the major version.
Here's an example version spec in app.yaml:
runtime: go115
With the Flexible environment you have the ability to pin a version rather than using the latest available/supported. In order to do that, you will have to specify in your app.yaml file the exact version you would like it to be:
runtime: go1.14
If you specify only runtime: go it will pull the latest release available for Go language (which seems to be 1.19).
For more information, please refer to this documentation: https://cloud.google.com/appengine/docs/flexible/go/reference/app-yaml#general
How to deploy a web application to heroku in new version of cloud9 ?
The previous version had the deploy button, but cannot be found in new version
In the new version of Cloud9 we don't have support for deployment from the UI yet unfortunately, but we're going to add those features soon. In the meantime, we recommend using the command line from the built-in terminal, as described on our documentation site here: https://docs.c9.io/deploying_via_cli.html
In addition to the directions that Ivar published above you may need some additional steps.
For Rails deployment you need to:
1) Add your SSH key via the command line to heroku using: $ heroku keys:add
Source: https://devcenter.heroku.com/articles/keys
2) Remove SQLite and add Postgresql
Directions and source: https://devcenter.heroku.com/articles/sqlite3
I noticed this too but I have already setup my deployment using snap-ci.com it takes about a minute and when you check into your repository snap-ci will deploy it to heroku for you. I know it doesn't exactly answer your question but its a very simple alternative. I would add that down the road if you need additional deployment steps you are already part way there if you use a CI system.
I managed to do it via c9 command line as there were some proxy issues which I couldn't figure out in my local computer.
AppHarbor supports Node using iisnode. Can I deploy my Sails.js app to AppHarbor at this time, and if so, how?
I honestly have no idea what I'm doing with a node deploy but I'm trying to follow along with what I'm reading online. When I deploy my code out to my repo and AppHarbor builds it I get the following error: The current identity (...) does not have write access to 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files'.
UPDATE (September 2013)
There is an updated deployment guide here:
https://github.com/balderdashy/sails-wiki/blob/0.9/deployment.md …
#chadn posted an example Heroku deployment with Sails.js here:
https://github.com/chadn/heroku-sails
Original post
I don't know a whole lot about Windows deployments in general, but we do have a deployment guide here:
https://github.com/balderdashy/sails/wiki/Guide:-Deployment
Also, I know the guys/gals at Nodejitsu and Modulus have helped out folks getting their Sails apps set up, so that might be a good place to start as well.
Good luck!
I have a catalog of builds indexed by git revision stored on s3 by our CI server. Instead of performing a build at deploy time, I would like to just download a pre-built application, unpack it and go.
I'm trying to accomplish this with a custom buildpack, but in order to do so, I need for it find out which revision of the code is being compiled. Sadly (for me), I can not find this information anywhere in the environment.
It seems like this is something that ought to be discoverable somehow, but I'm completely flummoxed as to where.
You might want to take a look at the (not officially supported) heroku-anvil plugin, which includes the heroku release command to push externally created slugs to a Heroku app. It was originally designed for working with slugs created with Anvil, but should work for any TAR GZ, as long as it can be run on Heroku. For example you could do something like this:
$ heroku release https://s3.amazonaws.com/my-bucket/slugs-000.tgz -a myapp-staging
Releasing to myapp-staging.heroku.com... done, v42
I'm trying out Play! with heroku and was going through the guide in the heroku site (https://devcenter.heroku.com/articles/play). After deploying my sample app, I noticed the dyno crashed. I checked the heroku logs and found out that heroku couldn't find the play command.
Anyone know how to install the Play! framework on heroku? I searched the dev center but couldn't find any info.
I had the same issue and the fix was changing the Procfile to use the command target/start instead of play and then pushing it to Heroku. Refer to the diff below.
Heroku will automatically detect Play! applications and install the Play! runtime for you when you push your code to Heroku. If Play! isn't being installed, its likely that your app is not being detected properly as a Play! app.
In the case of Play! 1.2.x (as in the Dev Center article you were reading), the Play! buildpack that will do the detection, and in the case of Play 2.x, the Scala buildpack is used to detect and install the Play! framework for you. For more information about Heroku Play Framework Support and what is needed for detection, see:
https://devcenter.heroku.com/articles/play-support
If you are still having problems with your app getting detected, I'd recommend cloning and pushing https://github.com/heroku/devcenter-play.git, which is the complete sample app from the Dev Center article you were reading:
git clone https://github.com/heroku/devcenter-play.git
cd devcenter-play
heroku create
git push heroku master
heroku open
The accepted answer is correct, but if you want to define your own Procfile you'll need to follow the instructions that adib provided. The sample Procfile that's currently listed on Heroku's site is specific to play 1.x apps.