capify-ec2 1.4.7 → 1.4.8
Sign up to get free protection for your applications and to get access to all the features.
- data/Changelog.md +7 -0
- data/lib/capify-ec2/version.rb +1 -1
- data/lib/capify-ec2.rb +4 -1
- data/readme.md +8 -4
- metadata +4 -4
data/Changelog.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
## 1.4.8 (May 17, 2013)
|
2
|
+
|
3
|
+
Features:
|
4
|
+
|
5
|
+
- The EC2 instance tag used to determine instance Project can now be customised. Defaults to 'Project' if this setting is ommited.
|
6
|
+
- If any project tags are being used, they are now displayed when running the 'ec2:status' command.
|
7
|
+
|
1
8
|
## 1.4.7 (May 16, 2013)
|
2
9
|
|
3
10
|
Features:
|
data/lib/capify-ec2/version.rb
CHANGED
data/lib/capify-ec2.rb
CHANGED
@@ -23,6 +23,8 @@ class CapifyEc2
|
|
23
23
|
|
24
24
|
# Maintain backward compatibility with previous config format
|
25
25
|
@ec2_config[:project_tags] ||= []
|
26
|
+
# User can change the Project tag string
|
27
|
+
@ec2_config[:aws_project_tag] ||= "Project"
|
26
28
|
# User can change the Roles tag string
|
27
29
|
@ec2_config[:aws_roles_tag] ||= "Roles"
|
28
30
|
# User can change the Options tag string.
|
@@ -81,6 +83,7 @@ class CapifyEc2
|
|
81
83
|
column_widths[:options] = desired_instances.map{|i| i.tags[@ec2_config[:aws_options_tag]].to_s.ljust( column_widths[:options_min] ) || ' ' * column_widths[:options_min] }.max_by(&:length).length
|
82
84
|
|
83
85
|
# Title row.
|
86
|
+
puts "#{@ec2_config[:aws_project_tag].bold}: #{@ec2_config[:project_tags].join(', ')}." if @ec2_config[:project_tags].any?
|
84
87
|
puts sprintf "%-3s %s %s %s %s %s %s %s",
|
85
88
|
'Num' .bold,
|
86
89
|
'Name' .ljust( column_widths[:name] ).bold,
|
@@ -109,7 +112,7 @@ class CapifyEc2
|
|
109
112
|
end
|
110
113
|
|
111
114
|
def project_instances
|
112
|
-
@instances.select {|instance| @ec2_config[:project_tags].include?(instance.tags[
|
115
|
+
@instances.select {|instance| @ec2_config[:project_tags].include?(instance.tags[@ec2_config[:aws_project_tag]])}
|
113
116
|
end
|
114
117
|
|
115
118
|
def desired_instances(region = nil)
|
data/readme.md
CHANGED
@@ -31,7 +31,7 @@ require "capify-ec2/capistrano"
|
|
31
31
|
|
32
32
|
#### Configuration
|
33
33
|
|
34
|
-
Note: ':aws_access_key_id' and ':aws_secret_access_key' are required, unless you provide them via the two alternative methods detailed below. ':region' is also required. Other settings are optional.
|
34
|
+
Note: ':aws_access_key_id' and ':aws_secret_access_key' are required, unless you provide them via the two alternative methods detailed below under 'AWS Credentials'. ':region' is also required. Other settings are optional.
|
35
35
|
|
36
36
|
* :project_tag
|
37
37
|
|
@@ -45,10 +45,9 @@ Note: ':aws_access_key_id' and ':aws_secret_access_key' are required, unless you
|
|
45
45
|
- "YOUR OTHER APP NAME"
|
46
46
|
```
|
47
47
|
|
48
|
-
* :
|
48
|
+
* :aws_project_tag
|
49
49
|
|
50
|
-
|
51
|
-
Note: This options only applies to deployments made to an individual instance, using the command 'cap INSTANCE_NAME_HERE deploy' - it doesn't apply to roles.
|
50
|
+
Use this option to change which EC2 instance tag Capify-EC2 uses to determine instance project. Defaults to 'Project' if ommited.
|
52
51
|
|
53
52
|
* :aws_roles_tag
|
54
53
|
|
@@ -58,6 +57,11 @@ Note: ':aws_access_key_id' and ':aws_secret_access_key' are required, unless you
|
|
58
57
|
|
59
58
|
Use this option to change which EC2 instance tag Capify-EC2 uses to determine instance options. Defaults to 'Options' if ommited.
|
60
59
|
|
60
|
+
* :load_balanced
|
61
|
+
|
62
|
+
When ':load_balanced' is set to 'true', Capify-EC2 uses pre and post-deploy hooks to deregister the instance from an associated Elastic Load Balancer, perform the actual deploy, then finally reregister with the ELB and validated the instance health.
|
63
|
+
Note: This options only applies to deployments made to an individual instance, using the command 'cap INSTANCE_NAME_HERE deploy' - it doesn't apply to roles.
|
64
|
+
|
61
65
|
##### AWS Credentials
|
62
66
|
|
63
67
|
###### Via YML Configuration
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capify-ec2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 4
|
9
|
-
-
|
10
|
-
version: 1.4.
|
9
|
+
- 8
|
10
|
+
version: 1.4.8
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Noah Cantor
|
@@ -18,7 +18,7 @@ autorequire:
|
|
18
18
|
bindir: bin
|
19
19
|
cert_chain: []
|
20
20
|
|
21
|
-
date: 2013-05-
|
21
|
+
date: 2013-05-17 00:00:00 Z
|
22
22
|
dependencies:
|
23
23
|
- !ruby/object:Gem::Dependency
|
24
24
|
name: fog
|