Pelican - 1-Klick Install Script Version
Verwendung Datei erstellen: Script einfügen. Ausführbar machen : Starten Voraussetzungen Nach der Installation Panel erreichbar unter: Hier noch einmal das Script - komplettes …
#!/bin/bash # =========================================================# Pelican Panel Auto Installer (Ubuntu 24.04) by rumpel (gameserver-install.de)# =========================================================# Dieses Script installiert automatisch:# - NGINX# - MariaDB# - PHP 8.3# - Composer# - Pelican Panel# - SSL via Let's Encrypt# ========================================================= clear echo "======================================="echo " Pelican Auto Installer"echo "=======================================" read -p "Domain eingeben (z.B. panel.domain.de): " DOMAINread -p "Admin E-Mail eingeben: " EMAILread -s -p "MariaDB Passwort für Pelican DB: " DBPASSecho "" # =========================================================# System Update# ========================================================= apt update && apt upgrade -y # =========================================================# Benötigte Pakete# ========================================================= apt install -y software-properties-common curl apt-transport-https \ca-certificates gnupg unzip tar nginx mariadb-server certbot \python3-certbot-nginx redis-server add-apt-repository ppa:ondrej/php -yapt update # =========================================================# PHP 8.3 installieren# ========================================================= apt install -y php8.3 php8.3-cli php8.3-fpm php8.3-gd \php8.3-mysql php8.3-mbstring php8.3-bcmath php8.3-xml \php8.3-curl php8.3-zip php8.3-intl php8.3-sqlite3 # =========================================================# Composer installieren# ========================================================= curl -sS https://getcomposer.org/installer | phpmv composer.phar /usr/local/bin/composer # =========================================================# MariaDB konfigurieren# ========================================================= systemctl enable mariadbsystemctl start mariadb mysql -u root <<MYSQL_SCRIPTCREATE DATABASE pelican;CREATE USER 'pelican'@'127.0.0.1' IDENTIFIED BY '${DBPASS}';GRANT ALL PRIVILEGES ON pelican.* TO 'pelican'@'127.0.0.1';FLUSH PRIVILEGES;MYSQL_SCRIPT # =========================================================# Pelican herunterladen# ========================================================= mkdir -p /var/www/pelicancd /var/www/pelican || exit curl -L https://github.com/pelican-dev/panel/releases/latest/download/panel.tar.gz | tar -xzv # =========================================================# Composer Dependencies# ========================================================= COMPOSER_ALLOW_SUPERUSER=1 composer install --no-dev --optimize-autoloader cp .env.example .env # =========================================================# Environment konfigurieren# ========================================================= php artisan key:generate --force sed -i "s|APP_URL=.*|APP_URL=https://${DOMAIN}|g" .envsed -i "s|DB_DATABASE=.*|DB_DATABASE=pelican|g" .envsed -i "s|DB_USERNAME=.*|DB_USERNAME=pelican|g" .envsed -i "s|DB_PASSWORD=.*|DB_PASSWORD=${DBPASS}|g" .env # Redis aktivierensed -i "s|CACHE_STORE=file|CACHE_STORE=redis|g" .envsed -i "s|SESSION_DRIVER=file|SESSION_DRIVER=redis|g" .envsed -i "s|QUEUE_CONNECTION=sync|QUEUE_CONNECTION=redis|g" .env # =========================================================# Datenbank migrieren# ========================================================= php artisan migrate --seed --force # =========================================================# Rechte setzen# ========================================================= chown -R www-data:www-data /var/www/pelicanchmod -R 755 storage/* bootstrap/cache/ # =========================================================# Admin User erstellen# ========================================================= echo ""echo "======================================="echo "Admin Benutzer erstellen"echo "=======================================" php artisan p:user:make # =========================================================# NGINX konfigurieren# ========================================================= cat > /etc/nginx/sites-available/pelican.conf <<EOFserver { listen 80; server_name ${DOMAIN}; root /var/www/pelican/public; index index.php; client_max_body_size 100m; access_log /var/log/nginx/pelican.access.log; error_log /var/log/nginx/pelican.error.log; location / { try_files \$uri \$uri/ /index.php?\$query_string; } location ~ \.php$ { fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_pass unix:/run/php/php8.3-fpm.sock; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name; }}EOF ln -sf /etc/nginx/sites-available/pelican.conf /etc/nginx/sites-enabled/pelican.conf nginx -tsystemctl restart nginx # =========================================================# SSL installieren# ========================================================= certbot --nginx --non-interactive --agree-tos \-m ${EMAIL} -d ${DOMAIN} --redirect # =========================================================# Queue Worker# ========================================================= cat > /etc/systemd/system/pelican.service <<EOF[Unit]Description=Pelican Queue WorkerAfter=redis-server.service [Service]User=www-dataGroup=www-dataRestart=alwaysExecStart=/usr/bin/php /var/www/pelican/artisan queue:work --sleep=3 --tries=3 [Install]WantedBy=multi-user.targetEOF systemctl daemon-reloadsystemctl enable pelicansystemctl start pelican # =========================================================# Cronjob# ========================================================= (crontab -l 2>/dev/null; echo "* * * * * php /var/www/pelican/artisan schedule:run >> /dev/null 2>&1") | crontab - # =========================================================# Fertig# ========================================================= clear echo "======================================="echo "Pelican Installation abgeschlossen!"echo "======================================="echo ""echo "Panel URL: https://${DOMAIN}"echo ""echo "Pfad: /var/www/pelican"echo ""echo "NGINX Status:"systemctl status nginx --no-pagerecho ""echo "PHP-FPM Status:"systemctl status php8.3-fpm --no-pagerecho ""echo "Pelican Queue Status:"systemctl status pelican --no-pagerVerwendung
Datei erstellen:
nano pelican-install.shScript einfügen.
Ausführbar machen :
chmod +x pelican-install.shStarten
sudo bash pelican-install.shVoraussetzungen
- Ubuntu 24.04
- Root Zugriff
- Domain zeigt bereits auf den Server
- Ports 80 & 443 offen
Nach der Installation
Panel erreichbar unter:
https://deine-domain.deHier noch einmal das Script - komplettes Pelican + Wings Auto Installer
#!/bin/bash # =========================================================# Pelican Komplett Installer (Panel + Wings)# Ubuntu 24.04 LTS# ========================================================= set -e clear echo "=================================================="echo " Pelican Komplett Auto Installer"echo "==================================================" read -p "Panel Domain (panel.domain.de): " PANEL_DOMAINread -p "Node Domain (node.domain.de): " NODE_DOMAINread -p "Admin E-Mail: " EMAILread -s -p "MariaDB Passwort: " DBPASSecho "" # =========================================================# Variablen# ========================================================= PANEL_PATH="/var/www/pelican" # =========================================================# System Update# ========================================================= apt update && apt upgrade -y timedatectl set-timezone Europe/Berlin # =========================================================# Firewall# ========================================================= apt install -y ufw ufw allow 22ufw allow 80ufw allow 443ufw allow 8080ufw --force enable # =========================================================# Docker installieren# ========================================================= apt install -y ca-certificates curl gnupg lsb-release install -m 0755 -d /etc/apt/keyrings curl -fsSL https://download.docker.com/linux/ubuntu/gpg | \gpg --dearmor -o /etc/apt/keyrings/docker.gpg chmod a+r /etc/apt/keyrings/docker.gpg echo \"deb [arch=$(dpkg --print-architecture) \signed-by=/etc/apt/keyrings/docker.gpg] \https://download.docker.com/linux/ubuntu \$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \tee /etc/apt/sources.list.d/docker.list > /dev/null apt update apt install -y docker-ce docker-ce-cli containerd.io \docker-buildx-plugin docker-compose-plugin systemctl enable dockersystemctl start docker # =========================================================# Pakete installieren# ========================================================= apt install -y software-properties-common apt-transport-https \ca-certificates gnupg unzip tar nginx mariadb-server \redis-server certbot python3-certbot-nginx add-apt-repository ppa:ondrej/php -y apt update # =========================================================# PHP 8.3# ========================================================= apt install -y php8.3 php8.3-cli php8.3-fpm php8.3-gd \php8.3-mysql php8.3-mbstring php8.3-bcmath \php8.3-xml php8.3-curl php8.3-zip \php8.3-intl php8.3-sqlite3 # =========================================================# Composer# ========================================================= curl -sS https://getcomposer.org/installer | phpmv composer.phar /usr/local/bin/composer # =========================================================# MariaDB# ========================================================= systemctl enable mariadbsystemctl start mariadb mysql -u root <<MYSQL_SCRIPTCREATE DATABASE pelican;CREATE USER 'pelican'@'127.0.0.1' IDENTIFIED BY '${DBPASS}';GRANT ALL PRIVILEGES ON pelican.* TO 'pelican'@'127.0.0.1';FLUSH PRIVILEGES;MYSQL_SCRIPT # =========================================================# Pelican Panel# ========================================================= mkdir -p ${PANEL_PATH} cd ${PANEL_PATH} curl -L https://github.com/pelican-dev/panel/releases/latest/download/panel.tar.gz | tar -xzv COMPOSER_ALLOW_SUPERUSER=1 composer install \--no-dev --optimize-autoloader cp .env.example .env php artisan key:generate --force sed -i "s|APP_URL=.*|APP_URL=https://${PANEL_DOMAIN}|g" .envsed -i "s|DB_DATABASE=.*|DB_DATABASE=pelican|g" .envsed -i "s|DB_USERNAME=.*|DB_USERNAME=pelican|g" .envsed -i "s|DB_PASSWORD=.*|DB_PASSWORD=${DBPASS}|g" .env sed -i "s|CACHE_STORE=file|CACHE_STORE=redis|g" .envsed -i "s|SESSION_DRIVER=file|SESSION_DRIVER=redis|g" .envsed -i "s|QUEUE_CONNECTION=sync|QUEUE_CONNECTION=redis|g" .env php artisan migrate --seed --force chown -R www-data:www-data ${PANEL_PATH}chmod -R 755 storage/* bootstrap/cache/ # =========================================================# Admin User# ========================================================= echo ""echo "=================================================="echo "Admin User erstellen"echo "==================================================" php artisan p:user:make # =========================================================# Queue Worker# ========================================================= cat > /etc/systemd/system/pelican.service <<EOF[Unit]Description=Pelican Queue WorkerAfter=redis-server.service [Service]User=www-dataGroup=www-dataRestart=alwaysExecStart=/usr/bin/php ${PANEL_PATH}/artisan queue:work --sleep=3 --tries=3 [Install]WantedBy=multi-user.targetEOF systemctl daemon-reloadsystemctl enable pelicansystemctl start pelican # =========================================================# Cronjob# ========================================================= (crontab -l 2>/dev/null; echo "* * * * * php ${PANEL_PATH}/artisan schedule:run >> /dev/null 2>&1") | crontab - # =========================================================# NGINX Panel# ========================================================= cat > /etc/nginx/sites-available/pelican.conf <<EOFserver { listen 80; server_name ${PANEL_DOMAIN}; root ${PANEL_PATH}/public; index index.php; client_max_body_size 100m; location / { try_files \$uri \$uri/ /index.php?\$query_string; } location ~ \.php$ { fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_pass unix:/run/php/php8.3-fpm.sock; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name; }}EOF # =========================================================# NGINX Wings Reverse Proxy# ========================================================= cat > /etc/nginx/sites-available/wings.conf <<EOFserver { listen 80; server_name ${NODE_DOMAIN}; location / { proxy_pass http://127.0.0.1:8080; proxy_set_header Host \$host; proxy_set_header X-Real-IP \$remote_addr; proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto \$scheme; }}EOF ln -sf /etc/nginx/sites-available/pelican.conf /etc/nginx/sites-enabled/pelican.confln -sf /etc/nginx/sites-available/wings.conf /etc/nginx/sites-enabled/wings.conf rm -f /etc/nginx/sites-enabled/default nginx -tsystemctl restart nginx # =========================================================# SSL# ========================================================= certbot --nginx --non-interactive --agree-tos \-m ${EMAIL} \-d ${PANEL_DOMAIN} \-d ${NODE_DOMAIN} \--redirect # =========================================================# Wings Installation# ========================================================= mkdir -p /etc/pelican curl -L -o /usr/local/bin/wings \https://github.com/pelican-dev/wings/releases/latest/download/wings_linux_amd64 chmod +x /usr/local/bin/wings # =========================================================# Wings Config# ========================================================= cat > /etc/pelican/config.yml <<EOFdebug: false uuid: CHANGE_MEtoken_id: CHANGE_MEtoken: CHANGE_ME api: host: 0.0.0.0 port: 8080 ssl: enabled: false system: data: /var/lib/pelican/volumes sftp: bind_port: 2022EOF # =========================================================# Wings Ordner# ========================================================= mkdir -p /var/lib/pelican/volumesmkdir -p /var/lib/pelican/archives # =========================================================# Wings Service# ========================================================= cat > /etc/systemd/system/wings.service <<EOF[Unit]Description=Pelican Wings DaemonAfter=docker.serviceRequires=docker.service [Service]User=rootWorkingDirectory=/etc/pelicanLimitNOFILE=4096PIDFile=/var/run/wings/daemon.pid ExecStart=/usr/local/bin/wingsRestart=on-failureStartLimitInterval=180StartLimitBurst=30RestartSec=5s [Install]WantedBy=multi-user.targetEOF systemctl daemon-reloadsystemctl enable wingssystemctl start wings # =========================================================# Fertig# ========================================================= clear echo "=================================================="echo " INSTALLATION ABGESCHLOSSEN"echo "=================================================="echo ""echo "Panel URL:"echo "https://${PANEL_DOMAIN}"echo ""echo "Wings Node:"echo "https://${NODE_DOMAIN}"echo ""echo "=================================================="echo "WICHTIG:"echo "=================================================="echo ""echo "1. Gehe ins Pelican Admin Panel"echo "2. Node erstellen"echo "3. Wings Konfiguration generieren"echo "4. Datei ersetzen:"echo ""echo "/etc/pelican/config.yml"echo ""echo "5. Danach:"echo "systemctl restart wings"echo ""echo "=================================================="echo "Services:"echo "==================================================" systemctl --no-pager status nginxsystemctl --no-pager status mariadbsystemctl --no-pager status redis-serversystemctl --no-pager status pelicansystemctl --no-pager status wingsDas war es auch schon wieder viel Spaß und gutes gelingen mit dem Pelican Webinterface.
LG
rumpel ;) :at:
War das hilfreich?
Passend dazu
Minecraft - PlotSquared Plugin muss man nicht kaufen man muss es nur kompilieren...Selbst kompilieren Du brauchst nur ein JDK 21 (z. B. von Adoptium/Temurin). Gradle musst du nicht installieren, das ist im Projekt enthalten.WireGuard-Tunnel zwischen root und Heimserver...Hier ist eine Schritt-für-Schritt-Anleitung, um einen WireGuard-Tunnel zwischen deinem Root-Server und deinem Heimserver einzurichten.Ark Asa - Clustern auf unterschiedlichen Servern (unterschiedliche Netzwerke)Für Ubuntu Linux 24.04 LTS ist Syncthing tatsächlich die stabilste und ausfallsicherste Methode, wenn du zwei getrennte Server zusammenschließen willst.DUNE Awakening - GameServer - Manager LinuxDUNE AWAKENING — Eigener Server leicht gemacht! Du willst deinen eigenen Dune Awakening Dedicated Server hosten — ohne technisches Vorwissen, ohne Windows ?
Nicht gefunden, was du suchst?Deine Frage ist nicht dabei? Frag einfach im Support-Forum.Frage stellen