Skip to main content

Questions tagged [mod-alias]

Maps different parts of a host file system into the document tree and it used for URL redirection

1 vote
1 answer
240 views

I have the following virtual hosts: <VirtualHost *:443> ServerName article.example.com AliasMatch "^/(.*)" "/var/www/html/article.php" </VirtualHost> <...
Maciek's user avatar
  • 139
0 votes
1 answer
386 views

I am trying map all wildcards for a directory /a/* onto on file article.php using AliasMatch ^/a/(.*) /article.php but without redirecting (I want to keep the url looking the same). But I am getting a ...
Maciek's user avatar
  • 139
1 vote
1 answer
887 views

I want to redirect URLs with multiple consecutive slashes (e.g. //) in the path to have only one consecutive slash, e.g. https://example.com/a//b/c/ → https://example.com/a/b/c/. My .htaccess file ...
fionn's user avatar
  • 13
1 vote
1 answer
932 views

I have main url like http://apps1.example.com and i want create alias like http://apps1.example.com/svc-base in my vhost config <VirtualHost *:80> ServerName apps1.example.com ...
Aleh's user avatar
  • 11
2 votes
1 answer
226 views

Using the .htaccess file, I would like to redirect www.example.com/fr/ to www.example.com/ but not other French pages that have the /fr/ root (e.g. www.example.com/fr/page-name) I've tried using ...
Samuel's user avatar
  • 23
1 vote
1 answer
160 views

I bought a VPS for my new project running apache. On it I have 2 websites on the same domain. The first one is Ruby on Rails /var/www/html The second one is Wordpress /var/www/blog I want Wordpress to ...
Adelle's user avatar
  • 13
2 votes
1 answer
905 views

I am trying to redirect the all the URL starting from /search-engine/* to /var/www/search-engine/dist but the result says not found, I had tried with AliasMatch as shown below AliasMatch ^/search-...
Prashobh K V's user avatar
0 votes
0 answers
648 views

Under mod_alias, how does Apache order Alias and ScriptAlias directives with respect to each other? The mod_alias docs say The ScriptAlias directive has the same behavior as the Alias directive, ...
JonahHuron's user avatar
1 vote
1 answer
3k views

I've been trying to remove the trailing slashes from all URLs. For example, I want the following URLs to redirect: http://example.com///test -> http://example.com/test http://example.com//test -&...
user2370460's user avatar
1 vote
1 answer
652 views

I have a legacy application that I want to wrap in a new symfony project. In order to separate things clearly I decided to move the entire legacy application into a folder legacy which lies outside ...
Emanuel Oster's user avatar
2 votes
2 answers
4k views

I can't find any documentation on Apache vhosts instructions priority / execution order between mod_alias (Redirect instructions), mod_rewrite (RewriteRule instructions) mod_proxy (ProxyPass ...
Quentin S.'s user avatar
1 vote
1 answer
9k views

I have this folder structure: /fonts /myfont.eot /myfont.svg /myfont.ttf /myfont.woff /myfont.woff2 /content /page1 /files /logo.png /style.css /index.html /page2 ...
LWChris's user avatar
  • 111
1 vote
1 answer
906 views

First of all i'm a beginner on these issues, sorry for this :) Actually i am a software developer. I have a project. Many domains connect to Rest Api domain. And all domains locate same server. I ...
okancelik's user avatar
  • 111
0 votes
1 answer
516 views

I would like to add the trailing slash in general when it is absent in the request URL: when user requests https://example.com/blog, it should be redirected to https://example.com/blog/ when user ...
svipul's user avatar
  • 101
0 votes
1 answer
461 views

I am using the following directive in my .htaccess file: RedirectMatch 301 ^/user/(.*)?$ http://$1.example.com/user/$1 to redirect the URL example.com/user/koko/ but it redirects to http://koko/....
Lolak's user avatar
  • 141
0 votes
1 answer
2k views

I have scoured several pages, answers and articles in an attempt to correctly configure Apache Alias and Wordpress Permalinks without success. /var/www/ | - example.com (Custom Web App) | - blog....
Ralph's user avatar
  • 952
-1 votes
1 answer
163 views

I am attempting to create a virtual host to connect a computer running a node application (Computer B 12.34.56.78) to a computer running my Apache web server (Computer A 12.34.56.77). Everything I ...
John Moran's user avatar
2 votes
0 answers
865 views

Within a multi-server shared hosting I am using this RedirectMatch temp "/.well-known/acme-challenge/(.*)" "https://FOO.BAR.TLD/$1" to redirect all Let's Encrypt requests to one server. The problem: ...
Schubi Duah's user avatar
0 votes
0 answers
275 views

I have a web server running since 2014 on Windows Server 2008R2 with Apache 2.2.25, PHP and stuff. It has some Alias directives inside its <VirtualHost> config entry, which seemingly had stopped ...
Vesper's user avatar
  • 834
0 votes
0 answers
873 views

In .htaccess: RewriteCond %{HTTP_HOST} ^domain.info RewriteRule (.*) http://www.domain.info/$1 [R=301,QSA,L] In server .conf file: Alias "/.well-known/acme-challenge" "/tmp/.well-known/acme-...
Pavel's user avatar
  • 487
0 votes
1 answer
2k views

i want to create an alias in my subdomain. The easiest way to do for my host is this : Alias "/docs" "/var/sudomain/web" Here all requests from http://google.io/docs will use folder /var/sudomain/web ...
Walden's user avatar
  • 3
-1 votes
1 answer
660 views

Using the web browser, I have a requirement to access a directory on a Linux server hosting around 2,00,000 files in it. I am using the 'Alias' directive in apache to achieve this requirement. ...
mwgeek's user avatar
  • 1
1 vote
1 answer
2k views

I am trying to alias a path to a specific file I tried: Alias /Console "/console/console.html" Now going to http://example.com/Console indeed brings console.html. but any relative resource ...
kofifus's user avatar
  • 165
1 vote
1 answer
485 views

We use Apache HTTPD server version 2.2. I try to use RedirectMatch of Apache 2.2 mod_alias without success ( http://httpd.apache.org/docs/2.2/mod/mod_alias.html#redirectmatch) I need to create rule ...
Michael's user avatar
  • 625
0 votes
0 answers
361 views

I have this configurartion <VirtualHost *:443> ServerName myserver.fr SSLEngine on ProxyRequests On ProxyPreserveHost On DocumentRoot /srv/apache2/htdocs/ Alias /...
Rafael Angarita's user avatar
4 votes
1 answer
2k views

Today I've noticed that mod_alias's Redirect and RedirectMatch directives show a different behavior in how they handle the redirect URL. A statement like this: Redirect 301 "/foo" "/bar%20baz" will ...
dorian's user avatar
  • 447
0 votes
1 answer
947 views

I'm trying to create an alias to intercept some url to serve from file system directly with Apache 2.4 In my virtualhost, I have: DocumentRoot /var/www/mysubroot I have a location on "/" in order to ...
DevOps's user avatar
  • 730
4 votes
2 answers
3k views

The Apache HTTP Server's mod_alias provides the Redirect directive which is great for simple redirects, like the following: # Redirect login to https Redirect permanent /login https://www.example.org/...
Stefan Lasiewski's user avatar
1 vote
1 answer
2k views

When using the Alias directive to map a URL to a directory outside the document root, it seems that the .htaccess files in the document root are not applied to those requests. For example, if setting ...
sa289's user avatar
  • 1,418
8 votes
5 answers
7k views

I have a global entry Alias /.well-known/acme-challenge /var/www/letsencrypt/.well-known/acme-challenge/ in my apache configuration, outside any virtual host. This way, the above Alias is effective ...
Joachim Breitner's user avatar
2 votes
2 answers
2k views

Is it possible to set up Apache to serve multiple directories from the same URL? For example, given that I have images in two locations: /mnt/imagestore1, /mnt/imagestore2. I would like mysite.com/...
Matt Brunmeier's user avatar
16 votes
3 answers
21k views

I have the following setup on one of my vhosts: ...<VirtualHost *:80> ServerName cloud.domain.de ServerAdmin [email protected] ServerSignature Off Alias "/.well-known/acme-...
FleBeling's user avatar
  • 163
1 vote
1 answer
876 views

I have inherited a web application written in PHP. The code is not the best and I want to start using the Symfony framework. It will be a gradual migration through several releases so I need the ...
emurano's user avatar
  • 111
0 votes
1 answer
2k views

I have a third-party shopping cart set up on my server using PayPal for payments. When a user completes a transaction they are redirected to the URL https://example.com/?target=payment%255freturn&...
colincameron's user avatar
0 votes
1 answer
506 views

I have a Plone-based site, running behind Apache 2.4, which could perform a little better. One idea is to have Apache serve the static parts of the contents, preventing them from being rewritten for ...
Tobias's user avatar
  • 165
3 votes
2 answers
6k views

I have a domain with dynamic subdomains. The domain, unfortunately, has changed. As such I need to redirect *.domain1.com to *.domain2.com while keeping the subdomains the same. I have looked ...
Joseph's user avatar
  • 161
-1 votes
1 answer
1k views

I have PHP5 installed on an Ubuntu 14.04 server and it works fine. I create a file called foo.php anywhere in the document tree and it gets passed to the PHP interpreter just as you'd expect. ...
kbro's user avatar
  • 320
2 votes
2 answers
28k views

Ok, not sure why this is occuring. So, I get the message The Alias directive in /etc/httpd/conf.d/awstats.conf at line 3 will probably never match because it overlaps an earlier Alias. and The ...
fizzy drink's user avatar
0 votes
1 answer
1k views

Here's my vhost in apache 2.4: <VirtualHost *:80> ServerName mailcatcher.dev Alias /mailcatcher.dev.png /Users/me/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/mailcatcher-0.5.12/...
Camden Narzt's user avatar
0 votes
1 answer
1k views

A mod_alias newbie here. I found the rewrite rule below somewhere and have been using it to block bots and hackers that hit my site, looking for directories like HNAP1, wp, blog, etc. And it works ...
markratledge's user avatar
0 votes
1 answer
3k views

Here is how the directories are laid out on my server (I inherited this and cannot change at the moment) - /var/www/<stuff for the web> /home/project/src/static/<some CSS, some JavaScript, ...
Jay Blanchard's user avatar
0 votes
1 answer
703 views

I would like domain1.com/customers to go to domain2 my home directory public html's folder / customers. Both domains are on different servers. In the folder on the second server/second domain we will ...
rhand's user avatar
  • 264
1 vote
1 answer
2k views

I have a generic alias match like: AliasMatch ^/plugins/([^/]*)/(.*) /usr/share/tuleap/plugins/$1/www/$2 <DirectoryMatch "/usr/share/tuleap/plugins/([^/]*)/www/"> ... </DirectoryMatch> ...
Manuel VACELET's user avatar
9 votes
2 answers
32k views

I want to try mod_alias instead of mod_rewrite for a couple of simple redirect rules, but the directives don't seem to be working when entered in .htaccess. Is it possible that mod_alias is not ...
Matthew S's user avatar
  • 209
0 votes
1 answer
637 views

I am trying to use mod_headers to change Location headers that are being sent via the mod_alias using the Redirect directive but none of them are being re-written. I have the following in my http.conf;...
nathanjosiah's user avatar
1 vote
2 answers
733 views

Roundcubemail and Owncloud folders live on the document root but because of the limitations of the Roundcube OwnCloud Plug-in I have to organise the vhosts as below. $rcmail_config['owncloud_url'] ...
Steve's user avatar
  • 13
1 vote
1 answer
343 views

I came across an article titled "Efficient 301 Redirects." For example, if you are trying to redirect your site from www to non-www domain, the article suggests that when compared to this .htaccess/...
its_me's user avatar
  • 225
2 votes
1 answer
821 views

I have various virtual hosts (vhosts) setup on an Apache 2.2 server such as: examplea.domain exampleb.domain testsitea.domain testsiteb.domain testsite.domain othersitea.domain On virtual hosts ...
Richy B.'s user avatar
  • 213
0 votes
2 answers
2k views

I am currently using Apache 2.4.4. Now, the problem is that when I am creating alias like Alias /mysite "D:/MySite" it doesn't work for http://127.0.0.1/MySite. So how can I make it case insensitive?
user avatar
6 votes
2 answers
14k views

Compare these two RedirectMatch's. The first doesn't work: RedirectMatch 302 ^/redirect\.php[?]page=(.+)$ http://somewhereelse.com/$1 Versus this, which will redirect to http://somewhereelse.com/?...
pinate's user avatar
  • 207