feature: add custom entry_point support to FrameworkProcessor.run()#5742
Open
rauldiaz wants to merge 1 commit intoaws:masterfrom
Open
feature: add custom entry_point support to FrameworkProcessor.run()#5742rauldiaz wants to merge 1 commit intoaws:masterfrom
entry_point support to FrameworkProcessor.run()#5742rauldiaz wants to merge 1 commit intoaws:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description:
This change adds an optional
entry_pointparameter toFrameworkProcessor.run(), allowing users to provide a customrunproc.shscript that replaces the default auto-generated one. The custom script content is embedded into the entrypoint, with the python command to execute the user script appended automatically.Motivation:
The default runproc.sh generated by FrameworkProcessor installs dependencies via
pip install -r requirements.txtusing the public PyPI index. In enterprise environments where internet access is restricted and Python packages are hosted on internal repositories (e.g., JFrog Artifactory, AWS CodeArtifact), users need to customize the entrypoint to configure pip with the appropriate index URL, certificates, or authentication before installing dependencies. This change enables that without requiring users to do complex workarounds or modifying the SDK.Changes:
entry_pointparameter toFrameworkProcessor.run()and threaded it through_pack_and_upload_code,_create_and_upload_runproc, and_generate_framework_script._generate_custom_framework_script()method that reads the custom script file and embeds its contententry_pointis relative andsource_diris provided, they are combined; absolute paths are used as-isTesting:
custom_framework_processor.ipynb