[full example]
from chalice import Chalice
app = Chalice(app_name="helloworld")
@app.route("/")
def index():
return {"hello": "world"}
@app.schedule(Rate(5, unit=Rate.MINUTES))
def periodic_task(event):
return {"hello": "world"}
@app.on_s3_event(bucket='mybucket')
def s3_handler(event):
print(event.bucket, event.key)
python3 --version
python3 -m venv venv37
. venv37/bin/activate