blog/sync.sh

81 lines
1.6 KiB
Bash
Raw Permalink Normal View History

2021-11-08 21:07:31 +00:00
#! /usr/bin/env bash
BASH_FILE="$(realpath "${BASH_SOURCE[0]}")"
BASH_ROOT="$(dirname "${BASH_FILE}")"
2020-04-12 01:13:28 +00:00
2022-04-18 12:19:47 +00:00
OUTPUT='out'
2020-04-12 01:13:28 +00:00
2020-12-21 10:31:41 +00:00
function rs { echo; \
echo "${2} @ ${3} : ${1}"; \
ssh -o 'LogLevel Error' -p ${1} "${2}@${3}" \
2021-11-08 21:07:31 +00:00
df --human-readable .
2020-12-21 10:31:41 +00:00
}
2020-04-12 01:13:28 +00:00
function rs {
2020-04-12 01:21:22 +00:00
echo "${2} @ ${3} : ${1}"
2020-04-12 01:13:28 +00:00
rsync --verbose --progress \
2020-04-12 03:44:29 +00:00
--rsh "ssh -o 'LogLevel Error' -p ${1}" \
2020-04-12 01:13:28 +00:00
--archive --checksum --delete-before \
2021-11-08 21:07:31 +00:00
"${BASH_ROOT}/${OUTPUT}/" \
2020-04-14 00:01:30 +00:00
"${2}@${3}:${4}/" \
> /dev/null
2020-04-12 01:13:28 +00:00
}
2020-12-21 11:33:04 +00:00
echo
2020-12-21 10:31:41 +00:00
2020-12-21 11:33:04 +00:00
echo 'FastCGI & PHP / .'
2020-12-21 10:31:41 +00:00
# .cgi .lua .pl .py .sh /cgi-bin .php
2020-04-12 06:59:47 +00:00
rs 22 'mspe' 'envs.net' 'public_html'
2021-03-22 13:22:36 +00:00
# /cgi-bin
rs 22 'mspe' 'insomnia247.nl' 'public_html/mspe.insomnia247.nl'
2020-12-21 10:31:41 +00:00
# .cgi .lua .pl .py .sh /cgi-bin .php
2020-04-12 06:59:47 +00:00
rs 22 'mspe' 'tilde.team' 'public_html'
2021-02-05 10:05:09 +00:00
# .cgi .lua .pl .py .sh /cgi-bin .php
rs 22 'mspe' 'tilde.cafe' 'public_html'
2020-12-21 10:31:41 +00:00
# .cgi .php
2020-04-12 06:59:47 +00:00
rs 22 'mspe' 'tilde.institute' 'public_html'
2020-12-21 11:33:04 +00:00
echo 'FastCGI & PHP / ~'
2020-12-21 10:31:41 +00:00
2020-12-21 11:33:04 +00:00
# .cgi .lua .pl .py .sh /cgi-bin .php
2020-12-21 10:31:41 +00:00
rs 22 'mspe' 'tilde.club' 'public_html'
2020-12-21 11:33:04 +00:00
echo
echo 'PHP → CGI / .'
2020-12-21 10:31:41 +00:00
2020-12-21 11:33:04 +00:00
# Python 3.5
rs 9022 'mspe' 'remotes.club' 'web'
echo 'PHP → CGI / ~'
2020-12-21 10:31:41 +00:00
rs 22 'mspe' 'thunix.net' 'public_html'
rs 22 'mspe' 'aussies.space' 'public_html'
2020-12-21 11:33:04 +00:00
echo 'PHP → CGI / http'
2020-04-12 06:59:47 +00:00
2020-12-21 11:33:04 +00:00
# Python 3.4
rs 22 'mspe' 'ctrl-c.club' 'public_html'
2020-04-12 06:59:47 +00:00
2020-12-21 11:33:04 +00:00
echo
2020-04-12 06:59:47 +00:00
2020-12-21 11:33:04 +00:00
echo 'ø / .'
2020-04-13 04:41:28 +00:00
2020-12-21 10:31:41 +00:00
rs 22 'mspe' 'fr.tild3.org' 'public_html'
2020-12-21 11:33:04 +00:00
echo 'ø / ~'
2020-12-21 10:31:41 +00:00
2020-04-12 06:59:47 +00:00
rs 22 'mspe' 'tilde.town' 'public_html'
2020-09-08 18:25:36 +00:00
rs 22 'mspe' 'tilde.fun' 'html'
2021-02-05 10:05:09 +00:00
rs 22 'mspe' 'tilde.pink' 'public_html'
rs 22 'mspe' 'heathens.club' 'www'
2020-07-31 19:31:49 +00:00
rs 22 'mspe' 'dimension.sh' 'public_html'
2022-04-18 13:03:10 +00:00
rs 22 'mspe' 'southlondon.cc' 'public_html'
2020-04-12 03:39:48 +00:00
rs 22 'mspe' 'squiggle.city' 'public_html'
2020-04-13 05:47:03 +00:00
2020-12-21 11:33:04 +00:00
echo 'ø / http'
2020-04-13 05:47:03 +00:00
2022-04-18 13:03:10 +00:00
# rs 22 'mspe' 'rw.rs' 'public_html'
2021-01-06 23:38:54 +00:00
2021-01-07 01:00:39 +00:00
2021-11-08 20:37:41 +00:00
rs 22 'mspe' 'tilde.guru' 'public_html'