mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-04-28 17:32:38 +02:00
Replace MySQL by MariaDB in all documentation / README / changelog
Also document the new requirement for MariaDB >= 10.3.2 Fixes: #632 Fixes: #743
This commit is contained in:
parent
477fc20cd4
commit
def6dba825
5 changed files with 37 additions and 7 deletions
|
@ -11,6 +11,8 @@ Breaking changes
|
||||||
|
|
||||||
- Drop support for Python 2 (#483)
|
- Drop support for Python 2 (#483)
|
||||||
- Drop support for Python 3.5 (#571)
|
- Drop support for Python 3.5 (#571)
|
||||||
|
- Drop support for MySQL (#743)
|
||||||
|
- Require MariaDB version 10.3.2 or above (#632)
|
||||||
|
|
||||||
The minimum supported version is now Python 3.6
|
The minimum supported version is now Python 3.6
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@ Requirements
|
||||||
============
|
============
|
||||||
|
|
||||||
* **Python**: version 3.6 to 3.9.
|
* **Python**: version 3.6 to 3.9.
|
||||||
* **Backends**: MySQL, PostgreSQL, SQLite, Memory.
|
* **Backends**: SQLite, PostgreSQL, MariaDB (version 10.3.2 or above), Memory.
|
||||||
|
|
||||||
Contributing
|
Contributing
|
||||||
============
|
============
|
||||||
|
|
|
@ -24,7 +24,11 @@ format used can be found on `the SQLAlchemy documentation`_.
|
||||||
``sqlite:///home/ihatemoney/ihatemoney.db``. Do *not* store it under
|
``sqlite:///home/ihatemoney/ihatemoney.db``. Do *not* store it under
|
||||||
``/tmp`` as this folder is cleared at each boot.
|
``/tmp`` as this folder is cleared at each boot.
|
||||||
|
|
||||||
If you're using PostgreSQL, Your client must use utf8. Unfortunately,
|
For example, if you're using MariaDB, use a configuration similar to the following::
|
||||||
|
|
||||||
|
SQLALCHEMY_DATABASE_URI = 'mysql+pymysql://user:pass@localhost/dbname'
|
||||||
|
|
||||||
|
If you're using PostgreSQL, your client must use utf8. Unfortunately,
|
||||||
PostgreSQL default is to use ASCII. Either change your client settings,
|
PostgreSQL default is to use ASCII. Either change your client settings,
|
||||||
or specify the encoding by appending ``?client_encoding=utf8`` to the
|
or specify the encoding by appending ``?client_encoding=utf8`` to the
|
||||||
connection string. This will look like::
|
connection string. This will look like::
|
||||||
|
|
|
@ -20,7 +20,7 @@ Requirements
|
||||||
«Ihatemoney» depends on:
|
«Ihatemoney» depends on:
|
||||||
|
|
||||||
* **Python**: version 3.6 to 3.9 included will work.
|
* **Python**: version 3.6 to 3.9 included will work.
|
||||||
* **A Backend**: to choose among MySQL, PostgreSQL, SQLite or Memory.
|
* **A Backend**: to choose among SQLite, PostgreSQL, MariaDB (>= 10.3.2) or Memory.
|
||||||
* **Virtual environment** (recommended): `python3-venv` package under Debian/Ubuntu.
|
* **Virtual environment** (recommended): `python3-venv` package under Debian/Ubuntu.
|
||||||
|
|
||||||
We recommend to use `virtual environment <https://docs.python.org/3/tutorial/venv.html>`_ but
|
We recommend to use `virtual environment <https://docs.python.org/3/tutorial/venv.html>`_ but
|
||||||
|
@ -65,10 +65,10 @@ Once installed, you can start a test server::
|
||||||
|
|
||||||
And point your browser at `http://localhost:5000 <http://localhost:5000>`_.
|
And point your browser at `http://localhost:5000 <http://localhost:5000>`_.
|
||||||
|
|
||||||
Configure database with MySQL/MariaDB (optional)
|
Configure database with MariaDB (optional)
|
||||||
================================================
|
================================================
|
||||||
|
|
||||||
.. note:: Only required if you use MySQL/MariaDB.
|
.. note:: Only required if you use MariaDB. Make sure to use MariaDB 10.3.2 or newer.
|
||||||
|
|
||||||
1. Install PyMySQL dependencies. On Debian or Ubuntu, that would be::
|
1. Install PyMySQL dependencies. On Debian or Ubuntu, that would be::
|
||||||
|
|
||||||
|
@ -184,7 +184,7 @@ Install Gunicorn::
|
||||||
Obviously, adapt the ``ExecStart`` path for your installation folder.
|
Obviously, adapt the ``ExecStart`` path for your installation folder.
|
||||||
|
|
||||||
If you use SQLite as database: remove mentions of ``postgresql.service`` in ``ihatemoney.service``.
|
If you use SQLite as database: remove mentions of ``postgresql.service`` in ``ihatemoney.service``.
|
||||||
If you use MySQL or MariaDB as database: replace mentions of ``postgresql.service`` by ``mysql.service`` or ``mariadb.service`` in ``ihatemoney.service``.
|
If you use MariaDB as database: replace mentions of ``postgresql.service`` by ``mariadb.service`` in ``ihatemoney.service``.
|
||||||
|
|
||||||
Then reload systemd, enable and start ``ihatemoney``::
|
Then reload systemd, enable and start ``ihatemoney``::
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,7 @@ If you were running IHateMoney using Python < 3.6, you must, **before** upgradin
|
||||||
or several of the following deployment options :
|
or several of the following deployment options :
|
||||||
|
|
||||||
- Gunicorn (Nginx)
|
- Gunicorn (Nginx)
|
||||||
- MySQL
|
- MariaDB
|
||||||
- PostgreSQL
|
- PostgreSQL
|
||||||
|
|
||||||
If so, pick the ``pip`` commands to use in the relevant section(s) of
|
If so, pick the ``pip`` commands to use in the relevant section(s) of
|
||||||
|
@ -65,6 +65,30 @@ If so, pick the ``pip`` commands to use in the relevant section(s) of
|
||||||
|
|
||||||
Then follow :ref:`general-procedure` from step 1. in order to complete the update.
|
Then follow :ref:`general-procedure` from step 1. in order to complete the update.
|
||||||
|
|
||||||
|
Switch to MariaDB >= 10.3.2 instead of MySQL
|
||||||
|
++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
|
||||||
|
.. note:: If you are using SQLite or PostgreSQL, you can skip this section, no
|
||||||
|
special action is required.
|
||||||
|
|
||||||
|
If you were running IHateMoney with MySQL, you must switch to MariaDB.
|
||||||
|
MySQL is no longer a supported database option.
|
||||||
|
|
||||||
|
In addition, the minimum supported version of MariaDB is 10.3.2.
|
||||||
|
See `this MySQL / MariaDB issue <https://github.com/spiral-project/ihatemoney/issues/632>`_
|
||||||
|
for details.
|
||||||
|
|
||||||
|
To upgrade:
|
||||||
|
|
||||||
|
1. Ensure you have a MariaDB server installed and configured, and that its
|
||||||
|
version is at least 10.3.2.
|
||||||
|
|
||||||
|
2. Copy your database from MySQL to MariaDB.
|
||||||
|
|
||||||
|
3. Ensure that IHateMoney is correctly configured to use your MariaDB database,
|
||||||
|
see :ref:`configuration`.
|
||||||
|
|
||||||
|
Then follow :ref:`general-procedure` from step 1. in order to complete the update.
|
||||||
|
|
||||||
2.x → 3.x
|
2.x → 3.x
|
||||||
---------
|
---------
|
||||||
|
|
Loading…
Reference in a new issue