Giter Site home page Giter Site logo

timelapse-lambda's Introduction

timelapse-lambda

installation

1. Deploy the ffmpeg-lambda-layer on your Lambda

2. Create an S3 bucket

name it, for example, "garden-snapshots" in the same region as the ffmpeg-lambda-layer

3. Create timelapse lambda

run ./create-aws-lambda by specifying the needed parameters, below you can find an example.

in the same region as above!

./create-aws-lambda \
  --region us-east-1 \
  --lambda Timelapse \
  --role arn:aws:iam::XXXXXXXXXXX:role/lambda_name \
  --ffmpeg arn:aws:lambda:us-east-1:XXXXXXXXXXX:layer:ffmpeg:1

4. update the lambda with the code

specify the region and the lambda name as above and run:

./deploy-aws-lambda \
  --region us-east-1 \
  --lambda Timelapse

usage

npm install and take a look at launch-lambda-example.js:

#!/usr/bin/env node

const AWS = require('aws-sdk')

const region = 'us-east-1'

const apiVersion = 'latest'
const lambda = new AWS.Lambda({ apiVersion, region })
const invokeParams = { FunctionName: 'Timelapse' }

lambda.invoke(invokeParams, (err, data) => {
  console.log(err, data)
})

timelapse-lambda's People

Contributors

christian-fei avatar

Stargazers

Anton Seledets avatar Jason Choo avatar  avatar Santiago Ferreira avatar Jagdeesh Karicherla avatar  avatar  avatar  avatar Sabir avatar

Watchers

James Cloos avatar  avatar

timelapse-lambda's Issues

missing lambda.zip file?

Hi - thanks for creating this! I'm new to lambda and may be missing something simple, but when I run create-aws-lambda I get the error:

Error parsing parameter '--zip-file': Unable to load paramfile fileb://lambda.zip: [Errno 2] No such file or directory: 'lambda.zip'

This is probably basic and due to my inexperience. Thanks!
Declan

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.