jets 1.1.2 → 1.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/Gemfile.lock +1 -1
- data/lib/jets/application.rb +17 -13
- data/lib/jets/commands/build.rb +18 -1
- data/lib/jets/commands/sequence.rb +9 -0
- data/lib/jets/turbine.rb +3 -0
- data/lib/jets/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0e2ca4e1e46c54d0900404bd31e09e0d142a2e1b15452e680a1ca61caec0c11
|
4
|
+
data.tar.gz: f299c7812a68de607e111195649b948c7099055ebb7db250c351807828ad38ca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 50812ce230aad0e1fa837152dcf69ad53436772ce2c4339f1b2e868efe182ae9af7bec4c2f5dc8efc9d86ebd2f0857f3bc8c6dc0faedb4822af2b69c9636cea7
|
7
|
+
data.tar.gz: a34ff0de3463ec1db9f4cab3f5f9372de2211c2efa6eb0888a0c680755605b4d82e8843553e9bfca484cf056046b57b7dc36a5d054aba94a47d6dc1bd2641094
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,13 @@
|
|
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.1.3]
|
7
|
+
- Merge pull request #79 from tongueroo/misc-fixes
|
8
|
+
- fix has_poly? check to account for shared functions
|
9
|
+
- fix jets new mode job copy_options
|
10
|
+
- fix Jets Turbine require active support fixes issue #78
|
11
|
+
- parse for project name as workaround to avoid double loading config/application.rb
|
12
|
+
|
6
13
|
## [1.1.2]
|
7
14
|
- Add option to specify authorization type application-wide option and on a per-route basis.
|
8
15
|
- Add option to specify endpoint type of the ApiGateway: config.api.endpoint_type option
|
data/Gemfile.lock
CHANGED
data/lib/jets/application.rb
CHANGED
@@ -85,28 +85,32 @@ class Jets::Application
|
|
85
85
|
config
|
86
86
|
end
|
87
87
|
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
88
|
+
# Double evaling config/application.rb causes subtle issues:
|
89
|
+
# * double loading of shared resources: Jets::Stack.subclasses will have the same
|
90
|
+
# class twice when config is called when declaring a function
|
91
|
+
# * forces us to rescue all exceptions, which is a big hammer
|
92
|
+
#
|
93
|
+
# Lets parse for the project name instead for now.
|
94
|
+
#
|
95
|
+
def parse_project_name
|
96
|
+
lines = IO.readlines("#{Jets.root}config/application.rb")
|
97
|
+
project_name_line = lines.find { |l| l =~ /project_name/ }
|
98
|
+
project_name_line.gsub(/.*=/,'').strip.gsub(/["']/,'') # project_name
|
99
|
+
end
|
95
100
|
|
101
|
+
def load_app_config
|
102
|
+
project_name = parse_project_name
|
103
|
+
@config = default_config(project_name)
|
96
104
|
set_dependent_configs! # things like project_namespace that need project_name
|
97
|
-
|
98
|
-
# Running eval_app_config the second time, hack to solve the chicken-and-egg problem
|
99
105
|
eval_app_config
|
100
106
|
|
101
107
|
set_iam_policy # relies on dependent values, must be called afterwards
|
102
108
|
normalize_env_vars!
|
103
109
|
end
|
104
110
|
|
105
|
-
def eval_app_config
|
111
|
+
def eval_app_config
|
106
112
|
app_config = "#{Jets.root}config/application.rb"
|
107
|
-
|
108
|
-
rescue NoMethodError => e
|
109
|
-
raise(e) unless squash_exception
|
113
|
+
require app_config
|
110
114
|
end
|
111
115
|
|
112
116
|
def load_environments_config
|
data/lib/jets/commands/build.rb
CHANGED
@@ -141,12 +141,29 @@ module Jets::Commands
|
|
141
141
|
# In this case, we can skip a lot of the ruby related building and speed up the
|
142
142
|
# deploy process.
|
143
143
|
def self.poly_only?
|
144
|
+
!app_has_ruby? && !shared_has_ruby?
|
145
|
+
end
|
146
|
+
|
147
|
+
def self.app_has_ruby?
|
144
148
|
has_ruby = app_files.detect do |path|
|
145
149
|
app_class = Jets::Klass.from_path(path) # IE: PostsController, Jets::PublicController
|
146
150
|
langs = app_class.tasks.map(&:lang)
|
147
151
|
langs.include?(:ruby)
|
148
152
|
end
|
149
|
-
|
153
|
+
!!has_ruby
|
154
|
+
end
|
155
|
+
|
156
|
+
def self.shared_has_ruby?
|
157
|
+
has_ruby = false
|
158
|
+
Jets::Stack.subclasses.each do |klass|
|
159
|
+
klass.functions.each do |fun|
|
160
|
+
if fun.lang == :ruby
|
161
|
+
has_ruby = true
|
162
|
+
break
|
163
|
+
end
|
164
|
+
end
|
165
|
+
end
|
166
|
+
has_ruby
|
150
167
|
end
|
151
168
|
|
152
169
|
# Add internal Jets controllers if they are being used
|
data/lib/jets/turbine.rb
CHANGED
data/lib/jets/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jets
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tung Nguyen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-11-
|
11
|
+
date: 2018-11-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionpack
|