1 unstable release
new 0.1.0 | Feb 21, 2025 |
---|
#870 in Network programming
20KB
103 lines
ASN Information Data Uploader
This script fetches the most up-to-date ASN information and saves as JSON or JSONL file and may upload to S3/R2 bucket if environment variables are set.
Install
Using cargo
cargo install asninfo
Using homebrew
on macOS
brew install bgpkit/tap/asninfo
Using cargo-binstall
Install cargo-binstall
first:
cargo install cargo-binstall
Then install asninfo
using cargo binstall
cargo binstall asninfo
Usage
A utility tool to export ASN information to JSON files.
Usage: asninfo [OPTIONS] [PATH]
Arguments:
[PATH] Export data path [default: ./asninfo.jsonl]
Options:
-u, --upload Flag to enable upload to S3-compatible object storage
-s, --simplified Simplified format
-h, --help Print help
-V, --version Print version
S3 upload environment variables
AWS_REGION
AWS_ENDPOINT
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
ASNINFO_UPLOAD_PATH
: full path withs3
orr2
prefix, such asr2://spaces/broker/asninfo.jsonl
Built with ❤️ by BGPKIT Team
Dependencies
~15–27MB
~408K SLoC