2020-11-04 03:52:42 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
case "$1" in
|
|
|
|
seirdy.one)
|
|
|
|
login='deploy@seirdy.one' # user@host
|
|
|
|
www_prefix="$login:/var/www/seirdy.one"
|
|
|
|
gemini_prefix="$login:/srv/gemini/seirdy.one"
|
|
|
|
;;
|
|
|
|
envs.net)
|
|
|
|
login='seirdy@envs.net'
|
|
|
|
www_prefix="$login:/home/seirdy/public_html"
|
|
|
|
gemini_prefix="$login:/home/seirdy/public_gemini"
|
|
|
|
;;
|
|
|
|
localhost)
|
2020-11-05 23:49:44 +00:00
|
|
|
www_prefix='/tmp/www/seeirdy.one'
|
2020-11-04 03:52:42 +00:00
|
|
|
gemini_prefix='/tmp/gemini/serve/seirdy.one'
|
2020-11-05 23:49:44 +00:00
|
|
|
mkdir -p "$www_prefix" "$gemini_prefix"
|
2020-11-04 03:52:42 +00:00
|
|
|
;;
|
|
|
|
*)
|
|
|
|
echo 'must supply hostname' >&2
|
|
|
|
exit 1
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
2020-11-05 23:49:44 +00:00
|
|
|
rsync -rvzP --exclude "gemini" --exclude "*.gmi" public/ "$www_prefix/"
|
2020-11-04 03:52:42 +00:00
|
|
|
rsync -rvzP --exclude "*.html" public/gemini/ public/about public/posts "$gemini_prefix/"
|
2020-11-19 01:02:24 +00:00
|
|
|
rsync -rvzP public/posts/gemini.xml "$gemini_prefix/feed.xml"
|