https://github.com/tobilg/serverless-cubejs
Serverless Cube.js backend infrastructure on AWS
https://github.com/tobilg/serverless-cubejs
athena aurora cubejs serverless
Last synced: 4 months ago
JSON representation
Serverless Cube.js backend infrastructure on AWS
- Host: GitHub
- URL: https://github.com/tobilg/serverless-cubejs
- Owner: tobilg
- License: mit
- Created: 2020-08-20T11:37:34.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-12-12T11:26:41.000Z (over 4 years ago)
- Last Synced: 2023-02-26T19:16:38.046Z (about 2 years ago)
- Topics: athena, aurora, cubejs, serverless
- Language: JavaScript
- Homepage:
- Size: 68.4 KB
- Stars: 17
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# serverless-cubejs
Serverless Cube.js backend infrastructure on AWS.## Architecture
This project uses
* API Gateway HTTP APIs for hosting the Cube.js backend API
* Athena for querying data in S3
* Aurora Serverless for pre-aggregations
* ElastiCache for query result cachingAll of that runs in a preconfigured VPC. You can also have a look at the stack diagram in [docs/stack.drawio](docs/stack.drawio).
AWS pricing applies, please make yourself familiar with the pricing of the deployed resources **BEFORE** you deploy the stack. This will not be covered by the AWS Free Tier!
## Usage
### Prerequisites
You'll need an AWS account (obviously), and a readily installed [Serverless framework](https://www.serverless.com), along with local AWS credentials.
### Cube configuration
You need to adapt (or add) the schemas for your cube in the [schema](schema/) folder appropriately (see [Cube.js docs](https://cube.dev/docs/cube)).
### Deployment
```bash
$ sls deploy --aurora-password YOUR_AURORA_PASSWORD --s3-data-bucket YOUR_S3_BUCKET_NAME --cube-secret YOUR_CUBE_SECRET
```The default stage that will be used is `dev`. You can also specify if via the `--stage` commandline option.
### Removal
```bash
$ sls remove
```It's possible that you have to manually clean some resources, e.g. the S3 bucket with the Athena query results.