Allow specifying a custom Docker image name and registry #53
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 pull request enhances the
setup-localstackaction by introducing a new input,image-name. This allows users to specify a full Docker image name, including a custom registry (e.g.,my.registry.com/localstack/localstack:latest), rather than being limited to images hosted on Docker Hub, for when organizational policies restrict where images are allowed to be pulled from.The action has been updated to prioritize the
image-nameinput. If it is provided, it will be used directly to pull the LocalStack image (populating the$IMAGE_NAMEenvironment variable). If it is not provided, the action will fall back to the existing behavior of constructing the image name using theimage-taginput.This change provides greater flexibility for users who manage their own Docker registries or use mirrors.
Changes
image-nameinput inaction.ymland pass it to thestartupsub-action.startup/action.ymlto accept theimage-nameinput and modify the startup logic to prioritize it overimage-tag(directly populating$IMAGE_NAME).README.mdto include the newimage-nameinput.How to use
To use a custom image, simply add the
image-nameinput to your workflow: