senthilrch / kube-fledged

A kubernetes operator for creating and managing a cache of container images directly on the cluster worker nodes, so application pods start almost instantly
Apache License 2.0
1.26k stars 119 forks source link

Feature: Awareness of available disk space #209

Open konturn opened 1 year ago

konturn commented 1 year ago

Hi there! I'm currently looking at using kube-fledged, but am concerned that a large image cache may eat up an unreasonable amount of disk space on the nodes. Is the controller aware of disk space constraints, or is it possible for image pulls instigated by the ImageCache resource to cause pod evictions due to low disk space? If so, I was thinking it could be a good approach to add one of the following options to the cacheSpec:

  1. A field for limiting the aggregate size of all images comprising the cacheSpec, or
  2. A field which prevents image pulls if node disk space drops below the configurable threshold (this would be evaluated on a per-node basis)

I could try taking a stab at this if pointed in the right direction, but wanted to confirm that this feature makes sense first.