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

Providing the environment to buildpacks #3

Open
stuartpb opened this issue Aug 7, 2014 · 4 comments
Open

Providing the environment to buildpacks #3

stuartpb opened this issue Aug 7, 2014 · 4 comments

Comments

@stuartpb
Copy link
Member

stuartpb commented Aug 7, 2014

I think this is an issue? It looked like some of those buildpacks expect config vars.

@stuartpb
Copy link
Member Author

Determining if buildpacks want the environment requires further investigation.

@stuartpb
Copy link
Member Author

https://github.com/motin/dokku-user-env-compile implies it was something provided by a separate plugin, emulating a labs feature at https://devcenter.heroku.com/articles/labs-user-env-compile, which now directs to https://devcenter.heroku.com/articles/buildpack-api - I think it's now just a documented thing a buildpack can do, if it needs it.

Anyway, this can be added with a separate plugin, if/when I've added the hook for adding commands to the build step.

@stuartpb
Copy link
Member Author

Okay, so I've done a little more investigating. user-env-compile is something that can be added with a plugin (although, since the labs feature ended up being deprecated and I'm pretty sure unused now, I'm not sure what that would do. Maybe it would help apps with buildpacks that call scripts that are part of the app and need the config variables defined?)

However, Heroku ended up taking a different approach, as documented on https://devcenter.heroku.com/articles/buildpack-api, where it provides a directory (named in the third argument of the buildpack) of files, similar to what's just been proposed in plushu/plushu-config#4.

Since this passing of arguments to the buildpack's compile happens as part of /build/builder, this needs to be implemented upstream first: progrium/buildstep#81

With the appropriate functionality in place, we can implement this with a build-app-docker-opts hook (basically the same as run-app-docker-opts), and then have plushu/plushu-options hook it to mount the directory from plushu/plushu-options#4 as /env.

@stuartpb stuartpb changed the title Environment not exposed when building Providing the environment to buildpacks Aug 25, 2014
@stuartpb
Copy link
Member Author

If/when progrium/buildstep#99 is merged, this can move forward. (Could also use my own fork.)

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

No branches or pull requests

1 participant