2023-09-14 16:51:15 +02:00
|
|
|
---
|
|
|
|
{%- from "vector/map.jinja" import vector with context %}
|
|
|
|
vector-archive-extract:
|
|
|
|
archive.extracted:
|
|
|
|
- name: {{ vector.release_dir }}/vector-{{ vector.version }}
|
|
|
|
- source: {{ vector.mirror }}/v{{ vector.version }}/vector-{{ vector.version }}-{{ vector.arch }}-unknown-{{ vector.os }}-{{ vector.variant }}.tar.gz
|
|
|
|
- skip_verify: true
|
|
|
|
- enforce_toplevel: false
|
|
|
|
- options: >
|
|
|
|
--strip 2
|
|
|
|
- if_missing: {{ vector.release_dir }}/vector-{{ vector.version }}/bin/vector
|
2023-12-06 04:10:43 +01:00
|
|
|
- watch_in:
|
|
|
|
- service: vector-service
|
2023-09-14 16:51:15 +02:00
|
|
|
|
|
|
|
vector-binary-symlink:
|
|
|
|
file.symlink:
|
|
|
|
- name: /usr/local/bin/vector
|
|
|
|
- target: {{ vector.release_dir }}/vector-{{ vector.version }}/bin/vector
|
|
|
|
- force: true
|
|
|
|
- require:
|
|
|
|
- archive: vector-archive-extract
|
2023-12-06 04:10:43 +01:00
|
|
|
- watch_in:
|
|
|
|
- service: vector-service
|
2023-09-14 16:51:15 +02:00
|
|
|
|
|
|
|
vector-cleanup:
|
|
|
|
software.cleanup:
|
|
|
|
- name: vector
|
|
|
|
- path: {{ vector.release_dir }}
|
2023-12-06 04:10:43 +01:00
|
|
|
- version: "{{ vector.version }}"
|