serverless_hub 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/serverless_hub/handler.rb +4 -3
- data/lib/serverless_hub/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 640d3cc5c64dfdeb422c1a0c2ee11b9456fe847383ae30189cd0a2551cf33b3d
|
4
|
+
data.tar.gz: 47813ad83a3662827c7ea504f463e69f1fa34c8547786abf00ca1d257afd9c68
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0e3cf17b7ba60a949d3eef193f3aacff4bffdaf2a63683c01120f3bec234a9361b1554081fbea8781e64f6213281275d68690bfeda77ee5cc4d54738200b8a88
|
7
|
+
data.tar.gz: 36dfad80e6bb3aa47ab0aa2f6042b97281661c66ae6b73c61b994216522e4e714131c09360ad74480ffa84c7514581d8fa5d9097dc8150e9e920cff10ad1a79f
|
@@ -1,5 +1,6 @@
|
|
1
1
|
if ENV["LAMBDA_TASK_ROOT"].present?
|
2
|
-
|
2
|
+
|
3
|
+
ENV['BUNDLE_GEMFILE'] ||= File.expand_path("#{ENV["LAMBDA_TASK_ROOT"]}/Gemfile.serverless", __dir__) rescue nil
|
3
4
|
|
4
5
|
ENV["RAILS_ENV"] ||= "production"
|
5
6
|
|
@@ -41,10 +42,10 @@ module ServerlessHub
|
|
41
42
|
run app
|
42
43
|
end.to_app
|
43
44
|
|
44
|
-
def self.call(event
|
45
|
+
def self.call(event: {}, context: {})
|
45
46
|
return "Warm Up" if event["source"] == "serverless-plugin-warmup"
|
46
47
|
|
47
|
-
|
48
|
+
Lamby.handler $app, event, context, rack: :api
|
48
49
|
rescue Exception => msg
|
49
50
|
p "errors: #{msg}"
|
50
51
|
response = {
|