Portál AbcLinuxu, 12. května 2025 08:29

Dotaz: konfiguracia apache2 - userdir

2.7.2006 21:01 amico | skóre: 24
konfiguracia apache2 - userdir
Přečteno: 600×
Odpovědět | Admin
Ako mam nakonfigurovať apache2 tak aby sa mi zobrazovali v prehliadači stranky z adresara:
/home/peter/public_html
Ak zadam
http://localhost/home/peter/public_html
nedeje sa nič....

moj mod_userdir.conf
# UserDir: The name of the directory that is appended onto a user's home
# directory if a ~user request is received.
#

IfModule mod_userdir.c
	# Note that the name of the user directory ("public_html") cannot easily be
	# changed here, since it is a compile time setting. The apache package
	# would have to be rebuilt. You could work around by deleting
	# /usr/sbin/suexec, but then all scripts from the directories would be
	# executed with the UID of the webserver.
	# 
	# To rebuild apache with another setting you need to change the 
	# %userdir define in the spec file. 

	# not every user's directory should be visible:
	UserDir disabled root

	# to enable UserDir only for a certain set of users, use this instead:
	#UserDir disabled
	#UserDir enabled user1 user2


	# the UserDir directive is actually used inside the virtual hosts, to 
	# have more control
	#UserDir public_html

	Directory /home/*/public_html

	Options Indexes MultiViews
        AllowOverride None
        Order allow,deny
        Allow from all


	Directory

IfModule
Nástroje: Začni sledovat (0) ?Zašle upozornění na váš email při vložení nového komentáře.

Odpovědi

2.7.2006 21:04 Michal Kubeček | skóre: 72 | Luštěnice
Rozbalit Rozbalit vše Re: konfiguracia apache2 - userdir
Odpovědět | | Sbalit | Link | Blokovat | Admin
http://localhost/~peter/
2.7.2006 21:11 amico | skóre: 24
Rozbalit Rozbalit vše Re: konfiguracia apache2 - userdir
Diky takto to funguje
2.7.2006 21:15 Michal Kubeček | skóre: 72 | Luštěnice
Rozbalit Rozbalit vše Re: konfiguracia apache2 - userdir
Není nad to si občas přečíst dokumentaci… :-)

Založit nové vláknoNahoru

Tiskni Sdílej: Linkuj Jaggni to Vybrali.sme.sk Google Del.icio.us Facebook

ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.