update db checks
This commit is contained in:
parent
6f4af34b27
commit
6cbbf28cc1
1 changed files with 2 additions and 1 deletions
3
debian/postinst
vendored
3
debian/postinst
vendored
|
@ -35,11 +35,12 @@ case "$1" in
|
||||||
# Show debconf questions
|
# Show debconf questions
|
||||||
. /usr/share/debconf/confmodule
|
. /usr/share/debconf/confmodule
|
||||||
echo "Create database if not present"
|
echo "Create database if not present"
|
||||||
if ! su gitlab -s /bin/sh -c "psql gitlab_production -c ''"
|
if ! su postgres -s /bin/sh -c "psql gitlab_production -c ''"
|
||||||
then
|
then
|
||||||
su postgres -c 'createdb gitlab_production'
|
su postgres -c 'createdb gitlab_production'
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Adjust database privileges
|
||||||
. /usr/lib/gitlab/scripts/grantpriv.sh
|
. /usr/lib/gitlab/scripts/grantpriv.sh
|
||||||
echo "Setting up environment varibales..."
|
echo "Setting up environment varibales..."
|
||||||
export RAILS_ENV=production
|
export RAILS_ENV=production
|
||||||
|
|
Loading…
Add table
Reference in a new issue