Can i install a new WordPress in this way?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×
A question can only have one accepted answer. Are you sure you want to replace the current answer with this one?
You previously marked this answer as accepted. Are you sure you want to unaccept it?
/etc/nginx/sites-available/currentdomain.com, set server_name to currentdomain.com, and set root to /var/www/currentdomain.com
ln -s /etc/nginx/sites-available/currentdomain.com /etc/nginx/sites-enabled/currentdomain.com
ln -s /etc/nginx/sites-available/seconddomain.com /etc/nginx/sites-enabled/seconddomain.com
wordpressuserwith the second domain's name e.g. seconddomain.
mv /var/www/* /var/www/currentdomain.com
mv /var/www/.* /var/www/currentdomain.com
tar xf latest.tar.gz
mv wordpress/* .
mv wordpress/.* .
rm -r wordpress
service nginx restart