Changeset - a2abde4062ec
[Not reviewed]
default
0 1 0
Thomas De Schampheleire - 7 years ago 2018-12-28 22:43:49
thomas.de_schampheleire@nokia.com
docs: upgrade: front-end should be built for all installation methods

... and not exclusively when installing from version control.
1 file changed with 14 insertions and 5 deletions:
0 comments (0 inline, 0 general)
docs/upgrade.rst
Show inline comments
 
@@ -69,49 +69,48 @@ installed Kallithea in by running::
 
This will list all packages installed in the current environment. If
 
Kallithea isn't listed, activate the correct virtual environment.
 
See the appropriate installation page for details.
 

	
 

	
 
4. Install new version of Kallithea
 
-----------------------------------
 

	
 
Please refer to the instructions for the installation method you
 
originally used to install Kallithea.
 

	
 
If you originally installed using pip, it is as simple as::
 

	
 
    pip install --upgrade kallithea
 

	
 
If you originally installed from version control, assuming you did not make
 
private changes (in which case you should adapt the instructions accordingly)::
 

	
 
    cd my-kallithea-clone
 
    hg parent   # make a note of the original revision
 
    hg pull
 
    hg update
 
    hg parent   # make a note of the new revision
 
    pip install --upgrade -e .
 
    kallithea-cli front-end-build
 

	
 
.. _upgrade_config:
 

	
 

	
 
5. Upgrade your configuration
 
-----------------------------
 

	
 
Run the following command to create a new configuration (``.ini``) file::
 

	
 
    kallithea-cli config-create new.ini
 

	
 
Then compare it with your old config file and see what changed.
 

	
 
.. note::
 
    Please always make sure your ``.ini`` files are up to date. Errors
 
    can often be caused by missing parameters added in new versions.
 

	
 
.. _upgrade_db:
 

	
 

	
 
6. Upgrade your database
 
------------------------
 

	
 
.. note::
 
@@ -154,64 +153,74 @@ Enabling old Kallithea config files for 
 
Kallithea configuration files created before the introduction of Alembic
 
(i.e. predating Kallithea 0.4) need to be updated for use with Alembic.
 
Without this, Alembic will fail with an error like this::
 

	
 
    FAILED: No config file 'my.ini' found, or file has no '[alembic]' section
 

	
 
.. note::
 
    If you followed this upgrade guide correctly, you will have created a
 
    new configuration file in section :ref:`Upgrading your configuration
 
    <upgrade_config>`. When calling Alembic, make
 
    sure to use this new config file. In this case, you should not get any
 
    errors and the below manual steps should not be needed.
 

	
 
If Alembic complains specifically about a missing ``alembic.ini``, it is
 
likely because you did not specify a config file using the ``-c`` option.
 
On the other hand, if the mentioned config file actually exists, you
 
need to append the following lines to it::
 

	
 
    [alembic]
 
    script_location = kallithea:alembic
 

	
 
Your config file should now work with Alembic.
 

	
 

	
 
7. Update Git repository hooks
 
7. Prepare the front-end
 
------------------------
 

	
 
Starting with Kallithea 0.4, external front-end dependencies are no longer
 
shipped but need to be downloaded and/or generated at installation time. Run the
 
following command::
 

	
 
    kallithea-cli front-end-build
 

	
 

	
 
8. Update Git repository hooks
 
------------------------------
 

	
 
It is possible that an upgrade involves changes to the Git hooks installed by
 
Kallithea. As these hooks are created inside the repositories on the server
 
filesystem, they are not updated automatically when upgrading Kallithea itself.
 

	
 
To update the hooks of your Git repositories:
 

	
 
* Go to *Admin > Settings > Remap and Rescan*
 
* Select the checkbox *Install Git hooks*
 
* Click the button *Rescan repositories*
 

	
 
.. note::
 
    Kallithea does not use hooks on Mercurial repositories. This step is thus
 
    not necessary if you only have Mercurial repositories.
 

	
 

	
 
8. Rebuild the Whoosh full-text index
 
9. Rebuild the Whoosh full-text index
 
-------------------------------------
 

	
 
It is recommended that you rebuild the Whoosh index after upgrading since
 
new Whoosh versions can introduce incompatible index changes.
 

	
 

	
 
9. Start the Kallithea web application
 
--------------------------------------
 
10. Start the Kallithea web application
 
---------------------------------------
 

	
 
This step once again depends entirely on the web server software used to
 
serve Kallithea.
 

	
 
Before starting the new version of Kallithea, you may find it helpful to
 
clear out your log file so that new errors are readily apparent.
 

	
 
.. note::
 
    If you're using Celery, make sure you restart all instances of it after
 
    upgrade.
 

	
 

	
 
.. _virtualenv: http://pypi.python.org/pypi/virtualenv
0 comments (0 inline, 0 general)