Answer the question
In order to leave comments, you need to log in
How to properly mirror a subdomain?
For example, I have a subdomain admin.site.ru . How to make a mirror of this subdomain that will be available via the link admin.ru?
Answer the question
In order to leave comments, you need to log in
Set up a 301 redirect from admin.ru to admin.site.ru. How to do this depends on many factors. I assume that the DNS server is not yours, in which case redirects are usually configured in the DNS / domain control panel. If redirects cannot be configured there, then create a zone for the domain there, specify the IP address of your server in the A record, add CNAME for www. If the domain already points to the server, just make a 301 redirect for it to your subdomain. In nginx, for example, this would be:
server {
listen 80;
server_name www.admin.ru admin.ru;
rewrite ^ http://admin.site.ru$request_uri? permanent;
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question