iptoasn-webservice/docker
Aaron Gember-Jacobson bdee525553 Update Alpine image version to support Rust version requirement 2024-03-05 19:42:42 +00:00
..
Dockerfile Update Alpine image version to support Rust version requirement 2024-03-05 19:42:42 +00:00
README.md nits 2018-07-18 19:14:05 +02:00
iptoasn-entrypoint.sh Add entrypoint shell script 2017-07-31 20:44:50 +03:00

README.md

How to use

Assume you are in the repo's root folder:

docker build -t iptoasn -f docker/Dockerfile .
docker run -itd \
           --name my-iptoasn \
           -p 80:53661 \
           iptoasn

Wait while iptoasn is downloading data, and then you can do curl requests as you used to:

curl 127.0.0.1:80/v1/as/ip/8.8.8.8

Setting service parameters

Listen port and database URL can be specified by environment variables:

docker run -itd \
           --name my-iptoasn \
           -e IPTOASN_PORT=10000 \
           -e IPTOASN_DBURL='http://your-database-url.com' \
           -p 80:10000 \
           iptoasn

Use as a binary

docker run -it --rm iptoasn --help