Browse Source

Adding Custom Changes for Debian

Adding a require to /etc/apt/listchanges.conf for the package
apt-listchanges so that listchanges.conf doesn't get added before the
listchanges package is installed causing apt to hit a catch 22.

Add an if statement to 50unattended-upgrades so that Debian doesn't
get Unattended-Upgrade::Allowed-Origins which doesn't work and causes
unattended upgrades to stop.
master
Nate Bohman 6 years ago
parent
commit
459871b18d
2 changed files with 4 additions and 0 deletions
  1. +2
    -0
      apt/listchanges.sls
  2. +2
    -0
      apt/templates/unattended_config.jinja

+ 2
- 0
apt/listchanges.sls View File

- group: root - group: root
- mode: 644 - mode: 644
- source: {{ listchanges_config_template }} - source: {{ listchanges_config_template }}
- require:
- pkg: apt-listchanges

+ 2
- 0
apt/templates/unattended_config.jinja View File

{% set automatic_reboot = unattended.get('automatic_reboot', 'false') -%} {% set automatic_reboot = unattended.get('automatic_reboot', 'false') -%}
{% set automatic_reboot_time = unattended.get('automatic_reboot_time', 'now') -%} {% set automatic_reboot_time = unattended.get('automatic_reboot_time', 'now') -%}
{% set dl_limit = unattended.get('dl_limit', '0') -%} {% set dl_limit = unattended.get('dl_limit', '0') -%}
{%- if salt['grains.get']('os') != 'Debian' -%}
Unattended-Upgrade::Allowed-Origins { Unattended-Upgrade::Allowed-Origins {
{%- for pattern in allowed_origins %} {%- for pattern in allowed_origins %}
"{{ pattern }}"; "{{ pattern }}";
{%- endfor %} {%- endfor %}
}; };
{%- endif %}
Unattended-Upgrade::Origins-Pattern { Unattended-Upgrade::Origins-Pattern {
{%- for pattern in origins_patterns %} {%- for pattern in origins_patterns %}
"{{ pattern }}"; "{{ pattern }}";

Loading…
Cancel
Save