hocho-ec2 0.2.0 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +26 -14
- data/lib/hocho-ec2/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e6be38211c3a8251117b1f3d61f6efb61a9067f16cd734ae4eb2feb43cf8e37d
|
4
|
+
data.tar.gz: 20d6ede54ddf6fafdece395d1a36311ff1a7caadedbfd3c195151f0ca4582bf4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e46953fe3b2de3ea5772c07f31bf34882be36cf9ddfecc0726e6483d0424ff8f987fa611186a33dc1c7ac7e11244c02935af0de413710bcf438411347b46fa28
|
7
|
+
data.tar.gz: 9d2533ddfb5c5f3adbaf9e3003787fd92a1d361be845e9a9bdfc24399ad37faf2958c4c8a23cb7ffecae0f706f02e6369f19a1f09ad581ddab56b776213701da
|
data/README.md
CHANGED
@@ -1,28 +1,40 @@
|
|
1
|
-
#
|
1
|
+
# hocho-ec2: Host inventory for Amazon EC2
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
TODO: Delete this and the text above, and describe your gem
|
3
|
+
This is a [sorah/hocho](https://github.com/sorah/hocho) inventory provider plugin that retrieves EC2 instance information as host data.
|
6
4
|
|
7
5
|
## Installation
|
8
6
|
|
9
|
-
Add this line to your
|
7
|
+
Add this line to your Gemfile:
|
10
8
|
|
11
9
|
```ruby
|
12
10
|
gem 'hocho-ec2'
|
13
11
|
```
|
14
12
|
|
15
|
-
And then execute:
|
16
|
-
|
17
|
-
$ bundle
|
18
|
-
|
19
|
-
Or install it yourself as:
|
20
|
-
|
21
|
-
$ gem install hocho-ec2
|
22
|
-
|
23
13
|
## Usage
|
24
14
|
|
25
|
-
|
15
|
+
```yaml
|
16
|
+
# hocho.yml
|
17
|
+
inventory_providers:
|
18
|
+
- ec2:
|
19
|
+
## AWS Region
|
20
|
+
region: ap-northeast-1
|
21
|
+
## ec2:DescribeInstances API filters
|
22
|
+
filters:
|
23
|
+
- name: instance-state-name
|
24
|
+
values: ['running']
|
25
|
+
## ERB Template for host.name. You can use `tag(instance, "NAME")` and `tag(vpc, "NAME")` helper.
|
26
|
+
hostname_template: '<%= tag(instance, "Name") %>.<%= tag(vpc, "Name") %>.compute.nkmi.me'
|
27
|
+
## Template - Ruby script for host.properties.template. Expected to return an Array.
|
28
|
+
runlist_template: '%w(site.rb entry_ec2.rb entry_ec2_role.rb)'
|
29
|
+
## Cache the result for specified duration.
|
30
|
+
cache_path: tmp/hocho-ec2-cache.apne1.yml
|
31
|
+
cache_duration: 3600
|
32
|
+
|
33
|
+
## You can add multiple instnaces of a provider to cover more regions:
|
34
|
+
# - ec2:
|
35
|
+
# region: us-west-2
|
36
|
+
# ...
|
37
|
+
```
|
26
38
|
|
27
39
|
## Development
|
28
40
|
|
data/lib/hocho-ec2/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hocho-ec2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sorah Fukumori
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-05-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-ec2
|
@@ -105,7 +105,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
105
105
|
- !ruby/object:Gem::Version
|
106
106
|
version: '0'
|
107
107
|
requirements: []
|
108
|
-
rubygems_version: 3.
|
108
|
+
rubygems_version: 3.1.2
|
109
109
|
signing_key:
|
110
110
|
specification_version: 4
|
111
111
|
summary: Hocho gem plugin to discover hosts in EC2
|