From 3d1e2229fd8afb4c7602e21e39ecd8131ecb085c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Ollivier?= Date: Tue, 26 Nov 2024 09:56:42 +0100 Subject: [PATCH] Stop passing stdin to the container MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It would avoid all the following errors: KubectlClient.exec stderr: Unable to use a TTY - input is not a terminal or the right kind of file Signed-off-by: Cédric Ollivier --- cluster_tools.cr | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cluster_tools.cr b/cluster_tools.cr index 8ce26137..356ea38b 100644 --- a/cluster_tools.cr +++ b/cluster_tools.cr @@ -79,7 +79,7 @@ module ClusterTools cluster_tools_pod_name = pods[0].dig?("metadata", "name") if pods[0]? Log.info { "cluster_tools_pod_name: #{cluster_tools_pod_name}"} - cmd = "-ti #{cluster_tools_pod_name} -- #{cli}" + cmd = "#{cluster_tools_pod_name} -- #{cli}" KubectlClient.exec(cmd, namespace: self.namespace!) end @@ -92,7 +92,7 @@ module ClusterTools cluster_tools_pod_name = pods[0].dig?("metadata", "name") if pods[0]? Log.debug { "cluster_tools_pod_name: #{cluster_tools_pod_name}"} - full_cli = "-ti #{cluster_tools_pod_name} -- #{cli}" + full_cli = "#{cluster_tools_pod_name} -- #{cli}" Log.debug { "ClusterTools exec full cli: #{full_cli}" } return full_cli end @@ -243,7 +243,7 @@ module ClusterTools # https://windsock.io/explaining-docker-image-ids/ # works on dockerhub and quay! - # ex. kubectl exec -ti cluster-tools-ww9lg -- skopeo inspect docker://jaegertracing/jaeger-agent:1.28.0 + # ex. kubectl exec cluster-tools-ww9lg -- skopeo inspect docker://jaegertracing/jaeger-agent:1.28.0 # Accepts org/image:tag or repo/org/image:tag # A content digest is an uncompressed digest, which is what Kubernetes tracks def self.official_content_digest_by_image_name(image_name)