From 2042d04fcb7983882e8fb481c15fadf897ddae15 Mon Sep 17 00:00:00 2001 From: Pirate Praveen Date: Sun, 9 Aug 2020 00:28:53 +0530 Subject: [PATCH] Allow gitlab user to create schema --- debian/gitlab.postinst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/debian/gitlab.postinst b/debian/gitlab.postinst index 9d64ba7755..61dd2aea64 100755 --- a/debian/gitlab.postinst +++ b/debian/gitlab.postinst @@ -314,6 +314,9 @@ case "$1" in # enable the pg_trgm extension runuser -u postgres -- sh -c "psql -d gitlab_production -c \"CREATE EXTENSION IF NOT EXISTS pg_trgm;\"" + # Allow gitlab user to create schema + runuser -u postgres -- sh -c "psql -c \"GRANT CREATE ON database gitlab_production TO ${gitlab_user};\"" + # Remove Gemfile.lock if present rm -f ${gitlab_data_dir}/Gemfile.lock