jets 0.10.1 → 0.10.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3831bca90084f7a67e71a09765d320e8be408b50a6dbc16daba01ffc0cfadf2a
4
- data.tar.gz: 98c96cac69d5c85ae965609e18294d270be098362b8911e84f936d33f31b230a
3
+ metadata.gz: 004fd07357a95e0e3510618961b5a6f34519ef3a63d8a701495cfdd778dbf0ae
4
+ data.tar.gz: 42f440db1cedab8d1fd125e2982bc3e1a4f142bce303cbdcab3ef4708c46c896
5
5
  SHA512:
6
- metadata.gz: c7e5c6646d2253b6d497562ee823544b21eb067ecdcce6e3791ad16c98aec23055c24e805020dbd3660e360000d54920c7c42025c7a7521c81cd1ebc24ae0647
7
- data.tar.gz: 76429beaecd48a4786c97de85518148b271ea29cd97f97a752ba3e5fa603de439f0642f0e959664f22d3cb76703f25d528303bf69adba477138440e606f25b59
6
+ metadata.gz: df31a2191ad694d664527d0fe2ab07d0e6d7f63193798ad5ccd06230ce6ed936cdef4350befd8d85b7f64a5ad2e8f02aa9ae813e467a0f3dd3a1497d666f95de
7
+ data.tar.gz: 071f98800a1e24d70390baec349ecf91111932c002e03f7ad63cd9f0605260d0d69cdbaf609af960e70db2e118133b07592e7e24477eab0fae6f83ddae224b54
data/CHANGELOG.md CHANGED
@@ -3,6 +3,11 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  This project *loosely tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
5
5
 
6
+ ## [0.10.2]
7
+ - fix cloudformation config rule permission race condition with depends on
8
+ - simplify --templates only cli option
9
+ - update config rules docs
10
+
6
11
  ## [0.10.1]
7
12
  - clear @associated_properties bug
8
13
  - fix jets new . , Merge pull request #46 from tongueroo/jets-new-dot
@@ -21,11 +26,12 @@ This project *loosely tries* to adhere to [Semantic Versioning](http://semver.or
21
26
  - fix iam policies: flatten
22
27
 
23
28
  ## [0.9.0]
24
- - Remove class name from the namespace. So namespace only has method name now. NOTE: This means upgrading from 0.8.x to 0.9.x requires a blue-green update.
25
- - Add upgrading docs.
29
+ - Pretty big update: introduce concept of Shared Resources and Stack DSL
26
30
  - Stack DSL: To support the concept of Custom Shared Resources. Supports extensions and simple functions also.
27
31
  - Stack DSL: Allow for control of DependsOn attribute.
28
32
  - Stack DSL: `MyStack.lookup` method
33
+ - Remove class name from the namespace. So namespace only has method name now. NOTE: This means upgrading from 0.8.x to 0.9.x requires a blue-green update.
34
+ - Add upgrading docs.
29
35
  - Associated resource extensions support
30
36
  - Associated resources multiple form support: long, medium, short
31
37
  - Add `jets new --mode`: 3 modes: html, api, job. Remove the `--api`
data/Gemfile.lock CHANGED
@@ -11,7 +11,7 @@ GIT
11
11
  PATH
12
12
  remote: .
13
13
  specs:
14
- jets (0.10.1)
14
+ jets (0.10.2)
15
15
  actionpack (>= 5.2.1)
16
16
  actionview (>= 5.2.1)
17
17
  activerecord (>= 5.2.1)
@@ -10,7 +10,7 @@ class Jets::Cfn::Builders
10
10
 
11
11
  # compose is an interface method
12
12
  def compose
13
- return unless @options[:full] || @options[:stack_type] != :minimal
13
+ return unless @options[:templates] || @options[:stack_type] != :minimal
14
14
 
15
15
  deployment = Jets::Resource::ApiGateway::Deployment.new
16
16
  add_resource(deployment)
@@ -10,7 +10,7 @@ class Jets::Cfn::Builders
10
10
 
11
11
  # compose is an interface method
12
12
  def compose
13
- return unless @options[:full] || @options[:stack_type] != :minimal
13
+ return unless @options[:templates] || @options[:stack_type] != :minimal
14
14
 
15
15
  add_gateway_rest_api
16
16
  add_gateway_routes
@@ -15,7 +15,7 @@ class Jets::Cfn::Builders
15
15
  puts "Building parent CloudFormation template."
16
16
 
17
17
  build_minimal_resources
18
- build_child_resources if @options[:full] || @options[:stack_type] == :full
18
+ build_child_resources if @options[:templates] || @options[:stack_type] == :full
19
19
  end
20
20
 
21
21
  # template_path is an interface method
@@ -53,7 +53,7 @@ class Jets::Cfn::Builders
53
53
  add_shared_resources(path)
54
54
  end
55
55
 
56
- if (@options[:full] || @options[:stack_type] == :full) and !Jets::Router.routes.empty?
56
+ if (@options[:templates] || @options[:stack_type] == :full) and !Jets::Router.routes.empty?
57
57
  add_api_gateway
58
58
  add_api_deployment
59
59
  end
@@ -20,7 +20,7 @@ module Jets::Commands
20
20
  time :run
21
21
 
22
22
  def build
23
- build_code unless @options[:templates_only]
23
+ build_code unless @options[:templates]
24
24
  build_templates
25
25
  end
26
26
  time :build
@@ -31,7 +31,7 @@ module Jets::Commands
31
31
  time :build_code
32
32
 
33
33
  def build_templates
34
- if @options[:full] || @options[:stack_type] == :full
34
+ if @options[:templates] || @options[:stack_type] == :full
35
35
  build_all_templates
36
36
  else
37
37
  build_minimal_template
@@ -7,8 +7,7 @@ module Jets::Commands
7
7
 
8
8
  desc "build", "Builds and packages project for AWS Lambda"
9
9
  long_desc Help.text(:build)
10
- option :templates_only, type: :boolean, default: false, desc: "provide a way to skip building the code and only build the CloudFormation templates"
11
- option :full, type: :boolean, default: false, desc: "For a fake full build even if the stack does not exist"
10
+ option :templates, type: :boolean, default: false, desc: "Only build the CloudFormation templates. Skip code building"
12
11
  def build
13
12
  Build.new(options).run
14
13
  end
@@ -7,12 +7,20 @@ module Jets::Resource::Config
7
7
  end
8
8
 
9
9
  def definition
10
- {
10
+ base = {
11
11
  config_rule_logical_id => {
12
12
  type: "AWS::Config::ConfigRule",
13
- properties: definition_properties,
13
+ properties: definition_properties
14
14
  }
15
15
  }
16
+
17
+ # Explicitly set depends_on to help with CloudFormation random race condition.
18
+ # Seems to be a new CloudFormation and AWS Config resource issue.
19
+ if definition_properties[:source][:owner] == 'CUSTOM_LAMBDA'
20
+ base[config_rule_logical_id][:depends_on] = "{namespace}Permission"
21
+ end
22
+
23
+ base
16
24
  end
17
25
 
18
26
  # Do not name this method properties, that is a computed method of `Jets::Resource::Base`
data/lib/jets/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Jets
2
- VERSION = "0.10.1"
2
+ VERSION = "0.10.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.1
4
+ version: 0.10.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tung Nguyen