trackdown 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6bef9cf45c5eb0f1cebf958c00d8b655d0840b07fe3ae3bca3732e0bdd25e2f8
4
- data.tar.gz: ac99be87d20b6795d7ce156bc9ae50af70e0b4506fa61c00851f5c1abb690e39
3
+ metadata.gz: 07f58b2d8b21b6a7a7a556cb1c5ed24023e751506cc42e630f30fd10c45b1ae4
4
+ data.tar.gz: b307787b7160c444b8ac7e73883e38c8bcd60f8c7d532bb35a12cb9d0c957472
5
5
  SHA512:
6
- metadata.gz: e69d703884469e3880eb06472182e00d356884a92089074a9e4ea916b8709d22bb34de22c8d5d37e16d8aada028099f96e22a2bc2a88c6aa10610a99f04c208b
7
- data.tar.gz: 18c3f1641bcec2facfbefc038d715f434e8a2f9bf5e53b1d83d85ed12d38fa008460bbe936cf47654de2686f6bdb2412fc6a90d2836107e573783e8a9fec435a
6
+ metadata.gz: 8e5a9dee06f9c556d10ed33880fef9ab5f1acc4323367a73ba6721dc492790b03d28ec62ec39a405b8d76f46e3f442a1a5459883cdd3ee7b7dd904e58a811279
7
+ data.tar.gz: 7c2ccb29ec564cd3d70762e2746eb1cc236191687eab91757597f8e6c2074096c91524c1b64bddccef14ac93e712b1f2dbc56854c307f9536b6a24bdfbc1850a
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## [0.1.1] - 2024-10-29
2
+
3
+ - Fix config validationerror on deployment
4
+
1
5
  ## [0.1.0] - 2024-10-29
2
6
 
3
7
  - Initial release
data/README.md CHANGED
@@ -60,7 +60,7 @@ production:
60
60
  refresh_maxmind_database:
61
61
  class: TrackdownDatabaseRefreshJob
62
62
  queue: default
63
- schedule: every day at 4am US/Pacific
63
+ schedule: every week at 4am US/Pacific
64
64
  ```
65
65
 
66
66
  After setting everything up, you can run the following command to update the MaxMind database / get the first fresh copy of it:
@@ -11,6 +11,14 @@ module Trackdown
11
11
  template 'trackdown_database_refresh_job.rb', 'app/jobs/trackdown_database_refresh_job.rb'
12
12
  end
13
13
 
14
+ def add_mmdb_to_gitignore
15
+ if File.exist?('.gitignore')
16
+ append_to_file '.gitignore', "\n\n# Trackdown\n*.mmdb"
17
+ else
18
+ create_file '.gitignore', "# Trackdown\n*.mmdb"
19
+ end
20
+ end
21
+
14
22
  def display_post_install_message
15
23
  say "\tThe `trackdown` gem has been successfully installed!", :green
16
24
  say "\nTo complete the setup:"
@@ -17,33 +17,9 @@ module Trackdown
17
17
  @reject_private_ips = true
18
18
  end
19
19
 
20
- def validate!
21
- missing = []
22
- missing << 'maxmind_license_key' if maxmind_license_key.nil?
23
- missing << 'maxmind_account_id' if maxmind_account_id.nil?
24
-
25
- raise Error, "Missing required configuration: #{missing.join(', ')} – Please set these in your config/initializers/trackdown.rb initializer." unless missing.empty?
26
-
27
- validate_paths!
28
- validate_timeouts!
29
- end
30
-
31
20
  def reject_private_ips?
32
21
  @reject_private_ips
33
22
  end
34
23
 
35
- private
36
-
37
- def validate_paths!
38
- unless database_path && !database_path.empty?
39
- raise Error, "database_path cannot be empty"
40
- end
41
- end
42
-
43
- def validate_timeouts!
44
- raise Error, "timeout must be positive" unless timeout.positive?
45
- raise Error, "pool_timeout must be positive" unless pool_timeout.positive?
46
- raise Error, "pool_size must be positive" unless pool_size.positive?
47
- end
48
24
  end
49
25
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Trackdown
4
- VERSION = "0.1.0"
4
+ VERSION = "0.1.1"
5
5
  end
data/lib/trackdown.rb CHANGED
@@ -19,7 +19,6 @@ module Trackdown
19
19
 
20
20
  def self.configure
21
21
  yield(configuration)
22
- configuration.validate!
23
22
  end
24
23
 
25
24
  def self.locate(ip)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trackdown
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - rameerez