0

I would like to write a lambda function in java so that whenever a particular folder on an EC2 instance is updated with a new file, I need to get that file and upload it to an S3 bucket. Can I do that? What is the appropriate event to handle in the lambda function ? Any example ? Thanks in advance. - Ramesh.

1 Answer 1

2

No, Lambda can't be triggered directly from a file appearing in a folder on an EC2 instance. Look at inotifywait or equivalent. Run that on the EC2 instance and respond to files appearing by syncing them to S3.

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks Jarmod for the confirmation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.