A Serverless project for exporting CSV data to S3, because trying to get AWS data pipeline working with Aurora was a lot of messing about.
Note that it is somewhat specific to my needs at this time (I'm accessing rows which all have a created_at
column and need data a year at a time), but the basic building blocks might be useful to someone. Maybe?
$ yarn
Coming soon to a computer near you...
$ yarn test
$ serverless invoke local --function exportTable --data '{"table": "<table name>"}'
$ serverless deploy
To add environment variables to your project
- Rename
env.example
toenv.yml
. - Add environment variables for the various stages to
env.yml
. - Uncomment
environment: ${file(env.yml):${self:provider.stage}}
in theserverless.yml
.