mirror of
https://github.com/myvesta/vesta
synced 2025-08-21 13:54:28 -07:00
Add WordFence CLI installation script
This commit is contained in:
parent
5fb7862b39
commit
35653eec54
2 changed files with 42 additions and 0 deletions
|
@ -27,6 +27,11 @@ if [ -z "$user" ]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ ! -f "/usr/local/vesta/bin/v-wf-malware-hyperscan-with-remediate" ]; then
|
||||||
|
echo "= WordFence CLI is not installed. Installing..."
|
||||||
|
/usr/local/vesta/bin/v-install-wordfence-cli
|
||||||
|
fi
|
||||||
|
|
||||||
# absolute paths to maintenance scripts, in desired order
|
# absolute paths to maintenance scripts, in desired order
|
||||||
declare -a tasks=(
|
declare -a tasks=(
|
||||||
"/usr/local/vesta/bin/v-change-database-password-for-wordpress"
|
"/usr/local/vesta/bin/v-change-database-password-for-wordpress"
|
||||||
|
|
|
@ -0,0 +1,37 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# info: Script for installing WordFence CLI
|
||||||
|
# options: NONE
|
||||||
|
|
||||||
|
if ! command -v git &> /dev/null; then
|
||||||
|
echo "= Git is not installed. Installing..."
|
||||||
|
apt-get update > /dev/null 2>&1
|
||||||
|
apt-get install -y git
|
||||||
|
fi
|
||||||
|
|
||||||
|
cd /root
|
||||||
|
|
||||||
|
if [ ! -d "myvesta-wordfence-cli" ]; then
|
||||||
|
git clone https://github.com/isscbta/myvesta-wordfence-cli.git
|
||||||
|
cd ~/myvesta-wordfence-cli/
|
||||||
|
else
|
||||||
|
cd ~/myvesta-wordfence-cli/
|
||||||
|
git pull
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
echo "----------------------------------------------------------------"
|
||||||
|
echo ""
|
||||||
|
echo "Which Docker container do you want to install for WordFence CLI?"
|
||||||
|
echo "1. WordFence CLI official Docker container"
|
||||||
|
echo "2. WordFence CLI Docker container maintained by myVesta"
|
||||||
|
read -r -p "Enter your choice: " choice < /dev/tty
|
||||||
|
|
||||||
|
if [ "$choice" == "1" ]; then
|
||||||
|
bash wf-cli-install.sh
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$choice" == "2" ]; then
|
||||||
|
bash wf-cli-install-our-image.sh
|
||||||
|
fi
|
||||||
|
|
||||||
|
exit 0;
|
Loading…
Add table
Add a link
Reference in a new issue