inf 0.0.9 → 0.0.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/inf +5 -2
- data/lib/aws.rb +12 -1
- data/lib/domains.rb +3 -3
- data/lib/inf.rb +2 -0
- data/lib/version.rb +3 -0
- metadata +6 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7765d51747258b9cb335204780d44762c00efdb7
|
4
|
+
data.tar.gz: dcf23bacd65b44f06f182947a3f13115c27b631c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 947bfbab39a2e34e3e850f1c1f432f24047bdc6a7028fefc037e5509cc6552f3a009bc9ca89d6cb47b9f6d7bec3abeda650391349f728725542187cc0f37230b
|
7
|
+
data.tar.gz: 85b89d216c0d4539705ac993aa56c888b3f1f0adb898a6c1be6552b7e5b70b6f96e4096948436a189f4268019ed0dae8a43741d5de22e6ab541cda217444c058
|
data/bin/inf
CHANGED
@@ -3,7 +3,6 @@
|
|
3
3
|
require 'thor'
|
4
4
|
require 'aws-sdk'
|
5
5
|
require 'time'
|
6
|
-
require 'pry'
|
7
6
|
require 'awesome_print'
|
8
7
|
require 'base64'
|
9
8
|
require 'colored'
|
@@ -33,7 +32,6 @@ require_env_vars %w(
|
|
33
32
|
SUBNET_IDS
|
34
33
|
KEY_NAME
|
35
34
|
CERT_ARN
|
36
|
-
JENKINS_PUBLIC_KEY
|
37
35
|
)
|
38
36
|
|
39
37
|
ENV['TERMINATE_INSTANCES'] ||= "true"
|
@@ -161,6 +159,11 @@ class CLI < Thor
|
|
161
159
|
puts "Opening #{url} in #{browser}".blue
|
162
160
|
`#{browser} #{url}`
|
163
161
|
end
|
162
|
+
|
163
|
+
desc 'version', 'prints version and exits'
|
164
|
+
def version
|
165
|
+
puts Inf::VERSION
|
166
|
+
end
|
164
167
|
end
|
165
168
|
|
166
169
|
CLI.start(ARGV)
|
data/lib/aws.rb
CHANGED
@@ -67,7 +67,7 @@ BOOTSTRAP_SCRIPT
|
|
67
67
|
elb.configure_health_check(
|
68
68
|
load_balancer_name: lb_name,
|
69
69
|
health_check: {
|
70
|
-
target: 'HTTP:80/',
|
70
|
+
target: 'HTTP:80/health_check',
|
71
71
|
interval: 10, # seconds
|
72
72
|
timeout: 5, # seconds to respond
|
73
73
|
unhealthy_threshold: 2, # two consecutive failures
|
@@ -107,6 +107,16 @@ BOOTSTRAP_SCRIPT
|
|
107
107
|
end
|
108
108
|
end.flatten
|
109
109
|
|
110
|
+
tag_specifications = [{
|
111
|
+
tags: [{
|
112
|
+
key: "app_name",
|
113
|
+
value: app_name
|
114
|
+
}, {
|
115
|
+
key: "fleet_name",
|
116
|
+
value: fleet_name
|
117
|
+
}]
|
118
|
+
}]
|
119
|
+
|
110
120
|
resp = ec2.request_spot_fleet(
|
111
121
|
spot_fleet_request_config: {
|
112
122
|
spot_price: ENV['SPOT_PRICE'],
|
@@ -116,6 +126,7 @@ BOOTSTRAP_SCRIPT
|
|
116
126
|
terminate_instances_with_expiration: ENV['TERMINATE_INSTANCES'],
|
117
127
|
iam_fleet_role: ENV['FLEET_ROLE'],
|
118
128
|
launch_specifications: launch_specifications,
|
129
|
+
# tag_specifications: tag_specifications,
|
119
130
|
excess_capacity_termination_policy: "default", # accepts noTermination, default
|
120
131
|
allocation_strategy: "diversified", # accepts lowestPrice, diversified
|
121
132
|
type: "maintain", # accepts request, maintain
|
data/lib/domains.rb
CHANGED
@@ -12,9 +12,9 @@ class Inf::Domains < Thor
|
|
12
12
|
end
|
13
13
|
|
14
14
|
def self.hosted_zones
|
15
|
-
@hosted_zones ||= route53.list_hosted_zones_by_name.hosted_zones.reduce
|
16
|
-
|
17
|
-
end
|
15
|
+
# @hosted_zones ||= route53.list_hosted_zones_by_name.hosted_zones.reduce
|
16
|
+
# binding.pry
|
17
|
+
# end
|
18
18
|
end
|
19
19
|
|
20
20
|
def self.sync_to_route53
|
data/lib/inf.rb
CHANGED
data/lib/version.rb
ADDED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: inf
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kyle Brett <kyle@kylebrett.com>
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-09-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '2.
|
33
|
+
version: '2.10'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '2.
|
40
|
+
version: '2.10'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: colored
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -96,6 +96,7 @@ files:
|
|
96
96
|
- lib/inf.rb
|
97
97
|
- lib/load_balancer.rb
|
98
98
|
- lib/migrations.rb
|
99
|
+
- lib/version.rb
|
99
100
|
homepage: http://www.kylebrett.com
|
100
101
|
licenses:
|
101
102
|
- Nonstandard
|
@@ -116,7 +117,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
116
117
|
version: '0'
|
117
118
|
requirements: []
|
118
119
|
rubyforge_project:
|
119
|
-
rubygems_version: 2.6.
|
120
|
+
rubygems_version: 2.6.12
|
120
121
|
signing_key:
|
121
122
|
specification_version: 4
|
122
123
|
summary: inf
|