Local environment for testing purposes #541
Answered
by
simonkrol
YasenMakioui
asked this question in
Q&A
-
Is there any type of documentation to set this project locally for testing? With this I mean a way to serve this app to make requests and test my consumer application before deploying the solution. |
Beta Was this translation helpful? Give feedback.
Answered by
simonkrol
May 29, 2024
Replies: 1 comment 1 reply
-
Hi, Could I have some guidance on the local environment? Do I have to start the project using Sharp? Is there a way to get the images from the filesystem for a local dev environment? Thank you, |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi @YasenMakioui,
As SIH retrieves the image to be processed directly from S3, we don't currently support using SIH through a local environment. There are some tests under
source/image-handler/test/index.spec.ts
which run through most of the process locally, you could look into modifying how the GetObject call is mocked to provide the image you're interested in testing. Our recommendation is to perform testing on an instance of SIH deployed to AWS throughcdk deploy
, allowing you to make changes to the application and update the stack quickly and efficiently through the command line (More info available in the README).Thanks for your interest in Serverless Image Handler,
Simon