General description
General rule is:
- Every version has it's own space (CRMDOC31, CRMDOC40, etc)
- Exception to above is whole 3.4/4.0 version split pattern - we're using higher number for naming the space.
- CRMDOC is a simple redirect in Apache - it just redirects requests to appropriate version number
Switching CRMDOC to point at new version of documentation (around beta).
STEP 1: Pointing CRMDOC at proper version
Edit: /etc/apache2/sites-available/wiki.civicrm.org Change last piece of the target redirect URL piece to needed value (CRMDOC41, CRMDOC42 or so).
STEP 2: Make template adjustments
- You'll need to go adjust CSS stylesheet: go to http://wiki.civicrm.org:8090/confluence/spaces/viewstylesheet.action?key=CRMDOC42. If it's empty, copy the CSS from previous (source) space. You might also want to change the colour of the warning message on top of the page (#spacewarning CSS id), while you're here.
- You need to adjust the text of warning message on top of the page, it can be done here: http://wiki.civicrm.org:8090/confluence/spaces/editdecorator.action?decoratorName=decorators/main.vmd&key=CRMDOC42. Find the fragment within <div id="spacewarning">[...]</div>.
- Edit http://wiki.civicrm.org:8090/confluence/display/CRMDOC42/Primer page to change the information on the right side of documentation home page.
- Edit http://wiki.civicrm.org:8090/confluence/display/CRMDOC41/TreeNavigation page to change the information in the left side navigation. This is done by changing includes, that are incorporating pieces from CiviCRM Documentation Commons space.
STEP 3: Make old space read only
Finally, make old space read only: http://wiki.civicrm.org:8090/confluence/spaces/spacepermissions.action?key=CRMDOC42
"Edit permissions" for groups, leave only "View" and "Export" permissions checked. Save.
Create new space for work on upcoming version docs.
STEP 1: Database backup, maintenance mode
Do a database backup (dbname: confluence_new), bring wiki into maintenance mode (in apache)
Edit: /etc/apache2/sites-available/wiki.civicrm.org
It should look like this:
Above means, that you're redirecting all the traffic hitting confluence to a static page saying that it's under maintenance. It's better than using built-in Confluence maintenance mode, since it's basically turning off all the traffic and reduces effort on the server (since space copying is a pretty resource heavy operation).
STEP 2: Copy CRMDOCXX to CRMDOCYY space.
Go to: http://wiki.civicrm.org:8090/confluence/spaces/copyspaceoptions.action?key=CRMDOC41 (where CRMDOC41 is an example - choose last current space which you want to copy from)
Fill the fields:
| Example: creating new space for 4.2 from 4.1 docs Name: CiviCRM 4.2 Documentation |
STEP 3: Make template adjustments
See instructions above.
STEP 4: Optional - Reindex confluence content
Go to: http://wiki.civicrm.org:8090/confluence/admin/search-indexes.action. If you don't do it, it'll be done automatically within 24 hours.
STEP 5: Bring wiki back from maintenance mode
/etc/apache2/sites-available/wiki.civicrm.org should look like this:
