Skip to content

CRON Job that takes weather and puts it in a dynamoDB for storage and processing.

License

Notifications You must be signed in to change notification settings

oharkins/serverless-weather-dynomoDB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AWS Node Scheduled Weather Example

This is an example of creating a function that runs as a cron job using the serverless schedule event. It retrieves weather information every hour and stores it in a DynomDB Database. For more information on schedule event check out the Serverless docs on schedule.

Cron syntax

Read the AWS cron expression syntax docs for more info on how to setup cron

Setup

Install Serverless

Serverless Quick Start

AWS - Credentials

OpenWeatherMap.org

Please visit https://openweathermap.org to register for a free API token.

Configuration

Upon setting up access to both external services, you'll be required to update the environment variables in serverless.yml:

environment:
    WEATHER_APPID: cbf3242865fa6678c01628ab8938d7 <your own WeatherId>

Deploy

In order to deploy the you endpoint simply run

serverless deploy

About

CRON Job that takes weather and puts it in a dynamoDB for storage and processing.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published