This commit is contained in:
Aleksander Cynarski 2017-04-13 22:19:44 +02:00
parent 462f6275d8
commit 6f4641403a

View File

@ -1,5 +1,7 @@
#!/bin/bash
rname=$(date +%s | sha256sum | base64 | head -c 32)
if [ -z $GOGS_ROOT_URL ]
then
printf "Need to set GOGS_ROOT_URL environment variable\n" >&2
@ -50,7 +52,7 @@ if [ -f $HOME/.ssh/$GOGS_REPO-sended ]; then
printf "Key sended\n" >&2
else
printf "Prepare to send key\n" >&2
title=$(hostname)@$(whoami)
title=$rname@$(hostname)
printf "title $title\n" >&2
deploykey=$(cat $HOME/.ssh/gogs.pub)
body=$(cat <<-END