I want to run a python code that I have in my S3 bucket using AWS lambda
I tried with os library, but it have not worked out
My code is:
from __future__ import print_function
import os
def lambda_handler(event, context):
os.system('python https://s3.us-east-2.amazonaws.com/BUCKET/CODE.py')
I get the message "No such file or directory"
I am using lambda because the code in python must be triggered when some event happends
How can I run my code?