kontena-plugin-aws 0.3.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/kontena/machine/aws/cloudinit.yml +12 -5
- data/lib/kontena/machine/aws/master_provisioner.rb +6 -2
- data/lib/kontena/machine/aws/node_provisioner.rb +6 -2
- data/lib/kontena/plugin/aws.rb +1 -1
- data/lib/kontena/plugin/aws/master/create_command.rb +3 -1
- data/lib/kontena/plugin/aws/nodes/create_command.rb +3 -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: a1c39a10a404506e61fc5f991d0086ae1be56e92e579fb1aab47490556a777f2
|
|
4
|
+
data.tar.gz: c7fae31982c09ee42b44063aaf7c4b6905407160250934697c6c37f01dbe28c8
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 54502b59edf8f14630bf40a82fb592987447cec5c82c470c5ea437db4a571aeac72e89454368dc059614244282ab44e8b0013ef5e0eb7e61bdf0f02f090e0a88
|
|
7
|
+
data.tar.gz: 382e37008e433d0ba793b65e02b6923d98e24200977f52be9643cff8e62cd8707aa1e20463aa68d5b6ce8f8cc097ed46b40d70b0328cd6250798eebff3ba70e0
|
|
@@ -12,13 +12,18 @@ write_files:
|
|
|
12
12
|
- path: /etc/systemd/system/docker.service.d/50-kontena.conf
|
|
13
13
|
content: |
|
|
14
14
|
[Service]
|
|
15
|
-
Environment='DOCKER_OPTS=--insecure-registry="10.81.0.0/16" --bip="172.17.43.1/16"'
|
|
15
|
+
Environment='DOCKER_OPTS=--log-driver=json-file --log-opt=max-size=20m --insecure-registry="10.81.0.0/16" --bip="172.17.43.1/16"'
|
|
16
16
|
Environment='DOCKER_CGROUPS=--exec-opt native.cgroupdriver=cgroupfs'
|
|
17
|
-
- path: /etc/sysctl.d/99-
|
|
17
|
+
- path: /etc/sysctl.d/99-kontena.conf
|
|
18
18
|
owner: root
|
|
19
19
|
permissions: 0644
|
|
20
20
|
content: |
|
|
21
21
|
fs.inotify.max_user_instances = 8192
|
|
22
|
+
fs.inotify.max_user_watches = 524288
|
|
23
|
+
vm.max_map_count = 262144
|
|
24
|
+
kernel.softlockup_panic = 1
|
|
25
|
+
kernel.softlockup_all_cpu_backtrace = 1
|
|
26
|
+
kernel.panic = 60
|
|
22
27
|
coreos:
|
|
23
28
|
units:
|
|
24
29
|
- name: zz-default.network
|
|
@@ -55,10 +60,9 @@ coreos:
|
|
|
55
60
|
content: |
|
|
56
61
|
[Unit]
|
|
57
62
|
Description=kontena-agent
|
|
63
|
+
Documentation=https://www.kontena.io/
|
|
58
64
|
After=network-online.target
|
|
59
65
|
After=docker.service
|
|
60
|
-
Description=Kontena Agent
|
|
61
|
-
Documentation=http://www.kontena.io/
|
|
62
66
|
Requires=network-online.target
|
|
63
67
|
Requires=docker.service
|
|
64
68
|
|
|
@@ -76,5 +80,8 @@ coreos:
|
|
|
76
80
|
-e KONTENA_PEER_INTERFACE=${KONTENA_PEER_INTERFACE} \
|
|
77
81
|
-v=/var/run/docker.sock:/var/run/docker.sock \
|
|
78
82
|
-v=/etc/kontena-agent.env:/etc/kontena.env \
|
|
79
|
-
--net=host \
|
|
83
|
+
--net=host --memory 384m \
|
|
80
84
|
kontena/agent:${KONTENA_VERSION}
|
|
85
|
+
|
|
86
|
+
[Install]
|
|
87
|
+
WantedBy=docker.service
|
|
@@ -36,8 +36,12 @@ module Kontena::Machine::Aws
|
|
|
36
36
|
end
|
|
37
37
|
end
|
|
38
38
|
|
|
39
|
-
ami
|
|
40
|
-
|
|
39
|
+
if opts[:ami]
|
|
40
|
+
ami = opts[:ami]
|
|
41
|
+
else
|
|
42
|
+
ami = resolve_ami(region)
|
|
43
|
+
abort('No valid AMI found for region') unless ami
|
|
44
|
+
end
|
|
41
45
|
opts[:vpc] = default_vpc.vpc_id unless opts[:vpc]
|
|
42
46
|
|
|
43
47
|
raise "Missing :subnet option" if opts[:subnet].nil?
|
|
@@ -24,8 +24,12 @@ module Kontena::Machine::Aws
|
|
|
24
24
|
|
|
25
25
|
# @param [Hash] opts
|
|
26
26
|
def run!(opts)
|
|
27
|
-
ami
|
|
28
|
-
|
|
27
|
+
if opts[:ami]
|
|
28
|
+
ami = opts[:ami]
|
|
29
|
+
else
|
|
30
|
+
ami = resolve_ami(region)
|
|
31
|
+
abort('No valid AMI found for region') unless ami
|
|
32
|
+
end
|
|
29
33
|
|
|
30
34
|
opts[:vpc] = default_vpc.vpc_id unless opts[:vpc]
|
|
31
35
|
|
data/lib/kontena/plugin/aws.rb
CHANGED
|
@@ -13,6 +13,7 @@ module Kontena::Plugin::Aws::Master
|
|
|
13
13
|
option "--vault-secret", "VAULT_SECRET", "Secret key for Vault (default: generate random secret)"
|
|
14
14
|
option "--vault-iv", "VAULT_IV", "Initialization vector for Vault (default: generate random iv)"
|
|
15
15
|
option "--mongodb-uri", "URI", "External MongoDB uri (optional)"
|
|
16
|
+
option "--ami", "AMI", "Which Container Linux AMI to use (default: latest stable)"
|
|
16
17
|
|
|
17
18
|
def execute
|
|
18
19
|
require 'securerandom'
|
|
@@ -33,7 +34,8 @@ module Kontena::Plugin::Aws::Master
|
|
|
33
34
|
mongodb_uri: mongodb_uri,
|
|
34
35
|
associate_public_ip: associate_public_ip?,
|
|
35
36
|
security_groups: security_groups,
|
|
36
|
-
initial_admin_code: SecureRandom.hex(16)
|
|
37
|
+
initial_admin_code: SecureRandom.hex(16),
|
|
38
|
+
ami: ami
|
|
37
39
|
)
|
|
38
40
|
rescue Seahorse::Client::NetworkingError => ex
|
|
39
41
|
raise ex unless ex.message.match(/certificate verify failed/)
|
|
@@ -11,6 +11,7 @@ module Kontena::Plugin::Aws::Nodes
|
|
|
11
11
|
include Kontena::Plugin::Aws::Prompts::Common
|
|
12
12
|
|
|
13
13
|
option "--count", "COUNT", "How many instances to create"
|
|
14
|
+
option "--ami", "AMI", "Which Container Linux AMI to use (default: latest stable)"
|
|
14
15
|
|
|
15
16
|
requires_current_master
|
|
16
17
|
|
|
@@ -33,7 +34,8 @@ module Kontena::Plugin::Aws::Nodes
|
|
|
33
34
|
key_pair: key_pair,
|
|
34
35
|
count: count,
|
|
35
36
|
associate_public_ip: associate_public_ip?,
|
|
36
|
-
security_groups: security_groups
|
|
37
|
+
security_groups: security_groups,
|
|
38
|
+
ami: ami
|
|
37
39
|
)
|
|
38
40
|
rescue Seahorse::Client::NetworkingError => ex
|
|
39
41
|
raise ex unless ex.message.match(/certificate verify failed/)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: kontena-plugin-aws
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.4.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Kontena, Inc.
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2018-03-29 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: kontena-cli
|
|
@@ -128,7 +128,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
128
128
|
version: '0'
|
|
129
129
|
requirements: []
|
|
130
130
|
rubyforge_project:
|
|
131
|
-
rubygems_version: 2.7.
|
|
131
|
+
rubygems_version: 2.7.6
|
|
132
132
|
signing_key:
|
|
133
133
|
specification_version: 4
|
|
134
134
|
summary: Kontena AWS plugin
|