From b755906ad165fea4e56176ff3a1c3f9ef09150a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Zapletal?= Date: Fri, 11 Nov 2022 09:42:04 +0100 Subject: [PATCH] [docs] postgres collation warning (#1017) --- .gitignore | 4 ++++ docs/configuration/database.md | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index b3ddcb399..f2a409fc0 100644 --- a/.gitignore +++ b/.gitignore @@ -32,3 +32,7 @@ shell.nix # ignore custom GOBIN path /bin + +# ignore config dirs from IDEs +/.idea/ +/.fleet/ diff --git a/docs/configuration/database.md b/docs/configuration/database.md index a8d7645e2..336279967 100644 --- a/docs/configuration/database.md +++ b/docs/configuration/database.md @@ -37,11 +37,13 @@ Then you should have already created database `gotosocial` in Postgres, and give The psql commands to do this will look something like: ```psql -create database gotosocial; +create database gotosocial with locale C.UTF-8 template template0; create user gotosocial with password 'some_really_good_password'; grant all privileges on database gotosocial to gotosocial; ``` +GoToSocial makes use of ULIDs (Universally Unique Lexicographically Sortable Identifiers) which will not work in non-English collate environments. For this reason it is important to create the database with `C.UTF-8` locale. To do that on systems which were already initialized with non-C locale, `template0` pristine database template must be used. + ## Settings ```yaml