paulbsd-salt/states/apt/init.sls
2023-07-02 21:32:49 +02:00

33 lines
727 B
Plaintext

---
{%- from "apt/map.jinja" import apt with context %}
apt-deps:
pkg.installed:
- pkgs:
- avahi-daemon
- avahi-utils
apt-proxy-detect-py:
file.managed:
- name: /usr/local/bin/apt-proxy-detect.py
- source: salt://apt/templates/apt.py.j2
- template: jinja
- mode: "0755"
apt-proxy-detect-go:
file.managed:
- name: /usr/local/bin/apt-proxy-detect
- source: {{ apt.fetch_url }}/apt_{{ apt.arch }}
- template: jinja
- skip_verify: true
- mode: "0755"
{% for key, value in apt.config.items() -%}
apt-proxy-{{ key }}:
file.managed:
- name: /etc/apt/apt.conf.d/{{ key }}
- user: root
- group: root
- mode: "0644"
- contents: {{ value }}
{% endfor -%}