Skip to content

Installation with Docker

About

geoip-updater provides automatically updated Docker 🐳 images within several registries:

Registry Image
Docker Hub crazymax/geoip-updater
GitHub Container Registry ghcr.io/crazy-max/geoip-updater

It is possible to always use the latest stable tag or to use another service that handles updating Docker images.

Note

Want to be notified of new releases? Check out 🔔 Diun (Docker Image Update Notifier) project!

Following platforms for this image are available:

$ docker run --rm mplatform/mquery crazymax/geoip-updater:latest
Image: crazymax/geoip-updater:latest
 * Manifest List: Yes
 * Supported platforms:
   - linux/amd64
   - linux/arm/v6
   - linux/arm/v7
   - linux/arm64
   - linux/386
   - linux/ppc64le

This reference setup guides users through the setup based on docker-compose, but the installation of docker-compose is out of scope of this documentation. To install docker-compose itself, follow the official install instructions.

Usage

version: "3.5"

services:
  geoip-updater:
    image: crazymax/geoip-updater:latest
    container_name: geoip-updater
    volumes:
      - "./data:/data"
    environment:
      - "EDITION_IDS=GeoLite2-ASN,GeoLite2-City,GeoLite2-Country"
      - "LICENSE_KEY=0123456789ABCD"
      - "DOWNLOAD_PATH=/data"
      - "SCHEDULE=0 0 * * 0"
      - "LOG_LEVEL=info"
      - "LOG_JSON=false"
    restart: always

Edit this example with your preferences and run the following commands to bring up geoip-updater:

docker-compose up -d
docker-compose logs -f

Or use the following command:

docker run -d --name geoip-updater \
  -e "EDITION_IDS=GeoLite2-ASN,GeoLite2-City,GeoLite2-Country" \
  -e "LICENSE_KEY=0123456789ABCD" \
  -e "DOWNLOAD_PATH=/data" \
  -e "SCHEDULE=0 0 * * 0" \
  -e "LOG_LEVEL=info" \
  -e "LOG_JSON=false" \
  -v "$(pwd)/data:/data" \
  crazymax/geoip-updater:latest

To upgrade your installation to the latest release:

docker-compose pull
docker-compose up -d

Last update: 2021-04-25 01:23:58
Created: 2020-07-23 13:19:07