Elixir

Elixir applications can be deployed on Scalingo thanks to the community buildpack: https://github.com/HashNuke/heroku-buildpack-elixir. A community buildpack means that Elixir is not officially supported and minimal support is provided in case of problem with the buildpack execution.

Elixir detection

For your Elixir app to be detected you have to declare explicitly the above mentioned buildpack in your application’s source code. To do this, create a file named .buildpacks with the following content:

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

Configuration

In order to configure the buildpack, please add a elixir_buildpack.config file at the root of the application. This file is a bash file. In order to configure the OTP version:

erlang_version=21.2.6

A comprehensive list of configuration options is available here. The configuration applied by default is here.

Phoenix Web Framework

Phoenix support requires combining the elixir buildpack mentioned above and a phoenix specific buildpack: the first one handles compiling the Elixir code, the second one handles the assets compilation.

Create a file named .buildpacks in your project which will define the buildpacks to use:

https://github.com/HashNuke/heroku-buildpack-elixir
https://github.com/gjaldon/heroku-buildpack-phoenix-static

Configuration

The phoenix buildpack can be configured using the phoenix_static_buildpack.config file:

node_version=12.0

A comprehensive list of configuration options is available here. The configuration applied by default is here.


Suggest edits

Elixir

©2024 Scalingo