29 lines
1 KiB
YAML
29 lines
1 KiB
YAML
|
---
|
||
|
- name: Create .local/bin for ansible user
|
||
|
ansible.builtin.file:
|
||
|
path: "/home/{{ ansible_user | default(ansible_env.USER) }}/.local/bin"
|
||
|
state: directory
|
||
|
owner: "{{ ansible_user | default(ansible_env.USER) }}"
|
||
|
group: "{{ ansible_user | default(ansible_env.USER) }}"
|
||
|
mode: "0750"
|
||
|
|
||
|
- name: Prepare mkcert
|
||
|
block:
|
||
|
|
||
|
- name: Download mkcert binary
|
||
|
ansible.builtin.get_url:
|
||
|
url: "https://github.com/FiloSottile/mkcert/releases/download/{{ mkcert_version }}/mkcert-{{ mkcert_version }}-linux-amd64"
|
||
|
dest: "/home/{{ ansible_user | default(ansible_env.USER) }}/.local/bin/mkcert"
|
||
|
checksum: "sha256:{{ mkcert_checksum }}"
|
||
|
owner: "{{ ansible_user | default(ansible_env.USER) }}"
|
||
|
group: "{{ ansible_user | default(ansible_env.USER) }}"
|
||
|
mode: "0750"
|
||
|
|
||
|
- name: Install mkcert CA
|
||
|
ansible.builtin.command:
|
||
|
cmd: "/home/{{ ansible_user | default(ansible_env.USER) }}/.local/bin/mkcert -install"
|
||
|
changed_when: false
|
||
|
|
||
|
when: use_mkcert
|
||
|
become: false
|