Welcome to the second post about Rendr. In the following steps we are gonna see how to setup a Rendr app to upload it to Heroku. So less talking and more doing:
- In the root directory we have to create a file called Procfile. Inside this file we have to write the following line:
- Then we modify Gruntfile.js, also in the root directory. Inside this file, at the bottom, we have to add the highlighted line:
- Due to the fact that we can't compile assets, templates and styles in the Heroku server, we have to compile those files in our workstation (running sudo grunt ) and then add them to the Heroku commit.
- Upload all the files to Heroku and wait the start-up process.
- Listo ;)
1: web: node index.js
0: ...
1: // Default task(s).
2: grunt.registerTask('default', ['compile']);
3: grunt.registerTask('heroku:', ['compile']);
4: };
PS: If the dyno didn't start run : heroku ps:scale web=1
I hope you find it useful.
@sdemians
No hay comentarios:
Publicar un comentario