Skip to content

Commit 580fbfe

Browse files
committed
feat: add custom user cmd arg on img upload
1 parent 96963e4 commit 580fbfe

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

remote-img-load.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
#!/bin/bash
22

33
readonly HOST="$1"
4+
readonly USER=${2:-ubuntu}
45
if [ -z "${HOST}" ]; then
56
echo "Usage: ./remote-img-load.sh <host>"
67
exit 1
78
fi
89

910
./build-image.sh
1011
echo "Transfering image to ${HOST} ..."
11-
docker save jembi/platform:latest | bzip2 | ssh ubuntu@"${HOST}" docker load
12+
docker save jembi/platform:latest | bzip2 | ssh "${USER}@${HOST}" docker load
1213
echo "Image transfered"

0 commit comments

Comments
 (0)