From 5443eb45834339cb5bfd4a8b1dbd2a6cd3de07cf Mon Sep 17 00:00:00 2001 From: Sameer Naik Date: Sat, 26 Apr 2014 17:40:04 +0530 Subject: [PATCH] added GITLAB_SSL_SELF_SIGNED configuration option --- Changelog.md | 1 + README.md | 1 + assets/config/gitlab-shell/config.yml | 2 +- assets/init | 2 ++ 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Changelog.md b/Changelog.md index 507dc38c..29e3f3a7 100644 --- a/Changelog.md +++ b/Changelog.md @@ -1,6 +1,7 @@ # Changelog **latest** +- added GITLAB_SSL_SELF_SIGNED configuration option to specify use of self signed ssl certificates. - fix git over ssh when the default http/https ports are not used. - compile the assets only if it does not exist or if the gitlab version has changed. - upgrade gitlab-shell to version 1.9.4 diff --git a/README.md b/README.md index 1aad8782..d9885e60 100644 --- a/README.md +++ b/README.md @@ -461,6 +461,7 @@ Below is the complete list of available options that can be used to customize yo - **GITLAB_BACKUP_EXPIRY**: Configure how long to keep backups before they are deleted. By default when automated backups are disabled backups are kept forever (0 seconds), else the backups expire in 7 days (604800 seconds). - **GITLAB_SHELL_SSH_PORT**: The ssh port number. Defaults to 22. - **GITLAB_HTTPS**: Set to true to enable https support, disabled by default. +- **GITLAB_SSL_SELF_SIGNED**: Set to true when using self signed ssl certificates. false by default. - **REDIS_HOST**: The hostname of the redis server. Defaults to localhost - **REDIS_PORT**: The connection port of the redis server. Defaults to 6379. - **UNICORN_WORKERS**: The number of unicorn workers to start. Defaults to 2. diff --git a/assets/config/gitlab-shell/config.yml b/assets/config/gitlab-shell/config.yml index 905b0bc2..dcff994e 100644 --- a/assets/config/gitlab-shell/config.yml +++ b/assets/config/gitlab-shell/config.yml @@ -9,7 +9,7 @@ http_settings: # password: somepass # ca_file: /etc/ssl/cert.pem # ca_path: /etc/pki/tls/certs - self_signed_cert: false + self_signed_cert: {{GITLAB_SSL_SELF_SIGNED}} # Repositories path # Give the canonicalized absolute pathname, diff --git a/assets/init b/assets/init index 16ed2a50..d7ef83c7 100755 --- a/assets/init +++ b/assets/init @@ -4,6 +4,7 @@ set -e GITLAB_HOST=${GITLAB_HOST:-localhost} GITLAB_PORT=${GITLAB_PORT:-} GITLAB_HTTPS=${GITLAB_HTTPS:-false} +GITLAB_SSL_SELF_SIGNED=${GITLAB_SSL_SELF_SIGNED:-false} GITLAB_EMAIL=${GITLAB_EMAIL:-gitlab@localhost} GITLAB_SUPPORT=${GITLAB_SUPPORT:-support@localhost} GITLAB_SIGNUP=${GITLAB_SIGNUP:-false} @@ -235,6 +236,7 @@ sudo -u git -H sed 's/{{REDIS_PORT}}/'"${REDIS_PORT}"'/' -i /home/git/gitlab/con # configure gitlab-shell sudo -u git -H sed 's,{{GITLAB_URL}},'"${GITLAB_URL}"',' -i /home/git/gitlab-shell/config.yml +sudo -u git -H sed 's/{{GITLAB_SSL_SELF_SIGNED}}/'"${GITLAB_SSL_SELF_SIGNED}"'/' -i /home/git/gitlab-shell/config.yml sudo -u git -H sed 's/{{REDIS_HOST}}/'"${REDIS_HOST}"'/' -i /home/git/gitlab-shell/config.yml sudo -u git -H sed 's/{{REDIS_PORT}}/'"${REDIS_PORT}"'/' -i /home/git/gitlab-shell/config.yml