From f20223c36bef62f220f9b361385798d66e9ab9be Mon Sep 17 00:00:00 2001 From: notplants Date: Tue, 26 Jan 2021 17:05:13 +0100 Subject: [PATCH] Add test lines to end of raspi_master.yaml --- .gitignore | 4 ++++ build.sh | 5 +++++ deploy.sh | 5 +++++ fetch.sh | 1 + raspi_master.yaml | 19 +++++++++++++++++++ ssh.sh | 1 + 6 files changed, 35 insertions(+) create mode 100755 build.sh create mode 100755 deploy.sh create mode 100755 fetch.sh create mode 100755 ssh.sh diff --git a/.gitignore b/.gitignore index 94bde07..c55daa4 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,7 @@ raspi_0w.yaml raspi_2.yaml raspi_3.yaml raspi_4.yaml +*.img +vmdb2/* +.idea +vmdb2 diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..50b6850 --- /dev/null +++ b/build.sh @@ -0,0 +1,5 @@ +#!/usr/bin/env bash +WD=/home/notplants/computer/projects/peachcloud/image-specs +cd $WD/vmdb2 +sudo ./vmdb2 --verbose --rootfs-tarball=$WD/my_raspi.tar.gz --output $WD/my_raspi.img $WD/raspi_3.yaml --log $WD/my_raspi.log + diff --git a/deploy.sh b/deploy.sh new file mode 100755 index 0000000..e0a74ae --- /dev/null +++ b/deploy.sh @@ -0,0 +1,5 @@ +KEY_PATH=/home/notplants/.ssh/do_rsa + +rsync -avzh --exclude target --exclude .idea --exclude .git --exclude *.img -e "ssh -i $KEY_PATH" . root@165.227.141.30:/srv/image-specs/ + +ssh -i $KEY_PATH root@165.227.141.30 'cd /srv/image-specs; echo "hi"' diff --git a/fetch.sh b/fetch.sh new file mode 100755 index 0000000..dfb2f33 --- /dev/null +++ b/fetch.sh @@ -0,0 +1 @@ +scp -i /home/notplants/.ssh/do_rsa root@165.227.141.30:/srv/image-specs/raspi_3.img peach.img \ No newline at end of file diff --git a/raspi_master.yaml b/raspi_master.yaml index 1c670e9..2e92345 100644 --- a/raspi_master.yaml +++ b/raspi_master.yaml @@ -132,3 +132,22 @@ steps: - shell: | rm "${ROOT?}/etc/resolv.conf" root-fs: / + + + - create-file: /srv/hi.txt + trailing-newline: '1' + contents: | + hello + here + are + some + lines + unless: rootfs_unpacked + + + - shell: | + echo "does this work?" > /srv/turtle.txt + + echo "and also this?" > /srv/cat.txt + + root-fs: / \ No newline at end of file diff --git a/ssh.sh b/ssh.sh new file mode 100755 index 0000000..2fd3ec3 --- /dev/null +++ b/ssh.sh @@ -0,0 +1 @@ +ssh -i /home/notplants/.ssh/do_rsa root@165.227.141.30 \ No newline at end of file