webserver-config/quickstart.sh

27 lines
636 B
Bash
Raw Normal View History

2024-10-14 21:56:48 +00:00
#!/bin/bash
2024-10-14 22:59:19 +00:00
# Script to quickly set up a new server
# Download and install by running:
# curl -sSL https://raw.githubusercontent.com/joby-lol/webserver-config/refs/heads/main/quickstart.sh | bash
if [ "$EUID" -ne 0 ]; then
echo "Please run as root or with sudo"
exit
fi
2024-10-14 21:56:48 +00:00
# Update package list
sudo apt update
# Install curl and git
2024-10-14 22:02:18 +00:00
sudo apt install -y git
2024-10-14 21:56:48 +00:00
# Clone the repository
git clone https://github.com/joby-lol/webserver-config.git
# Change to the repository directory
cd webserver-config
# Execute install-server.sh
sudo ./install-server.sh
2024-10-14 21:59:23 +00:00
echo "Server setup complete. Use 'sudo ./add_site.sh' to add new sites."