amazon-archives / aws-service-operator

AWS Service Operator allows you to create AWS resources using kubectl.
Apache License 2.0
732 stars 97 forks source link

Add support for creating EBS or local SSDs and attaching to instance #108

Open kmova opened 6 years ago

kmova commented 6 years ago

It will be cool if i can run the aws-service-operator on my K8s cluster have have the capability to attach/detach EBS or local SSD disks to a node in the K8s cluster. This will be in place of using the existing K8s - PV/PVC mechanism.

PV/PVC has the limitation that one PV (a full EBS disk) will have to be associated with a Pod. I would like to partition the same EBS for multiple pods.

christopherhein commented 6 years ago

Labeling this operator/ebs this could be useful, I wonder if this is a better fit under the https://github.com/kubernetes/cloud-provider-aws since that is where the PV/PVC mechanisms are implemented. @nckturner would probably have some input.

nckturner commented 5 years ago

@kmova why do you want to partition one EBS disk for multiple pods? I have a feeling that's asking for trouble but you should ask the question in the issues here: https://github.com/kubernetes-sigs/aws-ebs-csi-driver as that's where the storage experts hang out these days.

kmova commented 5 years ago

@nckturner - I am thinking of an usecase where EBS disks for making space available on the K8s node - that can be used for creating hostpath based pods. (not really partitioning the disk itself). I will check on the csi-driver repo as well.

For example, it is possible for me to setup a mechanism where whenever a node is attached to the cluster, I want it to have 1 additional (or n) EBS disks already attached to it.

christopherhein commented 5 years ago

For example, it is possible for me to setup a mechanism where whenever a node is attached to the cluster, I want it to have 1 additional (or n) EBS disks already attached to it.

You should be able to accomplish this outside of Kubernetes itself by setting these request on the Launch Configurations for the Autoscaling group. Maybe this would be better to be contained under #109 so that we can make sure you can customize the EBS mounts via the node groups

kmova commented 5 years ago

That makes sense @christopherhein