I'm using kubectl run
with environment parameters to create temporary docker containers for me (e.g. some forwarding for debugging purposes).
Since several weeks kubectl
is complaining about kubectl run
being deprecated. Unfortunately I can't find an appropriate replacement.
This is the old command:
$KUBECTL run -i -t --attach=false --image djfaze/port-forward --env="REMOTE_HOST=$REMOTE_HOST" --env="REMOTE_PORT=$REMOTE_PORT" $POD_NAME
When issuing this, kubectl
complains with this message:
kubectl run --generator=deployment/apps.v1beta1
is DEPRECATED and will be removed in a future version. Use kubectl create instead.
Any ideas how to replace this run command?