Skip to content

Tail-Database/tail-database-terraform

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 

Repository files navigation

Tail Database Terraform

This repo contains Terraform for provisioning the infrastructure behind taildatabase.com.

Cloudflare

Cloudflare is used to provide global object storage and caching without being tied to a single cloud provider.

KV

Each environment (e.g. testnet/mainnet) gets a KV namespace for caching responses without needing to go to R2 for every request.

R2

R2 buckets are created for each environment. The buckets store all asset token data that is displayed on the website. There are also buckets for storing the UI code.

Workers

Cloudflare workers access data in R2 buckets allowing the site to operate like a static website without needing a full node or a database. This completely removes multiple attack vectors and reduces the cost of running the site to $0/month. For comparison, running a full node + DB in AWS can easily cost > $200/month as a base cost before any traffic is taken into account.

The worker scripts are created in TypeScript so compilation is required before Terraform can deploy the scripts to Cloudflare.

About

Terraform for the taildatabase.com website

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published