From a79f42b0ca1d1f83bfcc97f0d23ad5fd77033625 Mon Sep 17 00:00:00 2001 From: Eliot Berriot <contact@eliotberriot.com> Date: Fri, 27 Apr 2018 18:28:44 +0200 Subject: [PATCH] Fix #185: Document that the database should use an utf-8 encoding --- changes/changelog.d/185.doc | 1 + docs/installation/external_dependencies.rst | 11 ++++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 changes/changelog.d/185.doc diff --git a/changes/changelog.d/185.doc b/changes/changelog.d/185.doc new file mode 100644 index 00000000..72144e34 --- /dev/null +++ b/changes/changelog.d/185.doc @@ -0,0 +1 @@ +Document that the database should use an utf-8 encoding (#185) diff --git a/docs/installation/external_dependencies.rst b/docs/installation/external_dependencies.rst index 05922697..7de8abca 100644 --- a/docs/installation/external_dependencies.rst +++ b/docs/installation/external_dependencies.rst @@ -32,13 +32,22 @@ Create the project database and user: .. code-block:: shell - CREATE DATABASE funkwhale; + CREATE DATABASE "scratch" + WITH ENCODING 'utf8' + LC_COLLATE = 'en_US.utf8' + LC_CTYPE = 'en_US.utf8'; CREATE USER funkwhale; GRANT ALL PRIVILEGES ON DATABASE funkwhale TO funkwhale; Assuming you already have :ref:`created your funkwhale user <create-funkwhale-user>`, you should now be able to open a postgresql shell: +.. warning:: + + It's importing that you use utf-8 encoding for your database, + otherwise you'll end up with errors and crashes later on when dealing + with music metedata that contains non-ascii chars. + .. code-block:: shell sudo -u funkwhale -H psql -- GitLab