---

- name: Compress previous version
  command: tar cf {{ cni_root_dir }}/archives/{{ cni_current_version }}.tar.zst ./ --use-compress-program=zstd
  args:
    chdir: "{{ cni_root_dir }}/archives/{{ cni_current_version }}"
  environment:
    ZSTD_CLEVEL: 10
  tags: cni

- name: Remove archive dir
  file: path={{ cni_root_dir }}/archives/{{ cni_current_version }} state=absent
  tags: cni
