virtualhost

Jetty: set up general host

霸气de小男生 提交于 2019-12-08 06:32:00
问题 How can i force Jetty to open all deployed webapps starting from specific virtual host like test.localhost:8080/myapp instead of localhost:8181/myapp ? Here's snippet from jetty.xml: <Call name="addConnector"> <Arg> <New class="org.eclipse.jetty.server.nio.SelectChannelConnector"> <Set name="host"> <Property name="jetty.host"/> </Set> <Set name="port"> <Property name="jetty.port" default="8181"/> </Set> ... ... i tried to play with jetty.host value but still no success. :( How to? 回答1: To

RewriteLock hangs Apache on re-start when added to an otherwise working Rewrite / Rewritemap

故事扮演 提交于 2019-12-08 05:35:54
问题 I am on a Network Solutions VPS, four domain names share the IP. I have a Rewrite / RewriteMap set up that works. The Rewrite is in the file for the example.com web address at var/www/vhosts/example.com/conf/vhost.conf, the Rewrite being the only thing in the vhost.conf file. It would not work in the main httpd.conf file for the server. The RewriteMap uses a couple things in the URL typed in by the user (http://example.com/bb/cc) to get a third piece of info (aa) from the matching database

Apache mod_rewrite ANY subdomain(s) to root domain, unless existent as virtualdocumentroot

怎甘沉沦 提交于 2019-12-08 04:50:00
问题 Say you've got an Apache2 virtual host setup, something like this: /htdocs/parent1.com /htdocs/sub1.parent1.com /htdocs/sub2.parent1.com /htdocs/parent2.net /htdocs/parentn.org Say you'd like to do this with VirtualDocumentRoot /htdocs/%0 , so that you can add and remove virtual hosts without tinkering with your Apache configuration. That's important: please please no messing with htaccess files or httpd.conf every time a virtual host comes or goes - whether that host is a parent domain or

Apache VirtualHost: How to ServerName a port different from 80

為{幸葍}努か 提交于 2019-12-08 04:28:23
问题 I use Xampp and I want test.localhost to go to 127.0.0.1:81 . In httpd.conf I wrote: Listen 127.0.0.1:81 NameVirtualHost 127.0.0.1:81 <VirtualHost 127.0.0.1:81> ServerName test.localhost DocumentRoot "d:\_projects\projectx" DirectoryIndex index.php </VirtualHost> and to windows\system32\drivers\etc\hosts I added: 127.0.0.1 test.localhost But http://test.localhost now brings me to 127.0.0.1:80 . How do I make it go to 127.0.0.1:81 ? 回答1: As far as your browser is concerned, http://test

Sharing configuration between several VHosts

自闭症网瘾萝莉.ら 提交于 2019-12-08 04:23:49
问题 I'm managing a httpd installation with several sites running on it, each defined within it's own <VirtualHost> directive. There are several configuration variables (most of them from core as well as some php_flag / php_value ) that are exactly the same for several of the sites defined. I would like to be able to define a configuration set that will apply to several <VirtualHost> directives at the same time (to remove redundancy and make the server maintenance a little bit easier). I have

setting document root in antoher partition on ubuntu

百般思念 提交于 2019-12-08 03:26:23
问题 i would like to place my apache document root inside another partition of my ubuntu hard drive, but i keep getting forbidden message, when i place to my home directory it woking find, how could that be? is the group or owner affected ? here mysite.conf and apache2.conf when i place my document root in my home folder (Working) #site-available/mysite.conf DocumentRoot /home/jono/www #/etc/apache2/apache2.conf <Directory /home/jono/www/> Options Indexes FollowSymLinks AllowOverride None Require

Apache + Python Bottle : visitor IP always refers to 127.0.0.1

三世轮回 提交于 2019-12-08 03:15:38
问题 My server handles multiple websites, most of them with Apache, PHP, etc. But one of them ( www.mywebsite.com ) uses a Python webserver, which listens on port 8092. Thus this Apache configuration: <VirtualHost *:80> ServerName mywebsite.com ServerAlias *.mywebsite.com RewriteEngine On RewriteRule /(.*) http://localhost:8092/$1 [P,L] </VirtualHost> Now when a user, coming from internet, connects to www.mywebsite.com , it works : Python handles it and everything is okay. Problem: the IP that I

(Using phusion passenger + Nginx) running same rails app with multiple instance names with same port (80)

南笙酒味 提交于 2019-12-08 02:20:27
问题 Note : i am newbie to ruby on rails and server hosting , i unable to express my vision as question , please forgive me if i am wrong or correct me. Hi , i am having an one product developed using ruby on rails , going to host in an dedicated server with 32 GB Ram and 8 Core Server Processor. Each client should have seperate DB and separate rails instance. I am replicating - duplicating code for each client with separate folders and giving different database names and so each serving as an

Apache - how to map prefixes to different directories

故事扮演 提交于 2019-12-08 00:37:03
问题 Is it possible to configure Apache to allow different prefixes (instead of www) to map to different directories in the file system? For example... I have two different environments on my webserver: /home/me/test/web : Test Environment /home/production/web : Production Environment I would like these to map to these urls: test.mysite.com -> /home/me/test/web prod.mysite.com -> /home/production/web However, nothing I've tried with VirtualHosts has worked: NameVirtualHost *:80 <VirtualHost *:80>

How do I make a subfolder act like a document root using htaccess?

我的未来我决定 提交于 2019-12-07 19:12:16
问题 Site location: http://localhost/~username/website The website loads lots of images with an absolute url such as /image/image.png. I need that request to go to: http://localhost/~username/website/image/image.png instead of http://localhost/image/image.png. I also need this to not affect any other folders or the root folder. So that I could also access http://localhost/image/image.png if I wanted to. Is there some way of making it so that when it's requested from this subfolder to redirect? I