Changes between Version 12 and Version 13 of ParrotServer


Ignore:
Timestamp:
05/02/13 10:39:48 (4 years ago)
Author:
chris
Comment:

Adding a domain to a site and Changing the default domain of a site sections added

Legend:

Unmodified
Added
Removed
Modified
  • ParrotServer

    v12 v13  
    6161* '''Users email address''' -- enter the email address that the SFTP, MySQL and WordPress login details are to be sent to 
    6262 
    63 That's it! 
     63This will create a site with a http://username.parrot.transitionnetwork.org/ address which is fine for developing the site, when it needs to be accessed from another domain name there are two steps to complete: 
     64 
     65=== Adding a domain to a site === 
     66 
     67To do this edit the {{{/root/webarch/accounts/sites.txt}}} file and add the domain(s) as aliases and run {{{buildapache username}}}, there '''username''' is the username for the site, for example: 
     68 
     69{{{ 
     70sudo -i 
     71vim /root/webarch/accounts/sites.txt 
     72buildapache username 
     73}}} 
     74 
     75This is what the file looks like: 
     76 
     77{{{ 
     78# File format "username" "sites subdir" "ServerName" "ServerAliases" 
     79# note ServerAliases are comma delimited. 
     80# 
     81#Example 
     82#aed foo foo.example.com www.foo.example.com,foo.example.org 
     83movie default movie.parrot.webarch.net movie.parrot.transitionnetwork.org,intransitionmovie.com,www.intransitionmovie.com,intransitionmovie.org,www.intransitionmovie.org,transitionmovie.org,www.transitionmovie.org 
     84}}} 
     85 
     86See also http://webarch.net/docs/wsh#buildapache 
     87 
     88=== Changing the default domain of a site === 
     89 
     90WordPress will redirect all requests to a single domain, this is set on the '''Settings -> General''' page at {{{/wp-admin/options-general.php}}} using the '''WordPress Address (URL)''' field. 
     91 
     92To change this address you need to add the following to {{{wp-config.php}}} after the "define" statements (just before the comment line that says "That's all, stop editing!"):  
     93 
     94{{{ 
     95define('RELOCATE',true); 
     96}}} 
     97 
     98Then update the DNS and visit the site at the correct URl, login and then remove the above from {{{wp-config.php}}}. For more information on this see https://codex.wordpress.org/Changing_The_Site_URL#Relocate_method 
    6499 
    65100== Maintaining WordPress sites ==