feat: add complex variables in config file
This commit is contained in:
parent
1e057c9ba1
commit
ee3401e419
4 changed files with 15 additions and 1 deletions
|
@ -9,6 +9,7 @@ Which is based on [Keep A Changelog](http://keepachangelog.com/)
|
|||
|
||||
- feat: add gitlab_data_dir variable
|
||||
- feat: add gitlab_pages_url variable
|
||||
- feat: add complex variables in config file
|
||||
|
||||
### Changed
|
||||
|
||||
|
|
|
@ -12,6 +12,16 @@
|
|||
enable: false
|
||||
grafana:
|
||||
enable: false
|
||||
ldap_servers:
|
||||
main:
|
||||
label: Main AD
|
||||
host: localhost
|
||||
port: 389
|
||||
uid: sAMAccountName
|
||||
encryption: plain
|
||||
bind_dn: 'CN=gitlab,DC=example,DC=com'
|
||||
password: secret
|
||||
base: 'OU=FR,DC=example,DC=com'
|
||||
|
||||
pre_tasks:
|
||||
- name: delete dockerenv file
|
||||
|
|
|
@ -18,6 +18,7 @@ def test_config_file(host):
|
|||
assert config.mode == 0o600
|
||||
assert config.contains("external_url 'http://gitlab.example.com'")
|
||||
assert config.contains("grafana\\['enable'\\] = false")
|
||||
assert config.contains('label: Main AD')
|
||||
|
||||
def test_service(host):
|
||||
service = host.service('gitlab-runsvdir')
|
||||
|
|
|
@ -18,7 +18,9 @@ git_data_dirs({
|
|||
{% elif value is sameas false %}false
|
||||
{% elif value is string %}'{{ value }}'
|
||||
{% elif value is number %}{{ value }}
|
||||
{% else %}['{{ value|join("', '") }}']
|
||||
{% else %}YAML.load <<-EOS
|
||||
{{ value|to_nice_yaml }}
|
||||
EOS
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
|
|
Loading…
Reference in a new issue