add config and templates

This commit is contained in:
Praveen Arimbrathodiyil 2015-10-24 13:00:34 +05:30
parent 0a25e32367
commit 0d8223f8e8
2 changed files with 45 additions and 0 deletions

22
debian/config vendored Normal file
View file

@ -0,0 +1,22 @@
#!/bin/sh
# config maintainer script for gitlab
set -e
# source debconf stuffs
. /usr/share/debconf/confmodule
# DB password can be left blank
db_input high gitlab/dbpass || true
db_go || true
# source dbconfig-common shell library, and call the hook function
if [ -f /usr/share/dbconfig-common/dpkg/config.pgsql ]; then
. /usr/share/dbconfig-common/dpkg/config.pgsql
dbc_dbname="gitlab_production"
dbc_dbuser="gitlab"
if ! dbc_go gitlab $@; then
echo 'Automatic database configuration using dbconfig-common failed!'
fi
fi

23
debian/gitlab.templates vendored Normal file
View file

@ -0,0 +1,23 @@
Template: gitlab/dbpass
Type: note
_Description: PostgreSQL application password
You can leave the PostgreSQL application password blank, as the "ident"
authentication method is used, allowing the gitlab user on the system
to connect to the gitlab database without a password.
Template: gitlab/ssl
Type: boolean
Default: true
_Description: Enable https?
Enabling https means that an SSL certificate is required to access this
Gitlab instance (as Nginx will be configured to respond only to https
requests). A self-signed certificate is enough for local testing (and
can be generated using, for instance, the package easy-rsa), but it is
recommended for a production instance.
.
Some certificate authorities like StartSSL (startssl.com) or WoSign
(buy.wosign.com/free) offer free SSL certificates.
.
You can disable https if you want to access Gitlab only locally, via
Unicorn on port 3000. If you disable https, Nginx configuration will be
skipped.