paulbsd-salt/states/pki/install.sls
2023-07-13 19:30:08 +02:00

27 lines
769 B
Plaintext

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