jets 1.5.0 → 1.5.1

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: a211d70b05e7db0a0a74d1432901a395bf86270671bd52444d61578320e7dea3
4
- data.tar.gz: 4f4ea63695bdb6230e9c40877911e476e6d0e35265089168920e3bad812b86e2
3
+ metadata.gz: 6885ae6e6c06e0dc4815590b04ddc1e7e969d214529bdc4ba50491d8bc9a1c6d
4
+ data.tar.gz: 619992a70dfef925eaccbd72f0d8b75755fd7be95633b34195230b5af1c7a9d3
5
5
  SHA512:
6
- metadata.gz: 0c951b27085d1a76cca87e843332f473407b9d45e0bce93ea7fa8b668130a61e559c6f1273840d82c1874232b9fa933789bfe05a54323a9d94503da8bbfe3364
7
- data.tar.gz: 4095238a2422f3f61df81fd14d3804f4040dde12ae290beeff89d079914f5d86038d20d1f9d4fd88a9ec1fc13b6f423bbf6b6ea7c22c8808fe97c4a3507ff474
6
+ metadata.gz: 20d3ea20af1a36c7faf4d224350b15fcbbb7892469e2976e129746a7768b6f10e500791ed5c4076beebad09e2db03a456e03ebaee7077fe95c7fdf5925348629
7
+ data.tar.gz: 1372624f0be64e02884e0524abcfadefcc1a76d644e28b77b4d8566e4330e64bf14e28b7f676b49ac923aefbacd11fb58b7b6155e301dee7990a59badef52cf2
@@ -3,6 +3,9 @@
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
+ ## [1.5.1]
7
+ - #137 from tongueroo/gems-check bypass gems check exit for custom lambda layers
8
+
6
9
  ## [1.5.0]
7
10
  - #135 from tongueroo/remove-rails-constant Remove Rails Constant
8
11
  - #136 from tongueroo/routes-namespace routes namespace support (ghost release, not documented yet on purpose)
@@ -11,7 +11,7 @@ GIT
11
11
  PATH
12
12
  remote: .
13
13
  specs:
14
- jets (1.5.0)
14
+ jets (1.5.1)
15
15
  activerecord (>= 5.2.1)
16
16
  activesupport (>= 5.2.1)
17
17
  aws-sdk-apigateway
@@ -7,9 +7,14 @@ class Jets::Builders
7
7
 
8
8
  def run
9
9
  check = Jets::Gems::Check.new
10
- found_gems = check.run! # exits early if missing gems found
10
+ if Jets.config.lambda.layers.empty?
11
+ found_gems = check.run! # exits early if missing gems found
12
+ else
13
+ # assumes missing gems are in the provided custom layer by the user
14
+ found_gems = check.run # does not exist early
15
+ end
11
16
 
12
- # Reaching here means its safe to download and extract the gems
17
+ # found gems will only have gems that were found
13
18
  found_gems.each do |gem_name, source|
14
19
  options = @options.merge(source_url: source)
15
20
  gem_extractor = Jets::Gems::Extract::Gem.new(gem_name, options)
@@ -1,3 +1,3 @@
1
1
  module Jets
2
- VERSION = "1.5.0"
2
+ VERSION = "1.5.1"
3
3
  end
@@ -36,4 +36,4 @@ DEPENDENCIES
36
36
  rspec (~> 3.0)
37
37
 
38
38
  BUNDLED WITH
39
- 1.16.3
39
+ 1.17.2
@@ -11,6 +11,10 @@ module Jets::Gems
11
11
  @missing_gems = [] # keeps track of gems that are not found in any of the lambdagems sources
12
12
  end
13
13
 
14
+ def run!
15
+ run(exit_early: true)
16
+ end
17
+
14
18
  # Checks whether the gem is found on at least one of the lambdagems sources.
15
19
  # By the time the loop finishes, found_gems will hold a map of gem names to found
16
20
  # url sources. Example:
@@ -20,7 +24,7 @@ module Jets::Gems
20
24
  # "pg-0.21.0" => "https://anothersource.com",
21
25
  # }
22
26
  #
23
- def run!
27
+ def run(exit_early: false)
24
28
  puts "Checking projects gems for binary Lambda gems..."
25
29
  found_gems = {}
26
30
  compiled_gems.each do |gem_name|
@@ -41,12 +45,11 @@ module Jets::Gems
41
45
  end
42
46
  end
43
47
 
44
- unless @missing_gems.empty?
48
+ if exit_early && !@missing_gems.empty?
45
49
  # Exits early if not all the linux gems are available.
46
50
  # Better to error now than deploy a broken package to AWS Lambda.
47
51
  # Provide users with message about using their own lambdagems source.
48
52
  puts missing_message
49
-
50
53
  Report.missing(@missing_gems) if agree.yes?
51
54
  exit 1
52
55
  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: 1.5.0
4
+ version: 1.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tung Nguyen