Changeset View
Changeset View
Standalone View
Standalone View
src/docs/user/upgrading.diviner
| Show All 37 Lines | |||||
| and deploy the cluster. During the week, major bugfixes are cherry-picked to | and deploy the cluster. During the week, major bugfixes are cherry-picked to | ||||
| the `stable` branch. The changelog lists the `stable` hashes for that week, | the `stable` branch. The changelog lists the `stable` hashes for that week, | ||||
| as well as any fixes which were cherry-picked. | as well as any fixes which were cherry-picked. | ||||
| To switch to `stable`, check the branch out in each working copy: | To switch to `stable`, check the branch out in each working copy: | ||||
| phabricator/ $ git checkout stable | phabricator/ $ git checkout stable | ||||
| arcanist/ $ git checkout stable | arcanist/ $ git checkout stable | ||||
| libphutil/ $ git checkout stable | |||||
| You can now follow the upgrade process normally. | You can now follow the upgrade process normally. | ||||
| Upgrade Process | Upgrade Process | ||||
| =============== | =============== | ||||
| IMPORTANT: You **MUST** restart Phabricator after upgrading. For help, see | IMPORTANT: You **MUST** restart Phabricator after upgrading. For help, see | ||||
| @{article:Restarting Phabricator}. | @{article:Restarting Phabricator}. | ||||
| IMPORTANT: You **MUST** upgrade `libphutil`, `arcanist` and `phabricator` at | IMPORTANT: You **MUST** upgrade `arcanist` and `phabricator` at the same time. | ||||
| the same time. | |||||
| Phabricator runs on many different systems, with many different webservers. | Phabricator runs on many different systems, with many different webservers. | ||||
| Given this diversity, we don't currently maintain a comprehensive upgrade | Given this diversity, we don't currently maintain a comprehensive upgrade | ||||
| script which can work on any system. However, the general steps are the same | script which can work on any system. However, the general steps are the same | ||||
| on every system: | on every system: | ||||
| - Stop the webserver (including `php-fpm`, if you use it). | - Stop the webserver (including `php-fpm`, if you use it). | ||||
| - Stop the daemons, with `phabricator/bin/phd stop`. | - Stop the daemons, with `phabricator/bin/phd stop`. | ||||
| - Run `git pull` in `libphutil/`, `arcanist/` and `phabricator/`. | - Run `git pull` in `arcanist/` and `phabricator/`. | ||||
| - Run `phabricator/bin/storage upgrade`. | - Run `phabricator/bin/storage upgrade`. | ||||
| - Start the daemons, with `phabricator/bin/phd start`. | - Start the daemons, with `phabricator/bin/phd start`. | ||||
| - Restart the webserver (and `php-fpm`, if you stopped it earlier). | - Restart the webserver (and `php-fpm`, if you stopped it earlier). | ||||
| For some more discussion details, see @{article:Configuration Guide}. | For some more discussion details, see @{article:Configuration Guide}. | ||||
| This template script roughly outlines the steps required to upgrade Phabricator. | This template script roughly outlines the steps required to upgrade Phabricator. | ||||
| You'll need to adjust paths and commands a bit for your particular system: | You'll need to adjust paths and commands a bit for your particular system: | ||||
| ```lang=sh | ```lang=sh | ||||
| #!/bin/sh | #!/bin/sh | ||||
| set -e | set -e | ||||
| set -x | set -x | ||||
| # This is an example script for updating Phabricator, similar to the one used to | # This is an example script for updating Phabricator, similar to the one used to | ||||
| # update <https://secure.phabricator.com/>. It might not work perfectly on your | # update <https://secure.phabricator.com/>. It might not work perfectly on your | ||||
| # system, but hopefully it should be easy to adapt. This script is not intended | # system, but hopefully it should be easy to adapt. This script is not intended | ||||
| # to work without modifications. | # to work without modifications. | ||||
| # NOTE: This script assumes you are running it from a directory which contains | # NOTE: This script assumes you are running it from a directory which contains | ||||
| # arcanist/, libphutil/, and phabricator/. | # arcanist/, and phabricator/. | ||||
| ROOT=`pwd` # You can hard-code the path here instead. | ROOT=`pwd` # You can hard-code the path here instead. | ||||
| ### STOP WEB SERVER AND DAEMONS ############################################### | ### STOP WEB SERVER AND DAEMONS ############################################### | ||||
| # Stop daemons. | # Stop daemons. | ||||
| $ROOT/phabricator/bin/phd stop | $ROOT/phabricator/bin/phd stop | ||||
| # If running the notification server, stop it. | # If running the notification server, stop it. | ||||
| # $ROOT/phabricator/bin/aphlict stop | # $ROOT/phabricator/bin/aphlict stop | ||||
| # Stop the webserver (apache, nginx, lighttpd, etc). This command will differ | # Stop the webserver (apache, nginx, lighttpd, etc). This command will differ | ||||
| # depending on which system and webserver you are running: replace it with an | # depending on which system and webserver you are running: replace it with an | ||||
| # appropriate command for your system. | # appropriate command for your system. | ||||
| # NOTE: If you're running php-fpm, you should stop it here too. | # NOTE: If you're running php-fpm, you should stop it here too. | ||||
| sudo /etc/init.d/httpd stop | sudo /etc/init.d/httpd stop | ||||
| ### UPDATE WORKING COPIES ###################################################### | ### UPDATE WORKING COPIES ###################################################### | ||||
| cd $ROOT/libphutil | |||||
| git pull | |||||
| cd $ROOT/arcanist | cd $ROOT/arcanist | ||||
| git pull | git pull | ||||
| cd $ROOT/phabricator | cd $ROOT/phabricator | ||||
| git pull | git pull | ||||
| # Upgrade the database schema. You may want to add the "--force" flag to allow | # Upgrade the database schema. You may want to add the "--force" flag to allow | ||||
| # this script to run noninteractively. | # this script to run noninteractively. | ||||
| Show All 12 Lines | |||||