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

Add support for custom post-install code execution #14

Open
ncoghlan opened this issue Sep 12, 2024 · 0 comments
Open

Add support for custom post-install code execution #14

ncoghlan opened this issue Sep 12, 2024 · 0 comments
Labels
Affects: Metadata Affects the stack output metadata Affects: Python API Affects the public Python API of the project Affects: Spec Format Affect the stack specification format Category: Enhancement New feature or request

Comments

@ncoghlan
Copy link
Collaborator

ncoghlan commented Sep 12, 2024

Sometimes an environment may need additional tweaks after deployment (e.g. fixing up absolute paths in data files, regenerating console entry point wrappers).

This issue covers designing and implementing a mechanism to support that.

For example, perhaps the layer specs could all gain a postinstall_script relative path field (similar to launch_module, but as a full Python script name), that gets copied to _postinstall_customize.py (adjacent to postinstall.py), which the generated postinstall.py runs with runpy.run_path(pathlib.Path(__file__).parent / "_postinstall_customize.py"). (To allow use of zipapp files, the extension on the specified script should be preserved)

@ncoghlan ncoghlan added the Category: Enhancement New feature or request label Sep 12, 2024
@ncoghlan ncoghlan transferred this issue from another repository Oct 18, 2024
@ncoghlan ncoghlan added Affects: Python API Affects the public Python API of the project Affects: Spec Format Affect the stack specification format Affects: Metadata Affects the stack output metadata labels Oct 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Affects: Metadata Affects the stack output metadata Affects: Python API Affects the public Python API of the project Affects: Spec Format Affect the stack specification format Category: Enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant