IPv6 OpenSuse Apache2: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
(Die Seite wurde neu angelegt: „=Installation= *zypper install apache2 =Konfiguration=“) |
|||
| (3 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 2: | Zeile 2: | ||
*zypper install apache2 | *zypper install apache2 | ||
=Konfiguration= | =Konfiguration= | ||
| + | *mkdir -p /srv/www/vhosts/opensuse.linuggs.de | ||
| + | =Konfiguration= | ||
| + | *cat /etc/apache2/vhosts.d/vhost.conf | ||
| + | <pre> | ||
| + | <VirtualHost [2a02:24d8:71:2445::102]:80> | ||
| + | ServerAdmin webmaster@opensuse.linuggs.de | ||
| + | ServerName opensuse.linuggs.de | ||
| + | DocumentRoot /srv/www/vhosts/opensuse.linuggs.de | ||
| + | ErrorLog /var/log/apache2/opensuse.linuggs.de-error_log | ||
| + | CustomLog /var/log/apache2/opensuse.linuggs.de-access_log combined | ||
| + | HostnameLookups Off | ||
| + | UseCanonicalName Off | ||
| + | ServerSignature On | ||
| + | <Directory "/srv/www/vhosts/opensuse.linuggs.de"> | ||
| + | Options Indexes FollowSymLinks | ||
| + | AllowOverride None | ||
| + | <IfModule !mod_access_compat.c> | ||
| + | Require all granted | ||
| + | </IfModule> | ||
| + | <IfModule mod_access_compat.c> | ||
| + | Order allow,deny | ||
| + | Allow from all | ||
| + | </IfModule> | ||
| + | </Directory> | ||
| + | </VirtualHost> | ||
| + | </pre> | ||
| + | |||
| + | =Webseite= | ||
| + | *cat /srv/www/vhosts/opensuse.linuggs.de/index.html | ||
| + | <pre> | ||
| + | <!DOCTYPE html> | ||
| + | <html lang="en"> | ||
| + | <head> | ||
| + | <meta charset="UTF-8"> | ||
| + | <meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
| + | <title>Webserver von opensuse.linuggs.de</title> | ||
| + | </head> | ||
| + | <body> | ||
| + | <h1>Willkommen auf dem Webserver von opensuse.linuggs.de</h1> | ||
| + | <p>IP-Adresse: 2a02:24d8:71:2445::102</p> | ||
| + | </body> | ||
| + | </html> | ||
| + | </pre> | ||
| + | =Firewall freischalten= | ||
| + | *firewall-cmd --zone=public --add-port=80/tcp --permanent | ||
| + | *firewall-cmd --reload | ||
| + | =Zugriff= | ||
| + | *http://opensuse.linuggs.de | ||
| + | *http://[[2a02:24d8:71:2445::102]] | ||
Aktuelle Version vom 13. Januar 2024, 12:50 Uhr
Installation
- zypper install apache2
Konfiguration
- mkdir -p /srv/www/vhosts/opensuse.linuggs.de
Konfiguration
- cat /etc/apache2/vhosts.d/vhost.conf
<VirtualHost [2a02:24d8:71:2445::102]:80>
ServerAdmin webmaster@opensuse.linuggs.de
ServerName opensuse.linuggs.de
DocumentRoot /srv/www/vhosts/opensuse.linuggs.de
ErrorLog /var/log/apache2/opensuse.linuggs.de-error_log
CustomLog /var/log/apache2/opensuse.linuggs.de-access_log combined
HostnameLookups Off
UseCanonicalName Off
ServerSignature On
<Directory "/srv/www/vhosts/opensuse.linuggs.de">
Options Indexes FollowSymLinks
AllowOverride None
<IfModule !mod_access_compat.c>
Require all granted
</IfModule>
<IfModule mod_access_compat.c>
Order allow,deny
Allow from all
</IfModule>
</Directory>
</VirtualHost>
Webseite
- cat /srv/www/vhosts/opensuse.linuggs.de/index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Webserver von opensuse.linuggs.de</title>
</head>
<body>
<h1>Willkommen auf dem Webserver von opensuse.linuggs.de</h1>
<p>IP-Adresse: 2a02:24d8:71:2445::102</p>
</body>
</html>
Firewall freischalten
- firewall-cmd --zone=public --add-port=80/tcp --permanent
- firewall-cmd --reload