Browse Source

apt_conf: remove_* consistent with other similar options

remove_* was recently changed to always place empty file, but just set
perms if not present, without replace.

Do the same with that option.
master
Adrien "ze" Urban 6 years ago
parent
commit
de05ac6f1c
1 changed files with 10 additions and 4 deletions
  1. +10
    -4
      apt/apt_conf.sls

+ 10
- 4
apt/apt_conf.sls View File

{% set clean_apt_conf_d = salt['pillar.get']('apt:clean_apt_conf_d', apt_map.clean_apt_conf_d) %} {% set clean_apt_conf_d = salt['pillar.get']('apt:clean_apt_conf_d', apt_map.clean_apt_conf_d) %}
{% set apt_conf_d = salt['pillar.get']('apt:apt_conf_d', apt_map.apt_conf_d) %} {% set apt_conf_d = salt['pillar.get']('apt:apt_conf_d', apt_map.apt_conf_d) %}


{% if remove_apt_conf %}
/etc/apt/apt.conf: /etc/apt/apt.conf:
file:
- absent
{% endif %}
file.managed:
- mode: '0644'
- user: root
- group: root
{% if remove_apt_conf %}
- contents: ''
- contents_newline: False
{% else %}
- replace: False
{% endif %}


{{ confd_dir }}: {{ confd_dir }}:
file.directory: file.directory:

Loading…
Cancel
Save