Drop default AdminAuth
This commit is contained in:
parent
03d82da02d
commit
e4d1e7de10
2 changed files with 6 additions and 4 deletions
|
@ -7,6 +7,10 @@
|
||||||
|
|
||||||
# Basic authentication with username and password, required to
|
# Basic authentication with username and password, required to
|
||||||
# visit pages with administrative functionality. Format: username:password
|
# visit pages with administrative functionality. Format: username:password
|
||||||
{% from "apt-cacher/ng/map.jinja" import apt_cacher_ng with context %}
|
{%- set cfg = salt['pillar.get']('apt_cacher_ng', {}) %}
|
||||||
AdminAuth: {{ apt_cacher_ng.admin_account }}:{{ apt_cacher_ng.admin_passwd }}
|
{%- set admin_account = cfg.get('admin_account', False) %}
|
||||||
|
{%- set admin_passwd = cfg.get('admin_passwd', False) %}
|
||||||
|
{%- if admin_account and admin_passwd %}
|
||||||
|
AdminAuth: {{ admin_account }}:{{ admin_passwd }}
|
||||||
|
{%- endif %}
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,5 @@
|
||||||
'service': 'apt-cacher-ng',
|
'service': 'apt-cacher-ng',
|
||||||
'credentials': '/etc/apt-cacher-ng/security.conf',
|
'credentials': '/etc/apt-cacher-ng/security.conf',
|
||||||
'client_config': '/etc/apt/apt.conf.d/80proxy',
|
'client_config': '/etc/apt/apt.conf.d/80proxy',
|
||||||
'admin_account': 'root',
|
|
||||||
'admin_passwd': 'admin'
|
|
||||||
},
|
},
|
||||||
}, merge=salt['pillar.get']('apt_cacher_ng')) %}
|
}, merge=salt['pillar.get']('apt_cacher_ng')) %}
|
||||||
|
|
Loading…
Reference in a new issue