serverless_hub 1.0.0 → 1.0.1
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 +15 -1
- 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: 0e483461afb6cd5669c76204595b56d195a7064d157cd4b89edea100e8657264
|
4
|
+
data.tar.gz: 9ed76e35c6c7d014bf41c99a96b09df8f7bb95f503d9fc387660ae622a7c3b9e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 523be73ee0075a87fa3ddcc1bbdd32b1a43dbcf1c601b2ee5b8a86b5f685a472ae52fb1954965bcfc1bcc1407634cb68f4bc19fba85138ab1c5224d333cdb9ff
|
7
|
+
data.tar.gz: f4a53565f47037ce26ba9f54e2d17338aae845a4709bf27017bbe1b551ab460842d17ac77424d1cd13bcabcc7eb7cb18c1ed74a41de14f31ee3d9daafa464e63
|
@@ -1,4 +1,18 @@
|
|
1
|
-
|
1
|
+
if ENV["LAMBDA_TASK_ROOT"].present?
|
2
|
+
ENV["RAILS_ENV"] ||= "production"
|
3
|
+
|
4
|
+
require "bundler"
|
5
|
+
Bundler.setup(:default, ENV["RAILS_ENV"])
|
6
|
+
|
7
|
+
require "active_record"
|
8
|
+
|
9
|
+
Bundler.require(:default, ENV["RAILS_ENV"])
|
10
|
+
|
11
|
+
ActiveSupport::Dependencies.autoload_paths += Dir[ "#{ENV["LAMBDA_TASK_ROOT"]}/app/**" ]
|
12
|
+
|
13
|
+
ActiveRecord::Base.configurations = {}
|
14
|
+
ActiveRecord::Base.establish_connection(ActiveRecord::Base.configurations[ENV["RAILS_ENV"]])
|
15
|
+
end
|
2
16
|
|
3
17
|
class DefaultApiEntry
|
4
18
|
def self.call(env)
|