1
1
Fork 0
mirror of https://github.com/roles-ansible/ansible_role_gitea.git synced 2024-08-16 11:39:50 +02:00

solve issue with gitea gpg key and download

Change gitea gpg behaviour and change download filename
This commit is contained in:
L3D 2023-01-26 04:12:00 +01:00
parent 47c3dedd1e
commit 8928b243b1
Signed by: l3d
GPG key ID: CD08445BFF4313D1
2 changed files with 8 additions and 3 deletions

View file

@ -51,11 +51,16 @@
changed_when: false changed_when: false
failed_when: _gitea_gpg_key_status.rc not in (0, 2) failed_when: _gitea_gpg_key_status.rc not in (0, 2)
- name: print gpg key staus on verbosity
ansible.builtin.debug:
msg: "{{ _gitea_gpg_key_status.stdout }}"
verbosity: 1
- name: Import gitea gpg key - name: Import gitea gpg key
ansible.builtin.command: "gpg --keyserver {{ gitea_gpg_server }} --recv {{ gitea_gpg_key }}" ansible.builtin.command: "gpg --keyserver {{ gitea_gpg_server }} --recv {{ gitea_gpg_key }}"
register: _gitea_import_key register: _gitea_import_key
changed_when: '"imported: 1" in _gitea_import_key.stderr' changed_when: '"imported: 1" in _gitea_import_key.stderr'
when: _gitea_gpg_key_status.rc != 0 when: '_gitea_gpg_key_status.rc != 0 or "expired" in _gitea_gpg_key_status.stdout'
- name: Check archive signature - name: Check archive signature
ansible.builtin.command: "gpg --verify /tmp/{{ gitea_filename }}.xz.asc /tmp/{{ gitea_filename }}.xz" ansible.builtin.command: "gpg --verify /tmp/{{ gitea_filename }}.xz.asc /tmp/{{ gitea_filename }}.xz"

View file

@ -8,7 +8,7 @@ gitea_go_arch_map:
armv5l: 'arm-5' armv5l: 'arm-5'
gitea_arch: "{{ gitea_go_arch_map[ansible_architecture] | default(ansible_architecture) }}" gitea_arch: "{{ gitea_go_arch_map[ansible_architecture] | default(ansible_architecture) }}"
gitea_filename: "gitea-{{ gitea_version }}.linux-{{ gitea_arch }}" gitea_filename: "gitea-{{ gitea_version_target }}.linux-{{ gitea_arch }}"
gitea_variables: gitea_variables:
files: files:
@ -56,5 +56,5 @@ transfer_custom_footer:
- 'files/gitea_footer/extra_links_footer.tmpl' - 'files/gitea_footer/extra_links_footer.tmpl'
- 'files/extra_links_footer.tmpl' - 'files/extra_links_footer.tmpl'
playbook_version_number: 40 # should be int playbook_version_number: 41 # should be int
playbook_version_path: 'do1jlr.gitea.version' playbook_version_path: 'do1jlr.gitea.version'