apod-slack-lambda

1.0.2 • Public • Published

apod-slack-lambda

Send yourself the Astronomy Picture of the Day via Slack, with a little help from AWS Lambda.

I created this to learn how to use Lambda to schedule a simple task. I wanted the configuration to live in version control, and the whole thing to be deployed automatically, so I decided to use ThoughtWorks Studios' nice library node-aws-lambda.

I added functionality to automatically configure Lambda functions with scheduled events, which I later moved into its own package, node-aws-lambda-scheduler.

Deployment

  1. Clone this repository.
  2. Set up your AWS credentials in ~/.aws/credentials, if you haven't already.
  3. If necessary, create an IAM role for Lambda execution.
  4. Configure your Lambda execution IAM role in config/default.yml.
  5. Optional: Adjust the ScheduleExpression in config.default.yml.
  6. Configure an incoming webhook integration in Slack. Copy ./config/local.template.yml to ./config/local.yml, which is gitignored, and fill it in.
  7. Optional: To avoid rate limits with NASA's demo key, obtain your own NASA API key and configure it in ./config/local.yml.
  8. Deploy: node_modules/.bin/gulp deploy

Contribute

Pull requests welcome!

Support

If you are having issues, please let me know.

License

The project is licensed under the MIT license.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.2
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.2
    1
  • 1.0.1
    0
  • 1.0.0
    0

Package Sidebar

Install

npm i apod-slack-lambda

Weekly Downloads

1

Version

1.0.2

License

MIT

Unpacked Size

14.1 kB

Total Files

16

Last publish

Collaborators

  • paulmelnikow