Compare commits
No commits in common. "20075ec132803e88ecd3f311695db2ec40ab01be" and "6f06eba56e837f9166cd7a68f5c3c99aee25de1a" have entirely different histories.
20075ec132
...
6f06eba56e
|
@ -1,2 +0,0 @@
|
||||||
config
|
|
||||||
config-urls
|
|
10
README.md
10
README.md
|
@ -2,11 +2,5 @@ All scripts require an argument to specify 'local' or 'remote'.
|
||||||
|
|
||||||
If none given script will exit.
|
If none given script will exit.
|
||||||
|
|
||||||
Using 'local' will
|
Scripts that operate on local/remote servers simultaneously (e.g,
|
||||||
set the source server URL to `$local_url`.
|
`wp-duplicarte.sh`) do not require this argument.sh
|
||||||
set the destination server URL to `$remote_url`.
|
|
||||||
|
|
||||||
Using 'remote' will
|
|
||||||
set the source server URL to `$remote_url`.
|
|
||||||
set the destination server URL to `$local_url`.
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
export local_url=''
|
|
||||||
export remote_url=''
|
|
18
run.sh
18
run.sh
|
@ -1,18 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
. ./config-urls
|
|
||||||
|
|
||||||
if [ "$1" = 'local' ] ; then
|
|
||||||
( export local_url="$local_url"; \
|
|
||||||
export remote_url="$remote_url"; \
|
|
||||||
cat config "$2" \
|
|
||||||
) | ssh root@"$local_url" -T /bin/sh
|
|
||||||
elif [ "$1" = 'remote' ] ; then
|
|
||||||
( export local_url="$remote_url"; \
|
|
||||||
export remote_url="$local_url"; \
|
|
||||||
cat config "$2" \
|
|
||||||
) | ssh root@"$remote_url" -T /bin/sh
|
|
||||||
else
|
|
||||||
echo "error: must specify local or remote"
|
|
||||||
fi
|
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
|
||||||
apt upgrade || exit 10
|
apt upgrade || exit 10
|
||||||
apt install -y tmux ufw || exit 15
|
apt install -y tmux ufw || exit 15
|
||||||
|
|
||||||
ufw allow ssh || exit 20
|
ufw allow ssh || exit 20
|
||||||
yes | ufw enable
|
ufw enable
|
||||||
|
|
Loading…
Reference in New Issue