--- - name: Create Hcloud token secret kubernetes.core.k8s: state: present definition: apiVersion: v1 kind: Secret metadata: name: hcloud-csi namespace: kube-system data: token: "{{ HcloudToken | b64encode }}" - name: Create temporary file ansible.builtin.tempfile: state: file suffix: temp register: csi_manifest_tmp - name: Download CSI manifest ansible.builtin.get_url: url: https://raw.githubusercontent.com/hetznercloud/csi-driver/v1.6.0/deploy/kubernetes/hcloud-csi.yml dest: "{{ csi_manifest_tmp.path }}" mode: '0664' - name: Deploy CSI driver kubernetes.core.k8s: state: present src: "{{ csi_manifest_tmp.path }}"