thecore_background_jobs 3.0.7 → 3.0.9

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: c0f2ec50c3d53b14587cc8c1adeaa4b5db83418e047c44b5a151ed86822aa20d
4
- data.tar.gz: 3e4bea08d6d4c70bbe18f6c1e8084c0cb6a485e0842062e32177906ad30792ec
3
+ metadata.gz: a4caaa36480a3111cb9d07ef76785a20ee874f7da1227e37a52cfc615959ac26
4
+ data.tar.gz: 70014f705d76e4f486fd9e978f440aa3a0a4c7eadcc9c810ff33063d6ee589f6
5
5
  SHA512:
6
- metadata.gz: 944eae6b4e8df60178fe0db6f5938e9fe6c1af33cdb6ea7c6c63d1b0fd7d98fd3ca44b76fec8a483232057b3a939f433baaf45ca46588731a5d681a262ead66a
7
- data.tar.gz: 4087e376d6301d26401dc3deff1b51c7e9987aef9a6492d43cb315e99ee36911bbbdc100fa226c8d03937b0971292fdb74a53942e9c63ae71de37b0eeed4cc85
6
+ metadata.gz: 65ad516accdb68e64c40fce5495706e67422abdd0d2001c55c675da06830fdcfa3604b80de366f68546b8751148c98a9c2ee892343d3ae56f3ff5c84cecffe1d
7
+ data.tar.gz: 5ff3cc5cab944d6ca6fbfc7c1d543d97faf493129f8584789172671bdc6629aeb55dabf9a40760f09177d61e61c4cab5d5570d62786fdc10cd7018c801c3452b
data/README.md CHANGED
@@ -1,28 +1 @@
1
- # ThecoreBackgroundJobs
2
- Short description and motivation.
3
-
4
- ## Usage
5
- How to use my plugin.
6
-
7
- ## Installation
8
- Add this line to your application's Gemfile:
9
-
10
- ```ruby
11
- gem "thecore_background_jobs"
12
- ```
13
-
14
- And then execute:
15
- ```bash
16
- $ bundle
17
- ```
18
-
19
- Or install it yourself as:
20
- ```bash
21
- $ gem install thecore_background_jobs
22
- ```
23
-
24
- ## Contributing
25
- Contribution directions go here.
26
-
27
- ## License
28
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
1
+ This is part of Thecore framework: https://github.com/gabrieletassoni/thecore/tree/release/3
data/config/routes.rb CHANGED
@@ -4,6 +4,6 @@ Rails.application.routes.draw do
4
4
 
5
5
  # Allow any authenticated User with admin capability
6
6
  authenticate :user, lambda { |u| u.admin? } do
7
- mount Sidekiq::Web => '/sidekiq'
7
+ mount Sidekiq::Web => '/sidekiq', scope: ENV.fetch("RAILS_RELATIVE_URL_ROOT", "/")
8
8
  end
9
9
  end
@@ -1,3 +1,3 @@
1
1
  module ThecoreBackgroundJobs
2
- VERSION = "3.0.7"
2
+ VERSION = "3.0.9"
3
3
  end
@@ -7,11 +7,25 @@ require "thecore_background_jobs/engine"
7
7
  module ThecoreBackgroundJobs
8
8
  # Your code goes here...
9
9
  def self.email_setup
10
- delivery_options = { domain: Settings.ns(:smtp).domain, address: Settings.ns(:smtp).address, port: Settings.ns(:smtp).port.to_i, enable_starttls_auto: (Settings.ns(:smtp).enable_starttls_auto == "true")}
10
+ # Fill variables with the correct values
11
+ domain = ThecoreSettings::Setting.where(ns: :smtp, key: :domain).first.raw
12
+ address = ThecoreSettings::Setting.where(ns: :smtp, key: :address).first.raw
13
+ port = ThecoreSettings::Setting.where(ns: :smtp, key: :port).first.raw.to_i
14
+ enable_starttls_auto = ThecoreSettings::Setting.where(ns: :smtp, key: :enable_starttls_auto).first.raw == "true"
15
+ user_name = ThecoreSettings::Setting.where(ns: :smtp, key: :user_name).first.raw
16
+ password = ThecoreSettings::Setting.where(ns: :smtp, key: :password).first.raw
17
+ authentication = ThecoreSettings::Setting.where(ns: :smtp, key: :authentication).first.raw
18
+
19
+ delivery_options = {
20
+ domain: domain,
21
+ address: address,
22
+ port: port,
23
+ enable_starttls_auto: enable_starttls_auto
24
+ }
11
25
  # Other Options
12
- delivery_options.merge!({user_name: Settings.ns(:smtp).user_name}) unless Settings.ns(:smtp).user_name.blank?
13
- delivery_options.merge!({password: Settings.ns(:smtp).password}) unless Settings.ns(:smtp).password.blank?
14
- delivery_options.merge!({authentication: Settings.ns(:smtp).authentication}) unless Settings.ns(:smtp).authentication.blank?
26
+ delivery_options.merge!({user_name: user_name}) unless user_name.blank?
27
+ delivery_options.merge!({password: password}) unless password.blank?
28
+ delivery_options.merge!({authentication: authentication}) unless authentication.blank? || authentication == "none"
15
29
  delivery_options
16
30
  end
17
31
 
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thecore_background_jobs
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.7
4
+ version: 3.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gabriele Tassoni
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2023-06-13 00:00:00.000000000 Z
10
+ date: 2025-01-16 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: redis-namespace
@@ -93,7 +92,6 @@ metadata:
93
92
  homepage_uri: https://github.com/gabrieletassoni/thecore_background_jobs
94
93
  source_code_uri: https://github.com/gabrieletassoni/thecore_background_jobs
95
94
  changelog_uri: https://github.com/gabrieletassoni/thecore_background_jobs/blob/master/CHANGELOG.md
96
- post_install_message:
97
95
  rdoc_options: []
98
96
  require_paths:
99
97
  - lib
@@ -108,8 +106,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
108
106
  - !ruby/object:Gem::Version
109
107
  version: '0'
110
108
  requirements: []
111
- rubygems_version: 3.4.10
112
- signing_key:
109
+ rubygems_version: 3.6.2
113
110
  specification_version: 4
114
111
  summary: Background workers for Thecore
115
112
  test_files: []