- Red Hat JBoss Enterprise Web Server (EWS) 1.x,2.x
- Apache httpd 2.2.x
- How can we include static content from external shared folders in EWS/Apache httpd? Any requests to these resources should be excluded from mod_jk AJP. Currently these contents are being deployed as part of our EAP(with entries in profile.xml and vfs.xml), which in fact, is not required. This causes lot of time being spent in deployment.
- How to use
Aliasto server static files from Apache httpd?
- A simple test case would be as follows:
- Create images in the
httpd.conf, have the following configuration.
<VirtualHost *:80> ServerName myapp.example.com DocumentRoot /var/www/ Alias /images "/var/www/img/" <Directory "/var/www/img"> Options +Indexes AllowOverride None Order allow,deny Allow from all </Directory> </VirtualHost>
- Go to url http://localhost/images and you should see the images listed.To prevent directory listings remove Options +Indexes.
- For more details check Apache httpd 2.2 mod_alias module documentation
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.