Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

AWS Lambda Function to send an initial password to a new user via Slack DM

License

Notifications You must be signed in to change notification settings

suzuki-shunsuke/aws-iam-cred-sender

Repository files navigation

aws-iam-cred-sender

Build Status Go Report Card GitHub last commit License

AWS Lambda Function to send an initial password to a new user via Slack DM

Assumption

IAM User name and Slack's display name must be same.

Overview

When an IAM User is created, the Lambda Function is triggered via CloudWatch Event. The function searches the Slack User with IAM User name. If the IAM User isn't found, the function notifies that the IAM User is created to a Slack channel.

image

If the IAM User is found, the function creates the IAM User's login profile and sends the initial password to the user via Slack DM.

image

If the login profile already exists, the password is changed by default. This behavior can be changed.

Architecture

aws-iam-cred-sender

Configuration

Please see here

Lambda Execution Role

Please see here

Slack App Permission

  • chat:write (chat.postMessage)
  • users:read (users.list)

DynamoDB

This function needs a DynamoDB table. Please see here.

LICENSE

MIT

About

AWS Lambda Function to send an initial password to a new user via Slack DM

Resources

License

Stars

Watchers

Forks

Packages

No packages published