paulbsd-salt/states/go-aptproxy/install.sls

27 lines
984 B
Plaintext

---
{%- from "go-aptproxy/map.jinja" import goaptproxy with context %}
go-aptproxy-archive-extract:
archive.extracted:
- name: {{ goaptproxy.release_dir }}/go-aptproxy-{{ go-aptproxy.version }}
- source: {{ goaptproxy.mirror }}/{{ go-aptproxy.version }}/go-aptproxy-{{ go-aptproxy.version }}-{{ go-aptproxy.os }}-{{ go-aptproxy.arch }}.tar.gz
- skip_verify: true
- enforce_toplevel: false
- if_missing: {{ goaptproxy.release_dir }}/go-aptproxy-{{ go-aptproxy.version }}
- watch_in:
- service: go-aptproxy-service
go-aptproxy-binary-symlink:
file.symlink:
- name: {{ goaptproxy.install_dir }}/go-aptproxy
- target: {{ goaptproxy.release_dir }}/go-aptproxy-{{ go-aptproxy.version }}
- require:
- archive: go-aptproxy-archive-extract
- watch_in:
- service: go-aptproxy-service
go-aptproxy-cleanup:
software.cleanup:
- name: go-aptproxy
- path: {{ goaptproxy.release_dir }}
- version: {{ goaptproxy.version }}