cody 1.0.2 → 1.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +19 -0
- data/README.md +2 -0
- data/cody.gemspec +2 -1
- data/lib/cody/cli/start.rb +8 -2
- data/lib/cody/core.rb +0 -1
- data/lib/cody/dsl/project/ssm.rb +1 -1
- data/lib/cody/setting.rb +6 -1
- data/lib/cody/tailer.rb +8 -0
- data/lib/cody/version.rb +1 -1
- data/lib/cody.rb +2 -0
- metadata +21 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a8381cda42f017707307d5de7118130640258798382938df63bdb4a028bfe43a
|
4
|
+
data.tar.gz: 4543b413ef1ecf727aa2b0151b62fed6b7928b946d142d1cbc1ed1897c53ed4f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1dc6cb7f35e4d21ae53c93746a22ed5df183dd06555939d4bec59f9b855197e67d2acbfc984b83a544c6dc9e79708709fb5c62005a654fffa0ea8108f25ffb3e
|
7
|
+
data.tar.gz: 45f3a91f478796108ed53fa7eba76f0743432c61872745d829a4d48c0b9ddbab7a733b98cd6e06db68a635aeaa7622b198226d85f1feddbca40a6e2a416b5247
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,25 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project *tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
|
5
5
|
|
6
|
+
## [1.0.6] - 2021-12-17
|
7
|
+
- [#32](https://github.com/tongueroo/cody/pull/32) fix activesupport require
|
8
|
+
- fix warn not found ssm param message
|
9
|
+
|
10
|
+
## [1.0.5] - 2021-08-28
|
11
|
+
- add params overrides option
|
12
|
+
- docs: fix ecs permission, add iam:GetRole
|
13
|
+
- edge case: yaml has nothing but comments
|
14
|
+
- improve settings merge
|
15
|
+
- update vpc config exmaple with camelcase
|
16
|
+
|
17
|
+
## [1.0.4] - 2021-01-08
|
18
|
+
- loosen activesupport version pin
|
19
|
+
|
20
|
+
## [1.0.3] - 2021-01-08
|
21
|
+
- [#31](https://github.com/tongueroo/cody/pull/31) surface context message with error message for during provisioning fa…
|
22
|
+
- docs: update ci jets v3
|
23
|
+
- raise error option
|
24
|
+
|
6
25
|
## [1.0.2]
|
7
26
|
- #30 Allow multiple git providers
|
8
27
|
|
data/README.md
CHANGED
@@ -9,6 +9,8 @@
|
|
9
9
|
|
10
10
|
[![BoltOps Badge](https://img.boltops.com/boltops/badges/boltops-badge.png)](https://www.boltops.com)
|
11
11
|
|
12
|
+
Please **watch/star** this repo to help grow and support the project.
|
13
|
+
|
12
14
|
Cody is an AWS CodeBuild Management Tool. Cody lets you create AWS CodeBuild projects with a beautiful DSL. The documentation site is at: [cody.run](https://cody.run/)
|
13
15
|
|
14
16
|
## Quick Start
|
data/cody.gemspec
CHANGED
@@ -22,7 +22,7 @@ Gem::Specification.new do |spec|
|
|
22
22
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
23
23
|
spec.require_paths = ["lib"]
|
24
24
|
|
25
|
-
spec.add_dependency "activesupport"
|
25
|
+
spec.add_dependency "activesupport"
|
26
26
|
spec.add_dependency "aws-logs"
|
27
27
|
spec.add_dependency "aws-mfa-secure"
|
28
28
|
spec.add_dependency "aws-sdk-cloudformation"
|
@@ -41,6 +41,7 @@ Gem::Specification.new do |spec|
|
|
41
41
|
spec.add_development_dependency "bundler"
|
42
42
|
spec.add_development_dependency "byebug"
|
43
43
|
spec.add_development_dependency "cli_markdown"
|
44
|
+
spec.add_development_dependency "nokogiri"
|
44
45
|
spec.add_development_dependency "rake"
|
45
46
|
spec.add_development_dependency "rspec"
|
46
47
|
end
|
data/lib/cody/cli/start.rb
CHANGED
@@ -15,6 +15,7 @@ class Cody::CLI
|
|
15
15
|
source_version: source_version
|
16
16
|
}
|
17
17
|
params[:environment_variables_override] = environment_variables_override if @options[:env_vars]
|
18
|
+
params.merge!(@options[:overrides]) if @options[:overrides]
|
18
19
|
resp = codebuild.start_build(params)
|
19
20
|
|
20
21
|
puts "Build started for project: #{project_name}"
|
@@ -54,8 +55,13 @@ class Cody::CLI
|
|
54
55
|
end
|
55
56
|
resource.physical_resource_id # codebuild project name
|
56
57
|
else
|
57
|
-
|
58
|
-
|
58
|
+
message = "ERROR: Unable to find the codebuild project with either full_project_name: #{@full_project_name} or project_name: #{@project_name}"
|
59
|
+
if @options[:raise_error]
|
60
|
+
raise(message)
|
61
|
+
else
|
62
|
+
puts message.color(:red)
|
63
|
+
exit 1
|
64
|
+
end
|
59
65
|
end
|
60
66
|
end
|
61
67
|
|
data/lib/cody/core.rb
CHANGED
data/lib/cody/dsl/project/ssm.rb
CHANGED
data/lib/cody/setting.rb
CHANGED
@@ -25,7 +25,10 @@ module Cody
|
|
25
25
|
|
26
26
|
all_envs = default.deep_merge(user.deep_merge(project))
|
27
27
|
all_envs = merge_base(all_envs)
|
28
|
-
|
28
|
+
|
29
|
+
env_data = all_envs[cb_env] || {}
|
30
|
+
base_data = all_envs["base"] || {}
|
31
|
+
data = base_data.merge(env_data)
|
29
32
|
data.deep_symbolize_keys
|
30
33
|
end
|
31
34
|
memoize :data
|
@@ -37,6 +40,7 @@ module Cody
|
|
37
40
|
path = "#{cb_root}/.cody/settings.yml"
|
38
41
|
if File.exist?(path)
|
39
42
|
settings = YAML.load_file(path)
|
43
|
+
settings = {} unless settings.is_a?(Hash) # in case YAML has nothing but comments
|
40
44
|
env = settings.find do |_env, section|
|
41
45
|
section ||= {}
|
42
46
|
ENV['AWS_PROFILE'] && ENV['AWS_PROFILE'] == section['aws_profile']
|
@@ -54,6 +58,7 @@ module Cody
|
|
54
58
|
|
55
59
|
content = RenderMePretty.result(path)
|
56
60
|
data = YAML.load(content)
|
61
|
+
data = {} unless data.is_a?(Hash) # in case YAML has nothing but comments
|
57
62
|
# If key is is accidentally set to nil it screws up the merge_base later.
|
58
63
|
# So ensure that all keys with nil value are set to {}
|
59
64
|
data.each do |env, _setting|
|
data/lib/cody/tailer.rb
CHANGED
@@ -54,6 +54,14 @@ module Cody
|
|
54
54
|
puts "Failed Phases:"
|
55
55
|
failed_phases.each do |phase|
|
56
56
|
puts "#{phase.phase_type}: #{phase.phase_status.color(:red)}"
|
57
|
+
context = phase.contexts.last
|
58
|
+
if context # show error details: Unable to pull customer's container image https://gist.github.com/tongueroo/22e4ca3d4cde002108ff506eba9062f6
|
59
|
+
message = context.message
|
60
|
+
puts message
|
61
|
+
if message.include?("CannotPullContainerError") && message.include?("access denied")
|
62
|
+
puts "See: https://docs.aws.amazon.com/codebuild/latest/userguide/sample-ecr.html"
|
63
|
+
end
|
64
|
+
end
|
57
65
|
end
|
58
66
|
end
|
59
67
|
|
data/lib/cody/version.rb
CHANGED
data/lib/cody.rb
CHANGED
metadata
CHANGED
@@ -1,29 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cody
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tung Nguyen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-12-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
26
|
+
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: aws-logs
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -262,6 +262,20 @@ dependencies:
|
|
262
262
|
- - ">="
|
263
263
|
- !ruby/object:Gem::Version
|
264
264
|
version: '0'
|
265
|
+
- !ruby/object:Gem::Dependency
|
266
|
+
name: nokogiri
|
267
|
+
requirement: !ruby/object:Gem::Requirement
|
268
|
+
requirements:
|
269
|
+
- - ">="
|
270
|
+
- !ruby/object:Gem::Version
|
271
|
+
version: '0'
|
272
|
+
type: :development
|
273
|
+
prerelease: false
|
274
|
+
version_requirements: !ruby/object:Gem::Requirement
|
275
|
+
requirements:
|
276
|
+
- - ">="
|
277
|
+
- !ruby/object:Gem::Version
|
278
|
+
version: '0'
|
265
279
|
- !ruby/object:Gem::Dependency
|
266
280
|
name: rake
|
267
281
|
requirement: !ruby/object:Gem::Requirement
|
@@ -387,7 +401,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
387
401
|
- !ruby/object:Gem::Version
|
388
402
|
version: '0'
|
389
403
|
requirements: []
|
390
|
-
rubygems_version: 3.
|
404
|
+
rubygems_version: 3.2.32
|
391
405
|
signing_key:
|
392
406
|
specification_version: 4
|
393
407
|
summary: Cody provides a beautiful DSL to create and manage AWS CodeBuild projects
|