From 58b22a1e411c45c133fc5a9d53ee775013b42c16 Mon Sep 17 00:00:00 2001 From: Yuval Adam <_@yuv.al> Date: Fri, 17 Nov 2017 16:50:20 +0200 Subject: Unified file structure --- README.md | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 83a1c3e..2e5a50e 100644 --- a/README.md +++ b/README.md @@ -2,27 +2,47 @@ An interactive rain radar clone running on Mapbox GL, see it live at: [https://geshem.space](https://geshem.space) +The entire service is served off of static assets located in S3 buckets: + - A staticmain index page, JS bundle and other static assets that are uploaded upon deploy + - Radar images that collected and indexed every minute by a recurring task running on AWS Lambda + +## Prerequisites + + - Node.js + - Yarn + - Serverless + ## Dev - - Node + Yarn - - Redis (optional, recommended) +### Static Assets Install dependencies: ```bash $ yarn install ``` -Run a local cache: +Build the JS bundle: + ```bash -$ redis-server +$ yarn run build ``` -Run a webpack watch process: +Deploy new static assets to S3: + ```bash -$ webpack --watch +$ yarn run deploy_static ``` -Run the server: +### Cron Task + +#### Deploy + +```bash +$ yarn run deploy_cron +``` + +#### Invoke + ```bash -$ node server.js +$ yarn run invoke_cron ``` -- cgit v1.3.1