Tuesday, January 18, 2022

redirecting to new domain

Added permanent redirects to our new domain, like this - 
I have now put the following
RewriteEngine on
 RewriteCond %{SERVER_NAME} =olddomain.org
 RewriteRule ^ https://newdomain.org%{REQUEST_URI} [END,NE,R=permanent]

in /etc/apache2/sites-available/olddomain.org-le-ssl.conf
of our server and restarted apache.

so that when google returns the Sai Inspires link, the user gets redirected to the correct page. But this redirection seemed to break an application on another domain of ours. PB corrected this by the following:
Have created a softlink and it seems to be working.
Did the following steps

mv /path/to/archive/www/problemdomain  /path/to/archive/www/problemdomain_backup
ln -s /path/to/media/www/problemdomain /path/to/archive/www/problemdomain
  

No comments:

Post a Comment