Skip to content

pariveda-serverless/ny-doorman

Repository files navigation

#Doorman

This will open the door for your coworkers when they enter the office.

This was send in as part of the AWS Deeplens Hackaton

Tools

  • Serverless Framework for easy serverless development and deployment
  • CircleCI for application CI/CD - /.circleci/config.yml contains the job and workflow configurations
  • AWS for application and infrastructure hosting, primarily API Gateway, Lambda, S3

Slack development resources

Initial Setup

Quite a few steps, needs cleanup, most of it can be automated.

  • Create a bucket, remember the name, make sure that your deeplens user can write to this bucket.

  • Create a Rekognition collection (and note the collecition id)

  • Be sure to have the following env vars in your environment:

    • BUCKET_NAME=your-bucket-name
    • SLACK_API_TOKEN=your-slack-token
    • SLACK_CHANNEL_ID="slack-channel-id"
    • REKOGNITION_COLLECTION_ID="your-collection-id"
  • Deploy the lambda functions with Serverles (eg: sls deploy), this will create a CF stack with your functions. Note the api gateway endpoint, you'll need it later

  • Go into the deeplens console, and create a project, select the "Object detection" model

  • Remove the deeplens-object-detection function, and add a function for find_person

  • Deploy the application to your deeplens

  • Go to the slack api, and click "create a new app".

  • Give a name, and select your workspace

  • Activate:

    • Incoming webhooks
    • Interactive components (use the api gateway endpoint that you noted before, ignore Load URL)
    • Permissions: Install the app in your workspace, and note the token. You'll need chat:write:bot, channels:read and incoming-webhook.
  • Deploy the app again with the new environment variables

That should be it. Whenever the Deeplens rekognizes someone, it will upload into the S3 bucket. Which will trigger the other lambda functions.

Architecture

Architecture

Video

Video

About

Deep Lens Doorman project specific to NY office.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages