mirror of
https://github.com/roles-ansible/ansible_role_gitea.git
synced 2024-08-16 11:39:50 +02:00
Merge pull request #145 from roles-ansible/systemd
Create systemd unit for all systems
This commit is contained in:
commit
7857a62eb2
7 changed files with 17 additions and 17 deletions
|
@ -1,4 +1,4 @@
|
||||||
[![Ansible Galaxy](https://ansible.l3d.space/svg/l3d.gitea.svg)](https://galaxy.ansible.com/ui/standalone/roles/l3d/gitea/)
|
[![Ansible Galaxy](https://ansible.l3d.space/svg/l3d.gitea.svg)](https://galaxy.ansible.com/ui/standalone/roles/roles-ansible/gitea/)
|
||||||
[![BSD-3 Clause](https://ansible.l3d.space/svg/l3d.gitea_license.svg)](LICENSE)
|
[![BSD-3 Clause](https://ansible.l3d.space/svg/l3d.gitea_license.svg)](LICENSE)
|
||||||
[![Maintainance](https://ansible.l3d.space/svg/l3d.gitea_maintainance.svg)](https://ansible.l3d.space/#l3d.gitea)
|
[![Maintainance](https://ansible.l3d.space/svg/l3d.gitea_maintainance.svg)](https://ansible.l3d.space/#l3d.gitea)
|
||||||
|
|
||||||
|
|
|
@ -1,23 +1,9 @@
|
||||||
---
|
---
|
||||||
- name: "Setup systemd service"
|
- name: "Setup systemd service"
|
||||||
become: true
|
become: true
|
||||||
when: ansible_os_family == "Debian"
|
|
||||||
ansible.builtin.template:
|
ansible.builtin.template:
|
||||||
src: gitea.service.j2
|
src: gitea.service.j2
|
||||||
dest: /lib/systemd/system/gitea.service
|
dest: "{{ gitea_systemd_path }}/gitea.service"
|
||||||
owner: root
|
|
||||||
group: root
|
|
||||||
mode: 0644
|
|
||||||
notify:
|
|
||||||
- "Reload systemd"
|
|
||||||
- "Restart gitea"
|
|
||||||
|
|
||||||
- name: "Setup systemd service"
|
|
||||||
become: true
|
|
||||||
when: ansible_os_family == "Suse"
|
|
||||||
ansible.builtin.template:
|
|
||||||
src: gitea.service.j2
|
|
||||||
dest: /etc/systemd/system/gitea.service
|
|
||||||
owner: root
|
owner: root
|
||||||
group: root
|
group: root
|
||||||
mode: 0644
|
mode: 0644
|
||||||
|
|
|
@ -3,3 +3,5 @@ gitea_dependencies:
|
||||||
- git
|
- git
|
||||||
- gnupg2
|
- gnupg2
|
||||||
- xz-utils
|
- xz-utils
|
||||||
|
|
||||||
|
gitea_systemd_path: '/lib/systemd/system'
|
||||||
|
|
|
@ -23,6 +23,7 @@ gitea_variables:
|
||||||
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
- "{{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
|
||||||
- "{{ ansible_distribution | lower }}.yml"
|
- "{{ ansible_distribution | lower }}.yml"
|
||||||
- "{{ ansible_os_family | lower }}.yml"
|
- "{{ ansible_os_family | lower }}.yml"
|
||||||
|
- 'os_fallback_defaults.yml'
|
||||||
paths:
|
paths:
|
||||||
- 'vars'
|
- 'vars'
|
||||||
|
|
||||||
|
@ -62,5 +63,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: 55
|
playbook_version_number: 56
|
||||||
playbook_version_path: 'do1jlr.gitea.version'
|
playbook_version_path: 'do1jlr.gitea.version'
|
||||||
|
|
7
vars/os_fallback_defaults.yml
Normal file
7
vars/os_fallback_defaults.yml
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
---
|
||||||
|
gitea_dependencies:
|
||||||
|
- git
|
||||||
|
- gnupg2
|
||||||
|
- xz-utils
|
||||||
|
|
||||||
|
gitea_systemd_path: '/lib/systemd/system'
|
|
@ -3,3 +3,5 @@ gitea_dependencies:
|
||||||
- git
|
- git
|
||||||
- gnupg2
|
- gnupg2
|
||||||
- xz
|
- xz
|
||||||
|
|
||||||
|
gitea_systemd_path: '/lib/systemd/system'
|
||||||
|
|
|
@ -3,3 +3,5 @@ gitea_dependencies:
|
||||||
- git
|
- git
|
||||||
- gpg2
|
- gpg2
|
||||||
- xz
|
- xz
|
||||||
|
|
||||||
|
gitea_systemd_path: '/etc/systemd/system'
|
||||||
|
|
Loading…
Reference in a new issue