FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

sinclair/herixir: Toying with Elixir, Phoenix and React ... and Heroku. · GitHub

Repository files navigation

Herixir

Messing about with Elixir, Phoenix, React and Heroku deployment.

Steps

Generated a Phoenix app as instructed here

http://bit.ly/phoenix-getting-started

All commands in the following steps should be issued from the application root directory.

Creating the Heroku app with the Elixir build-pack

Initialization and Creation
git init
heroku create <your app name for heroku>
Heroku Elixir build-packs

Basically, Elixir is not a core language at this time so it is necessary to use an Elixir build-pack to deploy an Elixir app to Heroku. More information can be found here, http://bit.ly/heroku-buildpack-api .

(Credit to, https://github.com/HashNuke/heroku-buildpack-elixir.git)

heroku buildpack:set https://github.com/HashNuke/heroku-buildpack-elixir.git

Note: The setting of the build-pack can occur when creating the Heroku app thus,

heroku create <your app name for heroku> --buildpack https://github.com/HashNuke/heroku-buildpack-elixir.git

This is an alternative approach with the same outcome.

Initializing elixir_buildpack.config
cat >> elixir_buildpack.config <<!
erlang_version=17.2
elixir_version=1.0.3
always_rebuild=true
!
Heroku run-time configuration
heroku config:set MIX_ENV=prod
Creating a Procfile for Heroku to launch the app
web: mix compile.protocols && elixir -pa _build/prod/consolidated -S mix phoenix.server
Run locally before deploying
heroku local

Note: Needs the 'foreman' ruby gem to be installed.

Deploying to Heroku (via git push)
Git commit
git commit -am "committed most recent changes"
Heroku deploy
git push heroku master

About

Toying with Elixir, Phoenix and React ... and Heroku.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages


Back | FazBrowse Home | New Git URL