I have a issue with Plesk to set the right path for a subdomain for a subdomain of a domain alias.
The structure I have:
domain.nl (Head domain)
*.domain.nl (wilcard subdomain) (points to: '/public_html/s')
domain.com (alias for domain.nl)
It's not really possible to create a wildcard subdomain for the 'domain.com(alias of domain.nl) like I did for the '.domain.nl' wildcard subdomain.
I'm trying to do the following:
get a cname setup so that *.subdomain.domain.com points to anotherdomain.com.
Then in the anotherdomain.com DNS, I want to look for things like one.subdomain.domain.com and point it to another server and two.subdomain.domain.com pointed to a fourth server.
Is this possible in any way?
I'm trying to setup Nginx config to auto redirect any domain/subdomain pointed(CNAME) to my static subdomain(site.domain.com) to a respective directory inside /var/www. The directory will be named after the pointed domain/subdomain. I don't want to use VirtualHost or alter/restart Nginx everytime someone add new domain.
I stumble upon this answer but I still don't quite understand.
I have a subdomain that has an SSL certificate that is working nicely. The web address for it is, lets say, like this: sd1.mydomain.com (sd1=sub-domain 1). Now I want to add a second subdomain, but it doesn't need to have the certificate encrypting the data. Thus, I want: sd2.mydomain.com
I adjusted my sites-enabled directory to have two config files, one for each subdomain.
I know this must have been answered a million times but I can't seem to get it to work
I would like to redirect a subdomain to a subdirectory.
I am currently using
server {
server_name sub.domain.com;
rewrite ^(.*) http://www.domain.com/sub-directory permanent;
}
If I navigate to sub.domain.com I am redirected to http://www.domain.com
EDIT
Here's my full config.
I installed the Apache.
#Hide Index
IndexIgnore *
#Define ErrorDoc
ErrorDocument 404 http://www.domain.com
#REDIRECTS
Redirect 301 /page.php http://domain.com
Redirect 301 /inc/page.php http://domain.com
Options +FollowSymlinks
RewriteEngine on
#Redirect all pages in a folder to a single URL
RewriteRule ^dir/(.*)$ http://domain.com/index.php [L,R=301]
#Redirect String
RewriteRule ^index.php?var1=value&var2=(.*)
I have a domain name set with wildcard for all subdomain (*.mydomain.com), I need of exclude a specific subdomain from this condition, I use a record dns for set wildcard and if I set a new record A for a specific subdomain it not work
I have configured Apache to load KnowledgeTree (KT) through a subdomain.
# Part of http.conf file
NameVirtualHost *:80
<VirtualHost *:80>
ServerName www.example.com
ServerAlias example.com
DocumentRoot /usr/local/apache2/htdocs
</VirtualHost>
<VirtualHost *:80>
ServerName knowledgetree.example.com
DocumentRoot /usr/local/apache2/htdocs/knowledgetree
</Vi