-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: replaced tronovav/geoip2-update
- Loading branch information
Showing
8 changed files
with
121 additions
and
135 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,59 @@ | ||
<?php | ||
|
||
return [ | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| GeoLite2 Token | ||
| GeoIP Driver Type | ||
|-------------------------------------------------------------------------- | ||
| | ||
| Licence key needed to retrieve the lastest GeoLite2 Country database. | ||
| To get yours, simply register to: | ||
| https://dev.maxmind.com/geoip/geolite2-free-geolocation-data | ||
| Supported: "ip-api", "maxmind_database", "maxmind_api" | ||
| | ||
*/ | ||
'driver' => env('GEOIP_DRIVER', 'maxmind_database'), | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Return random ipaddresses (useful for dev envs) | ||
|-------------------------------------------------------------------------- | ||
*/ | ||
'random' => env('GEOIP_RANDOM', false), | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| IP-API Driver | ||
|-------------------------------------------------------------------------- | ||
*/ | ||
'ip-api' => [ | ||
// Check out pro here: https://signup.ip-api.com/ | ||
'key' => env('GEOIP_IPAPI_KEY'), | ||
'lang' => env('GEOIP_IPAPI_LANG'), | ||
], | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Maxmind Database Driver | ||
|-------------------------------------------------------------------------- | ||
*/ | ||
'maxmind_database' => [ | ||
// Example: app_path().'/database/maxmind/GeoLite2-City.mmdb' | ||
// 'database' => base_path().'/'.env('GEOIP_MAXMIND_DATABASE', 'database/geoip/GeoLite2-City.mmdb'), | ||
'database' => storage_path('app'). '/' . 'GeoLite2-City.mmdb', | ||
|
||
'geoip_token' => env('GEOIP_TOKEN'), | ||
// The license key is required for database updates | ||
'license_key' => env('GEOIP_TOKEN'), | ||
], | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Maxmind Api Driver | ||
|-------------------------------------------------------------------------- | ||
*/ | ||
'maxmind_api' => [ | ||
'user_id' => env('GEOIP_MAXMIND_USER_ID'), | ||
'license_key' => env('GEOIP_MAXMIND_LICENSE_KEY'), | ||
//maxmind api will default to paid service. Use 'geolite.info' for free GeoLite2 Web service. https://github.com/maxmind/GeoIP2-php#usage-1 | ||
'host' => env('GEOIP_MAXMIND_HOST'), | ||
//local required on client call but defaults to 'en' for english. | ||
'locales' => ['en'], | ||
], | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters