Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
dcf3dca9
Commit
dcf3dca9
authored
Aug 19, 2015
by
Saad Ali
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #11459 from erulabs/add_aws_ebs_volume_size_option
Add config option for AWS EBS root volume size
parents
c1a2c6de
5ee816e9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
4 deletions
+11
-4
config-default.sh
cluster/aws/config-default.sh
+6
-1
util.sh
cluster/aws/util.sh
+5
-3
No files found.
cluster/aws/config-default.sh
View file @
dcf3dca9
...
@@ -39,6 +39,12 @@ LOG="/dev/null"
...
@@ -39,6 +39,12 @@ LOG="/dev/null"
MASTER_DISK_TYPE
=
"
${
MASTER_DISK_TYPE
:-
gp2
}
"
MASTER_DISK_TYPE
=
"
${
MASTER_DISK_TYPE
:-
gp2
}
"
MASTER_DISK_SIZE
=
${
MASTER_DISK_SIZE
:-
20
}
MASTER_DISK_SIZE
=
${
MASTER_DISK_SIZE
:-
20
}
# The master root EBS volume size (typically does not need to be very large)
MASTER_ROOT_DISK_TYPE
=
"
${
MASTER_ROOT_DISK_TYPE
:-
gp2
}
"
MASTER_ROOT_DISK_SIZE
=
${
MASTER_ROOT_DISK_SIZE
:-
8
}
# The minions root EBS volume size (used to house Docker images
MINION_ROOT_DISK_TYPE
=
"
${
MINION_ROOT_DISK_TYPE
:-
gp2
}
"
MINION_ROOT_DISK_SIZE
=
${
MINION_ROOT_DISK_SIZE
:-
32
}
MASTER_NAME
=
"
${
INSTANCE_PREFIX
}
-master"
MASTER_NAME
=
"
${
INSTANCE_PREFIX
}
-master"
MASTER_TAG
=
"
${
INSTANCE_PREFIX
}
-master"
MASTER_TAG
=
"
${
INSTANCE_PREFIX
}
-master"
...
@@ -93,4 +99,3 @@ KUBE_MINION_IMAGE="${KUBE_MINION_IMAGE:-}"
...
@@ -93,4 +99,3 @@ KUBE_MINION_IMAGE="${KUBE_MINION_IMAGE:-}"
COREOS_CHANNEL
=
"
${
COREOS_CHANNEL
:-
alpha
}
"
COREOS_CHANNEL
=
"
${
COREOS_CHANNEL
:-
alpha
}
"
CONTAINER_RUNTIME
=
"
${
KUBE_CONTAINER_RUNTIME
:-
docker
}
"
CONTAINER_RUNTIME
=
"
${
KUBE_CONTAINER_RUNTIME
:-
docker
}
"
RKT_VERSION
=
"
${
KUBE_RKT_VERSION
:-
0
.5.5
}
"
RKT_VERSION
=
"
${
KUBE_RKT_VERSION
:-
0
.5.5
}
"
cluster/aws/util.sh
View file @
dcf3dca9
...
@@ -63,7 +63,9 @@ MINION_SG_NAME="kubernetes-minion-${CLUSTER_ID}"
...
@@ -63,7 +63,9 @@ MINION_SG_NAME="kubernetes-minion-${CLUSTER_ID}"
# Be sure to map all the ephemeral drives. We can specify more than we actually have.
# Be sure to map all the ephemeral drives. We can specify more than we actually have.
# TODO: Actually mount the correct number (especially if we have more), though this is non-trivial, and
# TODO: Actually mount the correct number (especially if we have more), though this is non-trivial, and
# only affects the big storage instance types, which aren't a typical use case right now.
# only affects the big storage instance types, which aren't a typical use case right now.
BLOCK_DEVICE_MAPPINGS
=
"[{
\"
DeviceName
\"
:
\"
/dev/sdc
\"
,
\"
VirtualName
\"
:
\"
ephemeral0
\"
},{
\"
DeviceName
\"
:
\"
/dev/sdd
\"
,
\"
VirtualName
\"
:
\"
ephemeral1
\"
},{
\"
DeviceName
\"
:
\"
/dev/sde
\"
,
\"
VirtualName
\"
:
\"
ephemeral2
\"
},{
\"
DeviceName
\"
:
\"
/dev/sdf
\"
,
\"
VirtualName
\"
:
\"
ephemeral3
\"
}]"
BLOCK_DEVICE_MAPPINGS_BASE
=
"{
\"
DeviceName
\"
:
\"
/dev/sdc
\"
,
\"
VirtualName
\"
:
\"
ephemeral0
\"
},{
\"
DeviceName
\"
:
\"
/dev/sdd
\"
,
\"
VirtualName
\"
:
\"
ephemeral1
\"
},{
\"
DeviceName
\"
:
\"
/dev/sde
\"
,
\"
VirtualName
\"
:
\"
ephemeral2
\"
},{
\"
DeviceName
\"
:
\"
/dev/sdf
\"
,
\"
VirtualName
\"
:
\"
ephemeral3
\"
}"
MASTER_BLOCK_DEVICE_MAPPINGS
=
"[{
\"
DeviceName
\"
:
\"
/dev/sda1
\"
,
\"
Ebs
\"
:{
\"
DeleteOnTermination
\"
:true,
\"
VolumeSize
\"
:
${
MASTER_ROOT_DISK_SIZE
}
,
\"
VolumeType
\"
:
\"
${
MASTER_ROOT_DISK_TYPE
}
\"
}},
${
BLOCK_DEVICE_MAPPINGS_BASE
}
]"
MINION_BLOCK_DEVICE_MAPPINGS
=
"[{
\"
DeviceName
\"
:
\"
/dev/sda1
\"
,
\"
Ebs
\"
:{
\"
DeleteOnTermination
\"
:true,
\"
VolumeSize
\"
:
${
MINION_ROOT_DISK_SIZE
}
,
\"
VolumeType
\"
:
\"
${
MINION_ROOT_DISK_TYPE
}
\"
}},
${
BLOCK_DEVICE_MAPPINGS_BASE
}
]"
function
json_val
{
function
json_val
{
python
-c
'import json,sys;obj=json.load(sys.stdin);print obj'
$1
''
python
-c
'import json,sys;obj=json.load(sys.stdin);print obj'
$1
''
...
@@ -846,7 +848,7 @@ function kube-up {
...
@@ -846,7 +848,7 @@ function kube-up {
--key-name
${
AWS_SSH_KEY_NAME
}
\
--key-name
${
AWS_SSH_KEY_NAME
}
\
--security-group-ids
${
MASTER_SG_ID
}
\
--security-group-ids
${
MASTER_SG_ID
}
\
--associate-public-ip-address
\
--associate-public-ip-address
\
--block-device-mappings
"
${
BLOCK_DEVICE_MAPPINGS
}
"
\
--block-device-mappings
"
${
MASTER_
BLOCK_DEVICE_MAPPINGS
}
"
\
--user-data
file://
${
KUBE_TEMP
}
/master-start.sh | json_val
'["Instances"][0]["InstanceId"]'
)
--user-data
file://
${
KUBE_TEMP
}
/master-start.sh | json_val
'["Instances"][0]["InstanceId"]'
)
add-tag
$master_id
Name
$MASTER_NAME
add-tag
$master_id
Name
$MASTER_NAME
add-tag
$master_id
Role
$MASTER_TAG
add-tag
$master_id
Role
$MASTER_TAG
...
@@ -957,7 +959,7 @@ function kube-up {
...
@@ -957,7 +959,7 @@ function kube-up {
--key-name
${
AWS_SSH_KEY_NAME
}
\
--key-name
${
AWS_SSH_KEY_NAME
}
\
--security-groups
${
MINION_SG_ID
}
\
--security-groups
${
MINION_SG_ID
}
\
${
public_ip_option
}
\
${
public_ip_option
}
\
--block-device-mappings
"
${
BLOCK_DEVICE_MAPPINGS
}
"
\
--block-device-mappings
"
${
MINION_
BLOCK_DEVICE_MAPPINGS
}
"
\
--user-data
"file://
${
KUBE_TEMP
}
/minion-user-data"
--user-data
"file://
${
KUBE_TEMP
}
/minion-user-data"
echo
"Creating autoscaling group"
echo
"Creating autoscaling group"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment