From 0d8223f8e8b82736177b6eb9e7d0ec9628539884 Mon Sep 17 00:00:00 2001 From: Praveen Arimbrathodiyil Date: Sat, 24 Oct 2015 13:00:34 +0530 Subject: [PATCH] add config and templates --- debian/config | 22 ++++++++++++++++++++++ debian/gitlab.templates | 23 +++++++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 debian/config create mode 100644 debian/gitlab.templates diff --git a/debian/config b/debian/config new file mode 100644 index 0000000000..f24e0b2ce4 --- /dev/null +++ b/debian/config @@ -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 + diff --git a/debian/gitlab.templates b/debian/gitlab.templates new file mode 100644 index 0000000000..326bc72f7e --- /dev/null +++ b/debian/gitlab.templates @@ -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.