add comments
This commit is contained in:
parent
5384313b41
commit
1e885470d0
1 changed files with 3 additions and 0 deletions
3
debian/grantpriv.sh
vendored
3
debian/grantpriv.sh
vendored
|
@ -3,6 +3,8 @@
|
|||
user=gitlab
|
||||
dbname=gitlab_production
|
||||
|
||||
# If gitlab user cannot access gitlab_production,
|
||||
# then it means the gitlab role does not exist
|
||||
if ! su gitlab -s /bin/sh -c 'psql gitlab_production -c ""'
|
||||
then
|
||||
echo "Create $user user with create database privillege..."
|
||||
|
@ -11,6 +13,7 @@ then
|
|||
}
|
||||
fi
|
||||
|
||||
# By default the gitlab_prodcution is not owned by gitlab user
|
||||
echo "Make $user user owner of $dbname database..."
|
||||
sudo -u postgres psql -c "ALTER DATABASE $dbname OWNER to $user;" || {
|
||||
exit 1
|
||||
|
|
Loading…
Add table
Reference in a new issue