sumomo 0.8.1 → 0.8.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/sumomo/cdn.rb +7 -1
- data/lib/sumomo/stack.rb +2 -2
- data/lib/sumomo/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bf070c5bc35c015e9261e284545ff96808650232
|
4
|
+
data.tar.gz: 35f26a5e4ccda0698320ce9e3b711ea81f8eadc0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 897ca7e5600dbaaafd5036756d39c27c877c1350bb8d252efc7a1b85506f18a0599c0e14591609d5a990f9e1a3bd0e33fdc7a415e79863a6d49ac1fd01d4caad
|
7
|
+
data.tar.gz: c57c879584690161552ac1d408929e920aa66ab8a355d8846765e845bd2f1698a30ba1a5117bceece388a10057ce46ae6e68a94fb0ed6843a19dac6b98410b05
|
data/lib/sumomo/cdn.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
|
2
2
|
module Sumomo
|
3
3
|
module Stack
|
4
|
-
def make_cdn_from_dir(domain:, cert:nil, dns:nil, name:nil, dir:, low_ttl: [])
|
4
|
+
def make_cdn_from_dir(domain:, cert:nil, dns:nil, name:nil, dir:, low_ttl: [], lambda_assocs:{})
|
5
5
|
|
6
6
|
bucket_name = @bucket_name
|
7
7
|
|
@@ -84,6 +84,12 @@ module Sumomo
|
|
84
84
|
QueryString "false"
|
85
85
|
Cookies { Forward "none" }
|
86
86
|
}
|
87
|
+
|
88
|
+
LambdaFunctionAssociations (lambda_assocs.map do |event_type,arns|
|
89
|
+
arns.map do |arn|
|
90
|
+
{EventType: event_type, LambdaFunctionARN: arn}
|
91
|
+
end.to_a
|
92
|
+
end.flatten)
|
87
93
|
end
|
88
94
|
|
89
95
|
Logging do
|
data/lib/sumomo/stack.rb
CHANGED
@@ -25,7 +25,7 @@ module Sumomo
|
|
25
25
|
description: "Lambda Function in #{@bucket_name}",
|
26
26
|
function_key: "cloudformation/lambda/function_#{name}",
|
27
27
|
handler: "index.handler",
|
28
|
-
runtime: "
|
28
|
+
runtime: "nodejs8.10",
|
29
29
|
memory_size: 128,
|
30
30
|
timeout: 30,
|
31
31
|
with_statements: [])
|
@@ -131,7 +131,7 @@ module Sumomo
|
|
131
131
|
"Version" => "2012-10-17",
|
132
132
|
"Statement" => [{
|
133
133
|
"Effect" => "Allow",
|
134
|
-
"Principal" => {"Service" => ["lambda.amazonaws.com"]},
|
134
|
+
"Principal" => {"Service" => ["edgelambda.amazonaws.com", "lambda.amazonaws.com"]},
|
135
135
|
"Action" => ["sts:AssumeRole"]
|
136
136
|
}]
|
137
137
|
}
|
data/lib/sumomo/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sumomo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.8.
|
4
|
+
version: 0.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Siaw
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-07-
|
11
|
+
date: 2018-07-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|