2020-06-01 16:01:26 -04:00
|
|
|
run_remote() {
|
2020-08-21 10:33:56 -04:00
|
|
|
requestedcmd="'$*'"
|
2020-08-21 16:39:37 -04:00
|
|
|
echo Running $requestedcmd from https://$mgr/confluent-public/os/$profile/scripts/
|
2020-06-01 16:01:26 -04:00
|
|
|
cd $(mktemp -d)
|
|
|
|
curl -f https://$mgr/confluent-public/os/$profile/scripts/$1 > $1
|
|
|
|
chmod +x $1
|
2020-07-15 15:22:27 -04:00
|
|
|
cmd=$1
|
|
|
|
shift
|
2020-07-13 17:08:38 -04:00
|
|
|
./$cmd $*
|
2020-08-21 10:33:56 -04:00
|
|
|
echo "$requestedcmd exited with code $?"
|
2020-06-01 16:01:26 -04:00
|
|
|
cd -
|
|
|
|
}
|
|
|
|
|
|
|
|
run_remote_python() {
|
2020-08-20 16:20:02 -04:00
|
|
|
echo -n Running python script "'$*'" from https://$mgr/confluent-public/os/$profile/scripts/
|
2020-06-01 16:01:26 -04:00
|
|
|
cd $(mktemp -d)
|
|
|
|
curl -f https://$mgr/confluent-public/os/$profile/scripts/$1 > $1
|
2020-07-13 17:08:38 -04:00
|
|
|
python3 $*
|
2020-08-20 16:20:02 -04:00
|
|
|
echo "'$*' exited with code $?"
|
2020-06-01 16:01:26 -04:00
|
|
|
cd -
|
|
|
|
}
|