Commit 04186e97 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge pull request #2987 from Undev/support_env_in_settings

Environments support added to Gitlab config
parents 7fad4a96 77a3bfe1
...@@ -7,12 +7,13 @@ ...@@ -7,12 +7,13 @@
# 2. Replace gitlab -> host with your domain # 2. Replace gitlab -> host with your domain
# 3. Replace gitlab -> email_from # 3. Replace gitlab -> email_from
# production: &base
# 1. GitLab app settings #
# ========================== # 1. GitLab app settings
# ==========================
## GitLab settings ## GitLab settings
gitlab: gitlab:
## Web server settings ## Web server settings
host: localhost host: localhost
port: 80 port: 80
...@@ -35,20 +36,20 @@ gitlab: ...@@ -35,20 +36,20 @@ gitlab:
default_projects_limit: 10 default_projects_limit: 10
# signup_enabled: true # default: false - Account passwords are not sent via the email if signup is enabled. # signup_enabled: true # default: false - Account passwords are not sent via the email if signup is enabled.
## Gravatar ## Gravatar
gravatar: gravatar:
enabled: true # Use user avatar images from Gravatar.com (default: true) enabled: true # Use user avatar images from Gravatar.com (default: true)
# plain_url: "http://..." # default: http://www.gravatar.com/avatar/%{hash}?s=%{size}&d=mm # plain_url: "http://..." # default: http://www.gravatar.com/avatar/%{hash}?s=%{size}&d=mm
# ssl_url: "https://..." # default: https://secure.gravatar.com/avatar/%{hash}?s=%{size}&d=mm # ssl_url: "https://..." # default: https://secure.gravatar.com/avatar/%{hash}?s=%{size}&d=mm
# #
# 2. Auth settings # 2. Auth settings
# ========================== # ==========================
## LDAP settings ## LDAP settings
ldap: ldap:
enabled: false enabled: false
host: '_your_ldap_server' host: '_your_ldap_server'
base: '_the_base_where_you_search_for_users' base: '_the_base_where_you_search_for_users'
...@@ -58,8 +59,8 @@ ldap: ...@@ -58,8 +59,8 @@ ldap:
bind_dn: '_the_full_dn_of_the_user_you_will_bind_with' bind_dn: '_the_full_dn_of_the_user_you_will_bind_with'
password: '_the_password_of_the_bind_user' password: '_the_password_of_the_bind_user'
## Omniauth settings ## Omniauth settings
omniauth: omniauth:
# Enable ability for users # Enable ability for users
# Allow logging in via Twitter, Google, etc. using Omniauth providers # Allow logging in via Twitter, Google, etc. using Omniauth providers
enabled: false enabled: false
...@@ -88,22 +89,22 @@ omniauth: ...@@ -88,22 +89,22 @@ omniauth:
# #
# 3. Advanced settings # 3. Advanced settings
# ========================== # ==========================
# GitLab Satellites # GitLab Satellites
satellites: satellites:
# Relative paths are relative to Rails.root (default: tmp/repo_satellites/) # Relative paths are relative to Rails.root (default: tmp/repo_satellites/)
path: /home/git/gitlab-satellites/ path: /home/git/gitlab-satellites/
## Backup settings ## Backup settings
backup: backup:
path: "tmp/backups" # Relative paths are relative to Rails.root (default: tmp/backups/) path: "tmp/backups" # Relative paths are relative to Rails.root (default: tmp/backups/)
# keep_time: 604800 # default: 0 (forever) (in seconds) # keep_time: 604800 # default: 0 (forever) (in seconds)
## GitLab Shell settings ## GitLab Shell settings
gitlab_shell: gitlab_shell:
# REPOS_PATH MUST NOT BE A SYMLINK!!! # REPOS_PATH MUST NOT BE A SYMLINK!!!
repos_path: /home/git/repositories/ repos_path: /home/git/repositories/
hooks_path: /home/git/gitlab-shell/hooks/ hooks_path: /home/git/gitlab-shell/hooks/
...@@ -115,13 +116,22 @@ gitlab_shell: ...@@ -115,13 +116,22 @@ gitlab_shell:
# If you use non-standart ssh port you need to specify it # If you use non-standart ssh port you need to specify it
# ssh_port: 22 # ssh_port: 22
## Git settings ## Git settings
# CAUTION! # CAUTION!
# Use the default values unless you really know what you are doing # Use the default values unless you really know what you are doing
git: git:
bin_path: /usr/bin/git bin_path: /usr/bin/git
# Max size of git object like commit, in bytes # Max size of git object like commit, in bytes
# This value can be increased if you have a very large commits # This value can be increased if you have a very large commits
max_size: 5242880 # 5.megabytes max_size: 5242880 # 5.megabytes
# Git timeout to read commit, in seconds # Git timeout to read commit, in seconds
timeout: 10 timeout: 10
development:
<<: *base
test:
<<: *base
staging:
<<: *base
class Settings < Settingslogic class Settings < Settingslogic
source "#{Rails.root}/config/gitlab.yml" source "#{Rails.root}/config/gitlab.yml"
namespace Rails.env
class << self class << self
def gitlab_on_non_standard_port? def gitlab_on_non_standard_port?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment