ENV_NAME=some_branch
POD_NAME=`kubectl get pods -n $ENV_NAME | grep pod_name_part- | head -n 1 | awk '{print $1}'`; print $POD_NAME
kubectl exec -n $ENV_NAME $POD_NAME -- /app/appctl arg1 arg2
Last active
April 2, 2021 10:27
-
-
Save r3code/e3c588a94a1c4fb86965c1f4d4f1c295 to your computer and use it in GitHub Desktop.
Execute command in Kubernetis Pod
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment