Oops, enable the Forgejo service!
That's a step I've been forgetting with services lately, but yeah, I ran into this where analytics.openneo.net went down and I wasn't sure why it didn't get auto-restarted, and I think it being Started But Not Enabled is why. So, ta-da! Fix it here before we run into that lol. Also I refactored the handlers a bit, after seeing how I did it in the analytics Ansible file and going like. Oh, yeah, that's just better lol
This commit is contained in:
parent
6ca70721ec
commit
e0ffcbdd7f
1 changed files with 7 additions and 2 deletions
|
@ -59,16 +59,21 @@
|
||||||
src: files/forgejo.service
|
src: files/forgejo.service
|
||||||
dest: /etc/systemd/system/forgejo.service
|
dest: /etc/systemd/system/forgejo.service
|
||||||
notify:
|
notify:
|
||||||
|
- Reload service files
|
||||||
- Restart Forgejo
|
- Restart Forgejo
|
||||||
|
|
||||||
- name: Start Forgejo service
|
- name: Enable Forgejo service
|
||||||
systemd_service:
|
systemd_service:
|
||||||
name: forgejo
|
name: forgejo
|
||||||
|
enabled: true
|
||||||
state: started
|
state: started
|
||||||
|
|
||||||
handlers:
|
handlers:
|
||||||
|
- name: Reload service files
|
||||||
|
systemd_service:
|
||||||
|
daemon_reload: true
|
||||||
|
|
||||||
- name: Restart Forgejo
|
- name: Restart Forgejo
|
||||||
systemd_service:
|
systemd_service:
|
||||||
name: forgejo
|
name: forgejo
|
||||||
state: restarted
|
state: restarted
|
||||||
daemon_reload: true # For the case where the service file changes!
|
|
||||||
|
|
Loading…
Reference in a new issue