Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/carlo-colombo/elixir-buildpacks
https://github.com/carlo-colombo/elixir-buildpacks
cnb docker elixir erlang pack
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/carlo-colombo/elixir-buildpacks
- Owner: carlo-colombo
- License: mit
- Created: 2020-02-21T12:08:21.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-05-10T20:26:06.000Z (over 2 years ago)
- Last Synced: 2024-10-31T19:12:41.482Z (3 months ago)
- Topics: cnb, docker, elixir, erlang, pack
- Language: Shell
- Size: 21.5 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# elixir-buildpacks
A collection of buildpacks to build images of elixir projects
1. `erlang-runtime`
1. `elixir-runtime`
1. `mix-release` download project dependencies and create an [Elixir Release](https://elixir-lang.org/blog/2019/06/24/elixir-v1-9-0-released/#releases)
1. `elixir` meta buildpack that define the order in which buildpack runIn addition `rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder` is a builder based on `ubuntu:bionic` including the 4 buildpacks.
This stack support `org.cloudfoundry.stacks.cflinuxfs3` (`cloudfoundry/cnb:cflinuxfs3`) and `io.github.carlo-colombo.elixir-builder`
### Umbrella applications
To create a release from an umbrella application run from the root of the application defining the release to build with the `RELEASE` env variable
```bash
pack build dashboard \
--path . \
--builder rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder \
-e RELEASE=dashboard -e SECRET_KEY_BASE=asdadasdasd
```Note: is not supported to build individual release from the app folder, as in app dependency and configuration would be outside of the directory passed to `pack`.
### Know limitations
- It at least partially support `phoenix`, it requires to pass in `SECRET_KEY_BASE` as environment variable. For example
```bash
pack build dashboard \
--path . \
--builder rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder \
-e DEBUG=1 \
-e SECRET_KEY_BASE="$(mix phx.gen.secret)"
```## How to build an image with pack
### Using the builder image
```bash
pack build \
--path \
--builder rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder
```### Using individual buildpacks
```bash
pack build \
--path \
--buildpack ./elixir/ \
-b ./elixir-runtime/ \
-b ./erlang-runtime/ \
-b ./mix-release/ \
--builder rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder
```## How to create the builder image
```bash
cd elixir-builder
./build.sh
```It create an image on the local docker named `rg.nl-ams.scw.cloud/carlo-colombo/elixir-builder`