Skip to content

Instantly share code, notes, and snippets.

@entzik
Created May 31, 2018 21:42
Show Gist options
  • Save entzik/e07658531b39c6ad9c716625d5a33081 to your computer and use it in GitHub Desktop.
Save entzik/e07658531b39c6ad9c716625d5a33081 to your computer and use it in GitHub Desktop.
A shell script to create and deploy AWS lambda function
#!/bin/sh
aws lambda create-function \
--function-name ClimateMonitor \
--region eu-west-3 \
--zip-file fileb://build/libs/iot-home-climate-monitoring-1.0.0.BUILD-SNAPSHOT-aws.jar \
--role arn:aws:iam::603595916284:role/climate-monitor-role \
--handler com.thekirschners.iot.home.monitoring.Handler \
--environment Variables="{DB_HOST_NAME=localhost,DB_USERNAME=postgres,DB_PWD=password}" \
--runtime java8 \
--timeout 120 \
--memory-size 512
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment