From 087dca348211f23d514a602adf36a663bed1c3f0 Mon Sep 17 00:00:00 2001 From: Brad Ison Date: Tue, 4 Oct 2016 20:42:51 -0400 Subject: [PATCH] Only set memory request on Kubernetes builds This removes the aboslute limits on Kubernetes builds for now (KVM will still limit resources) and only sets the memory request as a hint to the scheduler. --- buildman/manager/executor.py | 8 -------- 1 file changed, 8 deletions(-) diff --git a/buildman/manager/executor.py b/buildman/manager/executor.py index a1dcc5d83..5438dce50 100644 --- a/buildman/manager/executor.py +++ b/buildman/manager/executor.py @@ -340,18 +340,11 @@ class KubernetesExecutor(BuilderExecutor): vm_memory_limit = self.executor_config.get('VM_MEMORY_LIMIT', '4G') vm_volume_size = self.executor_config.get('VOLUME_SIZE', '32G') - # Max values for this container - container_limits = { - 'memory' : self.executor_config.get('CONTAINER_MEMORY_LIMIT', '4Gi'), - 'cpu' : self.executor_config.get('CONTAINER_CPU_LIMIT', "2"), - } - # Minimum acceptable free resources for this container to "fit" in a quota # These may be lower than the aboslute limits if the cluster is knowingly # oversubscribed by some amount. container_requests = { 'memory' : self.executor_config.get('CONTAINER_MEMORY_REQUEST', '3968Mi'), - 'cpu' : self.executor_config.get('CONTAINER_CPU_REQUEST', "1"), } release_sha = release.GIT_HEAD or 'none' @@ -395,7 +388,6 @@ class KubernetesExecutor(BuilderExecutor): {'name': 'VM_VOLUME_SIZE', 'value': vm_volume_size}, ], 'resources': { - 'limits': container_limits, 'requests': container_requests, }, },