root: add geoip config to docker-compose
This commit is contained in:
@ -20,7 +20,7 @@ To optionally deploy a different version run `echo AUTHENTIK_TAG=2021.3.3 >> .en
|
||||
|
||||
If this is a fresh authentik install run the following commands to generate a password:
|
||||
|
||||
```
|
||||
```shell
|
||||
sudo apt-get install -y pwgen
|
||||
echo "PG_PASS=$(pwgen 40 1)" >> .env
|
||||
echo "AUTHENTIK_SECRET_KEY=$(pwgen 50 1)" >> .env
|
||||
@ -32,7 +32,7 @@ It is also recommended to configure global email credentials. These are used by
|
||||
|
||||
Append this block to your `.env` file
|
||||
|
||||
```
|
||||
```shell
|
||||
# SMTP Host Emails are sent to
|
||||
AUTHENTIK_EMAIL__HOST=localhost
|
||||
AUTHENTIK_EMAIL__PORT=25
|
||||
@ -48,11 +48,27 @@ AUTHENTIK_EMAIL__TIMEOUT=10
|
||||
AUTHENTIK_EMAIL__FROM=authentik@localhost
|
||||
```
|
||||
|
||||
## GeoIP configuration (optional)
|
||||
|
||||
authentik can use a MaxMind-formatted GeoIP Database to extract location data from IPs. You can then use this location data in policies, and location data is saved in events.
|
||||
|
||||
To configure GeoIP, sign up for a free MaxMind account [here](https://www.maxmind.com/en/geolite2/signup).
|
||||
|
||||
After you have your account ID and license key, add the following block to your `.env` file:
|
||||
|
||||
```shell
|
||||
GEOIPUPDATE_ACCOUNT_ID=*your account ID*
|
||||
GEOIPUPDATE_LICENSE_KEY=* your license key*
|
||||
AUTHENTIK_AUTHENTIK__GEOIP=/geoip/GeoLite2-City.mmdb
|
||||
```
|
||||
|
||||
The GeoIP database will automatically be updated every 8 hours.
|
||||
|
||||
## Startup
|
||||
|
||||
Afterwards, run these commands to finish
|
||||
|
||||
```
|
||||
```shell
|
||||
docker-compose pull
|
||||
docker-compose up -d
|
||||
docker-compose run --rm server migrate
|
||||
|
Reference in New Issue
Block a user