mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-06-17 02:27:10 +08:00
This also corrects FileHelper.download so it supports "follow_redirect" correctly (it used to always follow 1 redirect) and adds a `validate_url` param that will bypass all uri validation if set to false (default is true)
12 lines
346 B
Ruby
Vendored
12 lines
346 B
Ruby
Vendored
# frozen_string_literal: true
|
|
|
|
require_dependency 'discourse_ip_info'
|
|
|
|
desc "downloads MaxMind's GeoLite2-City database"
|
|
task "maxminddb:get" do
|
|
puts "Downloading MaxMindDb's GeoLite2-City..."
|
|
DiscourseIpInfo.mmdb_download('GeoLite2-City')
|
|
|
|
puts "Downloading MaxMindDb's GeoLite2-ASN..."
|
|
DiscourseIpInfo.mmdb_download('GeoLite2-ASN')
|
|
end
|