From 74c2974e6b364b139e590666d1f62ed196b72803 Mon Sep 17 00:00:00 2001 From: syed salman Date: Tue, 30 Jan 2024 20:03:49 +0530 Subject: [PATCH] [MOSIP-31031] Added method to fetch docker hash ID Signed-off-by: syed salman --- pmptest/Dockerfile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pmptest/Dockerfile b/pmptest/Dockerfile index 3a9145ab1..87f0c9eab 100644 --- a/pmptest/Dockerfile +++ b/pmptest/Dockerfile @@ -23,10 +23,15 @@ ARG container_user_gid=1001 # Set working directory for the user ENV work_dir=/home/${container_user}/ +ARG KUBECTL_VERSION=1.22.9 + # install packages and create user RUN groupadd -g ${container_user_gid} ${container_user_group} \ && useradd -u ${container_user_uid} -g ${container_user_group} -s /bin/bash -m ${container_user} -d ${work_dir} \ - && chown -R ${container_user}:${container_user} /home/${container_user}/ + && chown -R ${container_user}:${container_user} /home/${container_user}/ \ + && curl -LO "https://storage.googleapis.com/kubernetes-release/release/v${KUBECTL_VERSION}/bin/linux/amd64/kubectl" \ + && chmod +x kubectl \ + && mv kubectl /usr/local/bin/ # Switch to the specified user for the subsequent commands USER ${container_user_uid}:${container_user_gid}