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

resolve linting errors

This commit is contained in:
L3D 2022-03-27 05:19:36 +02:00
parent 61a9111c4d
commit c179060741
Signed by: l3d
GPG key ID: CD08445BFF4313D1
4 changed files with 6 additions and 3 deletions

View file

@ -1,14 +1,14 @@
--- ---
- name: "Restart gitea" - name: "Restart gitea"
become: true become: true
service: ansible.builtin.service:
name: gitea name: gitea
state: restarted state: restarted
when: ansible_service_mgr == "systemd" when: ansible_service_mgr == "systemd"
- name: "Reload systemd" - name: "Reload systemd"
become: true become: true
systemd: ansible.builtin.systemd:
daemon_reload: true daemon_reload: true
when: ansible_service_mgr == "systemd" when: ansible_service_mgr == "systemd"

View file

@ -26,6 +26,7 @@
ansible.builtin.command: ansible.builtin.command:
cmd: "sudo -u {{ gitea_user }} gitea dump -c /etc/gitea/gitea.ini" cmd: "sudo -u {{ gitea_user }} gitea dump -c /etc/gitea/gitea.ini"
chdir: "{{ gitea_backup_location }}" chdir: "{{ gitea_backup_location }}"
changed_when: true
when: when:
- ansible_facts.services["gitea.service"] is defined - ansible_facts.services["gitea.service"] is defined
- ansible_facts.services["gitea.service"].state == "running" - ansible_facts.services["gitea.service"].state == "running"

View file

@ -7,7 +7,7 @@
state: "present" state: "present"
- name: Switch shell when not using the builtin ssh server - name: Switch shell when not using the builtin ssh server
set_fact: ansible.builtin.set_fact:
gitea_shell: "/bin/bash" gitea_shell: "/bin/bash"
when: "not gitea_start_ssh and gitea_shell == '/bin/false'" when: "not gitea_start_ssh and gitea_shell == '/bin/false'"

View file

@ -26,6 +26,7 @@
url: "{{ gitea_dl_url }}.xz" url: "{{ gitea_dl_url }}.xz"
dest: "/tmp/{{ gitea_filename }}.xz" dest: "/tmp/{{ gitea_filename }}.xz"
checksum: "sha256:{{ gitea_dl_url }}.xz.sha256" checksum: "sha256:{{ gitea_dl_url }}.xz.sha256"
mode: 0640
register: _download_archive register: _download_archive
until: _download_archive is succeeded until: _download_archive is succeeded
retries: 5 retries: 5
@ -35,6 +36,7 @@
ansible.builtin.get_url: ansible.builtin.get_url:
url: "{{ gitea_dl_url }}.xz.asc" url: "{{ gitea_dl_url }}.xz.asc"
dest: "/tmp/{{ gitea_filename }}.xz.asc" dest: "/tmp/{{ gitea_filename }}.xz.asc"
mode: 0640
register: _download_asc register: _download_asc
until: _download_asc is succeeded until: _download_asc is succeeded
retries: 5 retries: 5