1.0.0 • Published 6 months ago
ace-spades v1.0.0
Ace Spades
Project with lambdas to handle with Cyan's main database.
Dependencies
Setup
git clone git@bitbucket.org:modclima/ace-spades.git
cd ace-spades
yarn install
ENVIRONMENT VARIABLES
. RABBITMQ_URL (Required): You need the RABBITMQ_URL to deploy.
. WASABI_ACCESS_KEY_ID (Required): Wasabi key ID to connect to access Wasabi buckets.
. WASABI_SECRET_ACCESS_KEY (Required): Wasabi password to access Wasabi buckets.
Deploy
This script uses the same environment variables as libpq to connect to a PostgreSQL server.
To deploy, have your aws settings configured, environment variables, and use:
STAGE=dev
PGHOST=database....
PGDATABASE=....
PGUSER=...
PGPASSWORD=...
PGPORT=121..
RABBITMQ_URL=amqp://project:.....
WASABI_ACCESS_KEY_ID=...
WASABI_SECRET_ACCESS_KEY=...
yarn run deploy [OPTIONS]
Tests
Local tests, Full tests and test coverage
To test lambda offline
yarn run dev
and call the api
curl -X GET http://localhost:3000/crops/{cropId}/crop-front
To run all test use command below:
yarn test
Unit tests and watch for changes
yarn run unit-test
License
© 2021 CYAN AGROANALYTICS ALL RIGHTS RESERVED
1.0.0
6 months ago