https://github.com/web3-storage/autobahn
๐ฃ๏ธ Experimental IPFS HTTP gateway for UnixFS data via CARs.
https://github.com/web3-storage/autobahn
Last synced: about 1 year ago
JSON representation
๐ฃ๏ธ Experimental IPFS HTTP gateway for UnixFS data via CARs.
- Host: GitHub
- URL: https://github.com/web3-storage/autobahn
- Owner: web3-storage
- License: other
- Archived: true
- Created: 2023-05-24T09:55:51.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-19T16:27:47.000Z (almost 3 years ago)
- Last Synced: 2025-02-24T00:28:04.774Z (over 1 year ago)
- Language: JavaScript
- Homepage: https://dev.autobahn.dag.haus
- Size: 90.8 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
autobahn
๐งช Experimental Trustless IPFS HTTP gateway providing access to UnixFS data via CAR CIDs.
How it works:
1. Extract `DATA_CID` from URL.
1. Lookup block index information in DyanmoDB
1. UnixFS export directly from S3 buckets using index data to locate block positions.
The search parameter `?origin` can optionally provide the hint of which CAR file(s) the data DAG is contained within. e.g.
```
https://autobahn.dag.haus/ipfs/bafybeiaaxqlnwlfeirgr5p63ftnfszmerttupnwrim52h4zv2tfpntbjdy/data.txt?origin=bagbaieralsmnkvhi3t3d7lek2ti2vhfglb4bhw7gite2qsz467zjuqvbvyva
```
[Read MOAR](READMOAR.md)
## Getting Started
The repo contains the infra deployment code and the service implementation.
```
โโโ packages - autobahn core and lambda wrapper
โโโ stacks - sst and aws cdk code to deploy all the things
```
To work on this codebase **you need**:
- Node.js >= v18 (prod env is node v18)
- An AWS account with the AWS CLI configured locally
- Copy `.env.tpl` to `.env` and fill in the blanks
- Install the deps with `npm i`
Deploy dev services to your aws account and start dev console. You may need to provide a `--profile` to pick the aws profile to deploy with.
```console
npm start
```
See: https://docs.sst.dev for more info on how things get deployed.
## Environment variables
The following should be set in the env when deploying. Copy `.env.tpl` to `.env` to set in dev.
```sh
SENTRY_DSN=
# Name of the "blocks-cars-position" table in DynamoDB
DYNAMO_TABLE=
# Region of the DynamoDB to query
DYNAMO_REGION=us-west-2
# (optional) CSV of S3 regions of buckets that CAR files are stored in
S3_REGIONS=us-east-1,us-east-2,us-west-2
# (optional) route53 zone name and id for custom domain.
# Create it in route53 and point NS records for it to route53 as needed.
HOSTED_ZONE=autobahn.dag.haus
HOSTED_ZONE_ID=Z09596441DFFYKDGRFNYN
```
## Contributing
Feel free to join in. All welcome. Please read our [contributing guidelines](https://github.com/web3-storage/autobahn/blob/main/CONTRIBUTING.md) and/or [open an issue](https://github.com/web3-storage/autobahn/issues)!
## License
Dual-licensed under [MIT + Apache 2.0](https://github.com/web3-storage/autobahn/blob/main/LICENSE.md)