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

Document script working directory and environment variables #47

Open
jonhoo opened this issue Jul 19, 2017 · 1 comment
Open

Document script working directory and environment variables #47

jonhoo opened this issue Jul 19, 2017 · 1 comment

Comments

@jonhoo
Copy link

jonhoo commented Jul 19, 2017

In certain pre/post scripts, it is useful to be able to refer back to files in the directory that houses that script itself (e.g., static assets, configuration files, etc.). It would be great if the working directory at the time when image-bootstrap is invoked was somehow made accessible to scripts (perhaps through an ORIGINAL_WD environment variable? An alternative would be to just chdir back to the original working directory before invoking the scripts; I don't know which is better.

@jonhoo
Copy link
Author

jonhoo commented Jul 19, 2017

Ah, it seems like the working directory is preserved. This should probably be documented somewhere!

@jonhoo jonhoo changed the title Add environment variable holding working directory Document script working directory and environment variables Jul 20, 2017
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

No branches or pull requests

1 participant