Closed millisami closed 10 years ago
You're right about the Mina part being for your own VPS.
I have deployed a Tapas project to Heroku, however, and it's really easy. You just need a Procfile
that runs a simple static web server. Stretch is an open-source Ember app built with Tapas that I deploy to Heroku.
@mutewinter , I looked into those links. But turns out that its using node.js stuffs in server.coffee.
Don't I've to build the app using cake build
and do some commits and push over to heroku?
Can you give a short illustration for such really easy task? Well, I'm not finding it easy. :)
I left a step out actually, let me make it clear.
public
like this one.project.json
. This will cause Heroku to build the project every time it's pushed.Procfile
that starts the server.Now when you push to Heroku the postinstall step will build the app and put it in the public folder. Then Heroku will start the server using the Procfile. That server will serve the static assets in the public folder.
That's it, the app should be running. Let me know if that makes sense.
@mutewinter Thanks, I will try it out and be back if any issues pops up.
Hi @mutewinter , yeah I was able to deploy to heroku. But in production version, the CSS is not the same as in the development. Following is the screenshot on development: And this is on production heroku at http://drag-n-drop.herokuapp.com
Note the difference on top h2 backgrounds and font styles and sizes!!
I've pushed this repo at https://github.com/millisami/drag-n-drop-emberjs
I think its the issue with compile while it builds with cake build
.
Can you have a look at it why such CSS difference between two versions?
I noticed you've got a bower.json file with no dependencies specified. Is it possible that your local copy has something in the bower_components
folder that should be saved?
Never mind, see below.
I checked out your repo and compiled it and I'm seeing the same thing. Looking into it further.
Aha! I know what is causing this. It's a build environment issue with Heroku. Basically, your app is picking up styles from a folder within a node dependency. I fixed this in my other app on Heroku in this commit. You just need to modify your config.coffee
to look like this.
This happens because Heroku's node buildpack puts node and npm in the vendor
directory.
My solution in Stretch just ignores the vendor folder. To conditionally ignore the vendor/node
folder that Heroku adds, use the following:
stylesheets:
joinTo:
'stylesheets/app.css': /^(app|vendor\/(?!node))/
order:
before: ['vendor/stylesheets/normalize.css']
Been looking into interwebs about how to deploy ember apps, but found none helpful. In the README, @mutewinter , you've specified the Mina part. But looks like it will work for the VPS only or at least it needs SSH access.
It would be helpful to know on how to deploy on Heroku. A cake task might be super useful if provided. Or, can u guide me through and I can update the README!!