1 |
Necesito configurar el mod de userdir en mi apache. La version de apache que |
2 |
uso es un mod de la 2.2. Hay varios archivos de configuracion que se cargan |
3 |
desde el archivo principal. Tambien he creado en los home's la carpeta |
4 |
public_html y le he dado los permisos con chmod. |
5 |
|
6 |
Este es el archivo inicial: |
7 |
|
8 |
# This is a modification of the default Apache 2.2 configuration file |
9 |
# for Gentoo Linux. |
10 |
# |
11 |
# Support: |
12 |
# http://www.gentoo.org/main/en/lists.xml [mailing lists] |
13 |
# http://forums.gentoo.org/ [web forums] |
14 |
# irc://irc.freenode.net#gentoo-apache [irc chat] |
15 |
# |
16 |
# Bug Reports: |
17 |
# http://bugs.gentoo.org [gentoo related bugs] |
18 |
# http://httpd.apache.org/bug_report.html [apache httpd related bugs] |
19 |
# |
20 |
# |
21 |
# This is the main Apache HTTP server configuration file. It contains the |
22 |
# configuration directives that give the server its instructions. |
23 |
# See <URL:http://httpd.apache.org/docs/2.2> for detailed information. |
24 |
# In particular, see |
25 |
# <URL:http://httpd.apache.org/docs/2.2/mod/directives.html> |
26 |
# for a discussion of each configuration directive. |
27 |
# |
28 |
# Do NOT simply read the instructions in here without understanding |
29 |
# what they do. They're here only as hints or reminders. If you are unsure |
30 |
# consult the online docs. You have been warned. |
31 |
# |
32 |
# Configuration and logfile names: If the filenames you specify for many |
33 |
# of the server's control files begin with "/" (or "drive:/" for Win32), the |
34 |
# server will use that explicit path. If the filenames do *not* begin |
35 |
# with "/", the value of ServerRoot is prepended -- so |
36 |
"var/log/apache2/foo_log" |
37 |
# with ServerRoot set to "/usr" will be interpreted by the |
38 |
# server as "/usr/var/log/apache2/foo.log". |
39 |
|
40 |
# ServerRoot: The top of the directory tree under which the server's |
41 |
# configuration, error, and log files are kept. |
42 |
# |
43 |
# Do not add a slash at the end of the directory path. If you point |
44 |
# ServerRoot at a non-local disk, be sure to point the LockFile directive |
45 |
# at a local disk. If you wish to share the same ServerRoot for multiple |
46 |
# httpd daemons, you will need to change at least LockFile and PidFile. |
47 |
ServerRoot "/usr/lib/apache2" |
48 |
|
49 |
# Dynamic Shared Object (DSO) Support |
50 |
# |
51 |
# To be able to use the functionality of a module which was built as a DSO |
52 |
you |
53 |
# have to place corresponding `LoadModule' lines at this location so the |
54 |
# directives contained in it are actually available _before_ they are used. |
55 |
# Statically compiled modules (those listed by `httpd -l') do not need |
56 |
# to be loaded here. |
57 |
# |
58 |
# Example: |
59 |
# LoadModule foo_module modules/mod_foo.so |
60 |
# |
61 |
# GENTOO: Automatically defined based on APACHE2_MODULES USE_EXPAND |
62 |
variable. |
63 |
# Do not change manually, it will be overwritten on upgrade. |
64 |
# |
65 |
# The following modules are considered as the default configuration. |
66 |
# If you wish to disable one of them, you may have to alter other |
67 |
# configuration directives. |
68 |
# |
69 |
# Change these at your own risk! |
70 |
|
71 |
LoadModule actions_module modules/mod_actions.so |
72 |
LoadModule alias_module modules/mod_alias.so |
73 |
LoadModule auth_basic_module modules/mod_auth_basic.so |
74 |
LoadModule authn_alias_module modules/mod_authn_alias.so |
75 |
LoadModule authn_anon_module modules/mod_authn_anon.so |
76 |
LoadModule authn_dbm_module modules/mod_authn_dbm.so |
77 |
LoadModule authn_default_module modules/mod_authn_default.so |
78 |
LoadModule authn_file_module modules/mod_authn_file.so |
79 |
LoadModule authz_dbm_module modules/mod_authz_dbm.so |
80 |
LoadModule authz_default_module modules/mod_authz_default.so |
81 |
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so |
82 |
LoadModule authz_host_module modules/mod_authz_host.so |
83 |
LoadModule authz_owner_module modules/mod_authz_owner.so |
84 |
LoadModule authz_user_module modules/mod_authz_user.so |
85 |
LoadModule autoindex_module modules/mod_autoindex.so |
86 |
<IfDefine CACHE> |
87 |
LoadModule cache_module modules/mod_cache.so |
88 |
</IfDefine> |
89 |
LoadModule cgid_module modules/mod_cgid.so |
90 |
<IfDefine DAV> |
91 |
LoadModule dav_module modules/mod_dav.so |
92 |
</IfDefine> |
93 |
<IfDefine DAV> |
94 |
LoadModule dav_fs_module modules/mod_dav_fs.so |
95 |
</IfDefine> |
96 |
<IfDefine DAV> |
97 |
LoadModule dav_lock_module modules/mod_dav_lock.so |
98 |
</IfDefine> |
99 |
LoadModule deflate_module modules/mod_deflate.so |
100 |
LoadModule dir_module modules/mod_dir.so |
101 |
<IfDefine CACHE> |
102 |
LoadModule disk_cache_module modules/mod_disk_cache.so |
103 |
</IfDefine> |
104 |
LoadModule env_module modules/mod_env.so |
105 |
LoadModule expires_module modules/mod_expires.so |
106 |
LoadModule ext_filter_module modules/mod_ext_filter.so |
107 |
<IfDefine CACHE> |
108 |
LoadModule file_cache_module modules/mod_file_cache.so |
109 |
</IfDefine> |
110 |
LoadModule filter_module modules/mod_filter.so |
111 |
LoadModule headers_module modules/mod_headers.so |
112 |
LoadModule include_module modules/mod_include.so |
113 |
<IfDefine INFO> |
114 |
LoadModule info_module modules/mod_info.so |
115 |
</IfDefine> |
116 |
LoadModule log_config_module modules/mod_log_config.so |
117 |
LoadModule logio_module modules/mod_logio.so |
118 |
<IfDefine CACHE> |
119 |
LoadModule mem_cache_module modules/mod_mem_cache.so |
120 |
</IfDefine> |
121 |
LoadModule mime_module modules/mod_mime.so |
122 |
LoadModule mime_magic_module modules/mod_mime_magic.so |
123 |
LoadModule negotiation_module modules/mod_negotiation.so |
124 |
LoadModule rewrite_module modules/mod_rewrite.so |
125 |
LoadModule setenvif_module modules/mod_setenvif.so |
126 |
LoadModule speling_module modules/mod_speling.so |
127 |
<IfDefine SSL> |
128 |
LoadModule ssl_module modules/mod_ssl.so |
129 |
</IfDefine> |
130 |
<IfDefine STATUS> |
131 |
LoadModule status_module modules/mod_status.so |
132 |
</IfDefine> |
133 |
LoadModule unique_id_module modules/mod_unique_id.so |
134 |
<IfDefine USERDIR> |
135 |
LoadModule userdir_module modules/mod_userdir.so |
136 |
UserDir public_html |
137 |
</IfDefine> |
138 |
LoadModule usertrack_module modules/mod_usertrack.so |
139 |
LoadModule vhost_alias_module modules/mod_vhost_alias.so |
140 |
|
141 |
# If you wish httpd to run as a different user or group, you must run |
142 |
# httpd as root initially and it will switch. |
143 |
# |
144 |
# User/Group: The name (or #number) of the user/group to run httpd as. |
145 |
# It is usually good practice to create a dedicated user and group for |
146 |
# running httpd, as with most system services. |
147 |
User apache |
148 |
Group apache |
149 |
|
150 |
# Supplemental configuration |
151 |
# |
152 |
# Most of the configuration files in the /etc/apache2/modules.d/ directory |
153 |
can |
154 |
# be turned on using APACHE2_OPTS in /etc/conf.d/apache2 to add extra |
155 |
features |
156 |
# or to modify the default configuration of the server. |
157 |
# |
158 |
# To know which flag to add to APACHE2_OPTS, look at the first line of the |
159 |
# the file, which will usually be an <IfDefine OPTION> where OPTION is the |
160 |
# flag to use. |
161 |
Include /etc/apache2/modules.d/*.conf |
162 |
|
163 |
# Virtual-host support |
164 |
# |
165 |
# Gentoo has made using virtual-hosts easy. In /etc/apache2/vhosts.d/ we |
166 |
# include a default vhost (enabled by adding -D DEFAULT_VHOST to |
167 |
# APACHE2_OPTS in /etc/conf.d/apache2). |
168 |
Include /etc/apache2/vhosts.d/*.conf |
169 |
|
170 |
# vim: ts=4 filetype=apache |
171 |
|
172 |
|
173 |
----------------------------------------------------------- |
174 |
|
175 |
y este es el archivo donde esta la configuracion de userdir. |
176 |
|
177 |
|
178 |
-------------------------------------------------------------- |
179 |
|
180 |
# Settings for user home directories |
181 |
|
182 |
<IfDefine USERDIR> |
183 |
<IfModule userdir_module> |
184 |
|
185 |
# UserDir: The name of the directory that is appended onto a user's home |
186 |
# directory if a ~user request is received. Note that you must also set |
187 |
# the default access control for these directories, as in the example below. |
188 |
|
189 |
UserDir public_html |
190 |
|
191 |
# Control access to UserDir directories. The following is an example |
192 |
# for a site where these directories are restricted to read-only. |
193 |
<Directory /home/*/public_html> |
194 |
AllowOverride FileInfo AuthConfig Limit Indexes |
195 |
Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec |
196 |
<Limit GET POST OPTIONS> |
197 |
Order allow,deny |
198 |
Allow from all |
199 |
</Limit> |
200 |
<LimitExcept GET POST OPTIONS> |
201 |
Order deny,allow |
202 |
Deny from all |
203 |
</LimitExcept> |
204 |
</Directory> |
205 |
|
206 |
# Suexec isn't really required to run cgi-scripts, but it's a really good |
207 |
# idea if you have multiple users serving websites... |
208 |
<IfDefine SUEXEC> |
209 |
<IfModule suexec_module> |
210 |
<Directory /home/*/public_html/cgi-bin> |
211 |
Options ExecCGI |
212 |
SetHandler cgi-script |
213 |
</Directory> |
214 |
</IfModule> |
215 |
</IfDefine> |
216 |
|
217 |
</IfModule> |
218 |
</IfDefine> |
219 |
|
220 |
# vim: ts=4 filetype=apache |
221 |
------------------------------------------------------ |
222 |
Parece que esta activado pero la verdad es que no responde en la url |
223 |
http://ip/~usuario/ |
224 |
|
225 |
|
226 |
|
227 |
|
228 |
Saludos |