Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support post compile hook #31

Closed
chrismccord opened this issue Apr 30, 2015 · 10 comments · Fixed by #39
Closed

Support post compile hook #31

chrismccord opened this issue Apr 30, 2015 · 10 comments · Fixed by #39

Comments

@chrismccord
Copy link
Contributor

For Phoenix, we would like to have a complete buildpack solution when we ship 1.0, which means we need to be able to build brunch assets after compile. I'm not sure where to start here, but @ericmj has some idea where we need to begin.

@HashNuke
Copy link
Owner

HashNuke commented May 1, 2015

@chrismccord won't that mean we would need node.js installed too? (https://github.com/ddollar/heroku-buildpack-multi).

\cc: @ericmj

@rwdaigle
Copy link

Just an FYI that Heroku Buildpacks have changed a bit. You no longer need the multi-buildpack to specify a build pipeline. Instead, specify each buildpack individually with the following CLI:

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

Regarding brunch asset compilation, here's how they do it in the official Ruby/Rails buildpack.

@ericmj
Copy link
Collaborator

ericmj commented May 31, 2015

Should we automatically run a post_compile / post_compile.sh file in your root directory or should we take the file from a post_compile option in elixir_buildpack.config?

/cc @josevalim

@josevalim
Copy link

I thought the plan was to not support hooks. What changed? :)

@HashNuke
Copy link
Owner

HashNuke commented Jun 1, 2015

At work, I was working with a non-Heroku deployed app where the compilers option in mix.exs was used to add a :frontend compiler so that everytime the app is started or compiled, the frontend too gets compiled.

Curious how a post compile hook will help on Heroku since we depend on mutl-buildpack for asset compilation.

@ericmj
Copy link
Collaborator

ericmj commented Jun 1, 2015

At work, I was working with a non-Heroku deployed app where the compilers option in mix.exs was used to add a :frontend compiler so that everytime the app is started or compiled, the frontend too gets compiled.

The problem is that you might not want to compile assets on every compilation or app start so a Heroku specific compilation step is very useful.

Curious how a post compile hook will help on Heroku since we depend on mutl-buildpack for asset compilation.

Not sure what you are asking here, as long as the node buildpack runs before the elixir buildpack it will work.

@HashNuke
Copy link
Owner

HashNuke commented Jun 2, 2015

@ericmj I meant to ask what the use case was for the post-compile hook. I remember there was this discussion earlier in another issue and that that issue was closed.

Sorry read your comment in bed and forgot to reply the other day.

@ericmj
Copy link
Collaborator

ericmj commented Jun 2, 2015

@HashNuke
Copy link
Owner

HashNuke commented Jun 2, 2015

@ericmj 👍 thanks for linking. Got it now ~!

@HashNuke
Copy link
Owner

Yaaay ~!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants