souls 1.21.8 → 1.22.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bf225b8fb6383d37d0557dc336cf837066f80b2f9053f6cbf5710e5664a48206
|
4
|
+
data.tar.gz: 74a2b152293eb1aa547756f6abc50ba3937f451fc895215ced1c1c97719d485f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b412b04e1a4d1bc5a286ea2329ab416a5a94dbd285e9f9047b077d0a056c70bf577c702c4c0f5a051dbbf8879f50b878c506779ab6bb894226bf43b9547759c0
|
7
|
+
data.tar.gz: 729ab0de6a94f82469b8df9103740d03e671d26ecc6b42db217a947e0445f550e0a59e1725494f5e274040219155e82f5d18be596164b2dc5671459741e31f68
|
@@ -28,11 +28,16 @@ module SOULs
|
|
28
28
|
end
|
29
29
|
|
30
30
|
def souls_fb_auth(token: "")
|
31
|
+
raise(ArgumentError, "Invalid or Missing Token") if token.blank?
|
32
|
+
|
31
33
|
FirebaseIdToken::Certificates.request!
|
32
|
-
sleep(3)
|
33
34
|
user = FirebaseIdToken::Signature.verify(token)
|
34
|
-
|
35
|
-
|
35
|
+
if user.blank?
|
36
|
+
Retryable.retryable(tries: 20, on: ArgumentError) do
|
37
|
+
user = FirebaseIdToken::Signature.verify(token)
|
38
|
+
raise(ArgumentError, "Invalid or Missing Token") if user.blank?
|
39
|
+
end
|
40
|
+
end
|
36
41
|
user
|
37
42
|
end
|
38
43
|
|
@@ -3,7 +3,8 @@ module SOULs
|
|
3
3
|
desc "awake [url]", "Set Ping by Google Cloud Scheduler: Cron e.g. '0 10 * * *' or 'every 10 hours'"
|
4
4
|
def awake
|
5
5
|
app_name = SOULs.configuration.app.gsub("_", "-")
|
6
|
-
|
6
|
+
project_id = SOULs.configuration.project_id
|
7
|
+
worker_names = SOULs.configuration.workers.map { |f| f[:name] }
|
7
8
|
services = ["souls-#{app_name}-api"]
|
8
9
|
worker_names.each { |worker| services << "souls-#{app_name}-#{worker}" }
|
9
10
|
|
@@ -11,10 +12,10 @@ module SOULs
|
|
11
12
|
service = prompt.select("Select Service?", services)
|
12
13
|
cron = prompt.ask("Cron Schedule?", default: "every 10 mins")
|
13
14
|
|
14
|
-
url = SOULs::
|
15
|
+
url = SOULs::CloudRun.new.get_endpoint(service)
|
15
16
|
system(
|
16
17
|
"gcloud scheduler jobs create http #{app_name}-awake \
|
17
|
-
--schedule '#{cron}' --uri #{url} --http-method GET"
|
18
|
+
--schedule '#{cron}' --uri '#{url}' --project=#{project_id} --http-method GET"
|
18
19
|
)
|
19
20
|
end
|
20
21
|
|
data/lib/souls/version.rb
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.22.0
|
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.22.0
|
data/lib/souls.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: souls
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.22.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- POPPIN-FUMI
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date: 2022-
|
13
|
+
date: 2022-02-11 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activesupport
|
@@ -138,6 +138,20 @@ dependencies:
|
|
138
138
|
- - ">="
|
139
139
|
- !ruby/object:Gem::Version
|
140
140
|
version: 2.8.3
|
141
|
+
- !ruby/object:Gem::Dependency
|
142
|
+
name: retryable
|
143
|
+
requirement: !ruby/object:Gem::Requirement
|
144
|
+
requirements:
|
145
|
+
- - ">="
|
146
|
+
- !ruby/object:Gem::Version
|
147
|
+
version: 3.0.5
|
148
|
+
type: :runtime
|
149
|
+
prerelease: false
|
150
|
+
version_requirements: !ruby/object:Gem::Requirement
|
151
|
+
requirements:
|
152
|
+
- - ">="
|
153
|
+
- !ruby/object:Gem::Version
|
154
|
+
version: 3.0.5
|
141
155
|
- !ruby/object:Gem::Dependency
|
142
156
|
name: thor
|
143
157
|
requirement: !ruby/object:Gem::Requirement
|