Apache2 : Enable Userdir2025/09/08 |
|
Enable userdir. Users can create websites under their own home directory by this setting. |
|
| [1] | Configure Apache2. |
|
root@www:~# a2enmod userdir Enabling module userdir. To activate the new configuration, you need to run: systemctl restart apache2root@www:~# systemctl restart apache2 |
| [2] | Create a test page with a user and access to it from any client computer with Web browser. |
|
debian@www:~$
mkdir ~/public_html debian@www:~$ chmod 711 $HOME debian@www:~$ chmod 755 ~/public_html debian@www:~$ vi ~/public_html/index.html <html> <body> <h1 style="width: 100%; font-size: 40px; text-align: center;"> UserDir Test Page </h1> </body> </html> |
|
| Sponsored Link |