https://github.com/mikaelvesavuori/triplecheck-example-cloudflare-workers
TripleCheck broker running on Cloudflare Workers and KV.
https://github.com/mikaelvesavuori/triplecheck-example-cloudflare-workers
consumer-contracts consumer-driven-contracts contract-testing pacts triplecheck
Last synced: about 2 months ago
JSON representation
TripleCheck broker running on Cloudflare Workers and KV.
- Host: GitHub
- URL: https://github.com/mikaelvesavuori/triplecheck-example-cloudflare-workers
- Owner: mikaelvesavuori
- License: mit
- Created: 2021-05-15T17:27:50.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2023-01-07T07:36:05.000Z (over 2 years ago)
- Last Synced: 2025-01-16T16:22:25.570Z (4 months ago)
- Topics: consumer-contracts, consumer-driven-contracts, contract-testing, pacts, triplecheck
- Language: TypeScript
- Homepage:
- Size: 1.08 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: SECURITY.md
Awesome Lists containing this project
README
# triplecheck-example-cloudflare-workers

## TripleCheck broker running on Cloudflare Workers and KV
This repo demonstrates a working, basic implementation of a [TripleCheck broker](https://github.com/mikaelvesavuori/triplecheck-broker) running on Cloudflare Workers with the database being Cloudflare KV.
Refer to the documentation on the [broker](https://github.com/mikaelvesavuori/triplecheck-broker) for how to call the API.
Technology choices are:
- [Node.js](https://nodejs.org/en/)
- [TypeScript](https://www.typescriptlang.org)
- [Cloudflare Wrangler CLI](https://developers.cloudflare.com/workers/get-started/guide) for easing deployment and packaging
- [Webpack](https://webpack.js.org) for bundling## Pre-requisites
- A Cloudflare account
- [Wrangler CLI](https://developers.cloudflare.com/workers/get-started/guide) installed
- Run the `init.sh` script
- Set the bindings presented from the above script in `wrangler.toml`, then rename the file `wrangler dot toml` – the actual file is gitignored so you don't commit any secret values
- Set `zone_id` and `account_id` in `wrangler.toml`, these are easiest found in the web console
- Configure the `custom` block in `serverless.yml` so it uses your own values## Installation
Run `npm install` or `yarn install`.
## Local development
Run `npm start` or `yarn start`.
## Deploy
Run `npm run deploy` or `yarn run deploy`.
## Teardown (remove stack)
There is currently no way to remove a function with the CLI tool – you will have to do this manually in the web console.