- Add login.php, auth.php, and auth.config.php for manual access control - Create logout.php for session management - Add .htaccess to route /manual/ requests to PHP-based index - Create logs directory and access.log for tracking manual visits - Update deployment script to upload PHP authentication files and logs - Add rewrite rule to ensure /manual/ uses login-guarded PHP version - Keep static index.html as fallback for direct
60 lines
1.3 KiB
Bash
Executable File
60 lines
1.3 KiB
Bash
Executable File
#!/bin/bash
|
|
# Deploy SummitWave landing page to Hetzner public_html via SFTP
|
|
|
|
# === CONFIGURATION ===
|
|
SERVER="www269.your-server.de"
|
|
USER="summitb"
|
|
REMOTE_DIR="public_html"
|
|
LOCAL_DIR="$(dirname \"$0\")/src"
|
|
|
|
# === UPLOAD ===
|
|
echo "Uploading website files to $USER@$SERVER:$REMOTE_DIR ..."
|
|
sftp $USER@$SERVER <<EOF
|
|
cd $REMOTE_DIR
|
|
put -r $LOCAL_DIR/index.html
|
|
put -r $LOCAL_DIR/impressum.html
|
|
put -r $LOCAL_DIR/robots.txt
|
|
put -r $LOCAL_DIR/sitemap.xml
|
|
put -r $LOCAL_DIR/.htaccess
|
|
|
|
# Hauptbilder der Landingpage
|
|
mkdir img
|
|
cd img
|
|
put -r $LOCAL_DIR/img/*
|
|
cd ..
|
|
|
|
# Manual (HTML + Bilder + PHP + Logs)
|
|
mkdir manual
|
|
cd manual
|
|
|
|
# statische HTML-Variante (Fallback / Direktaufrufe)
|
|
put -r $LOCAL_DIR/manual/index.html
|
|
|
|
# PHP-basierte Manual-/Login-Dateien
|
|
put -r $LOCAL_DIR/manual/.htaccess
|
|
put -r $LOCAL_DIR/manual/index.php
|
|
put -r $LOCAL_DIR/manual/login.php
|
|
put -r $LOCAL_DIR/manual/auth.config.php
|
|
put -r $LOCAL_DIR/manual/auth.php
|
|
put -r $LOCAL_DIR/manual/logout.php
|
|
|
|
# Manual-Bilder
|
|
put -r $LOCAL_DIR/manual/beacon-front.jpg
|
|
mkdir img
|
|
cd img
|
|
put -r $LOCAL_DIR/manual/img/*
|
|
cd ..
|
|
|
|
# Log-Verzeichnis für Zugriffsprotokolle
|
|
mkdir logs
|
|
cd logs
|
|
put -r $LOCAL_DIR/manual/logs/access.log
|
|
cd ..
|
|
|
|
cd ..
|
|
bye
|
|
EOF
|
|
|
|
echo "Deployment complete. Visit your site to verify: http://summitwave.eu/"
|
|
|
|
# BiLqHib8s5Ag2FmL |