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.
Related
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
I am looking for extending WebSphere Liberty buildpack included in Bluemix with some third party libraries from our application architecture, so the size of EAR file will decrease a lot and cf push command will be more fast and agile. Is it possible?
I know there is a WebSphere Liberty buildpack open sourced at Cloudfoundry.org but as far as I know, it is not so powerful like the one included in Bluemix and we would loose some interesting features.
Thanks!
The Liberty buildpack you find on GitHub should be pretty similar to the one Bluemix uses especially in terms of features. Beta features are included and auto-configuration should work so in theory if you do cf push appName -b https://github.com/cloudfoundry/ibm-websphere-liberty-buildpack.git -p myapp.war it should work the same way if you did cf push appName -p myapp.war.
If you want to modify the buildpack you can fork it and add the jars you want although I am unsure on the process for adding the jars. Maybe someone else can add an answer that points you in the right direction.
You can find an alternative buildpack for Websphere Liberty here. As you will notice, it is actually a CloudFoundry buildpack -- normally all of them will work in Bluemix. To use it, add a buildpack: line to your manifest.yml or a -b option to cf command line tool.
There is not much detail in your question as to what libraries or modifications you need, but this buildpack is in github and you can freely fork it and modify it. The buildpack prepares the runtime, and you should be able to add your own downloads in some hooks and replicate the directory structure you must be using locally. It is also very well documented, so you should find your way through the configurations if you are doing anything non-standard.
You are welcome to share your own new buildpack too!
If you want to be more efficient during the development cycle where you constantly push changes, you can try the 'development mode' support in the Bluemix Liberty buildpack. This allows you to push incremental file changes without even restarting the Liberty server (not to mention the whole application container, aka no cf push). See the doc here: https://www.ng.bluemix.net/docs/manageapps/eclipsetools/eclipsetools.html#incrementalpublish. You can also do remote debugging with development mode.
To customize a Liberty server in Bluemix, you can also use the server package command of a local Liberty server, and then cf push the generated zip.
See https://www.ibm.com/developerworks/community/blogs/msardana/entry/developing_with_bluemix_customizing_the_liberty_build_pack_to_add_your_configurations for details
That, of course, defeats your goal of smaller deployment times, but I wanted to add the possibility for completeness and to prevent someone from forking the buildpack without needing it.
So, I've download the Heroku Integration, with PyCharm 2.7.2. I've put in the API key, added an app with a name I chose. I want to create just a basic django app on a heroku free account. So, what do I do now? Could someone please give me some basic instructions as to how you get started with actually uploading all the stuff in your project to Heroku?
Not sure about the pycharm integration, but the easy answer is git push to heroku.
When using pycharm, I just do Menu >> VCS >> Git >> Push. Then if heroku is not your default remote (origin), check the box for push to alternate remote/branch. I choose heroku and master and away it goes!
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.
My hosting service just informed me that they don't have Git installed on any of their servers. I am at a loss as to how I am going to deploy a project there. My only option is Bash, it seems. Is it possible to deploy a project using bash only? Help is much, much appreciated.
Regards
I had the same issues, I found the deploy option in http://beanstalkapp.com to be excellent, you can setup deploy via SFTP/FTP from your GIT/SVN repo.
And even deploy in staging.