* adding scripts for creation/spawning of gitian hosts
parent
7d5f65f6a3
commit
462e1290fb
@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
cd ../gitian-host || exit $?
|
||||||
|
|
||||||
|
if [ ! -f authorized_keys ]; then
|
||||||
|
echo "No authorized_keys file found in $PWD"
|
||||||
|
if [ -f ~/.ssh/id_rsa.pub ]; then
|
||||||
|
echo "Do you want to use ~/.ssh/id_rsa.pub? (y/n)"
|
||||||
|
read -r ANSWER
|
||||||
|
if [[ "$ANSWER" == "y" ]]; then
|
||||||
|
cp -v ~/.ssh/id_rsa.pub authorized_keys || exit $?
|
||||||
|
else
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
docker build --tag=gdm85/gitian-host . && \
|
||||||
|
echo "Gitian host image created successfully!" && \
|
||||||
|
echo "You can now spawn containers with spawn-gitian-host.sh"
|
@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
CID=$(docker run -d --privileged gitian-host) || exit $?
|
||||||
|
|
||||||
|
echo "You can now SSH into container $CID (IPv4 $IP) with user debian"
|
Loading…
Reference in New Issue