aboutsummarylogtreecommitdiffstats
path: root/kuttle
blob: 87cd27e99d260e8182397d2a6300aa5050a9fe27 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh
# Kuttle wrapper by kayrus (https://github.com/kayrus/kuttle)

if [ "$1" = "-p" ]; then
  # https://github.com/sshuttle/sshuttle/pull/401 introduced new port param and
  # quotes the complete command '/bin/sh -c pyscript', effectivly changing the
  # argument position and interpretation
  # sshuttle > v1.0.1
  eval exec kubectl exec -i $3 -- "$5"
else
  exec kubectl exec -i $1 -- /bin/sh -c "$3"
fi