fix
This commit is contained in:
parent
2758299bee
commit
a025ef4425
7
files/etc/webhooks.json
Normal file
7
files/etc/webhooks.json
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
[
|
||||||
|
{
|
||||||
|
"id": "generate",
|
||||||
|
"execute-command": "/sbin/genHugo",
|
||||||
|
"command-working-directory": "/srv/hugo"
|
||||||
|
}
|
||||||
|
]
|
@ -1,3 +1,3 @@
|
|||||||
#!/sbin/openrc-run
|
#!/sbin/openrc-run
|
||||||
|
|
||||||
command=/srv/hugo/generate.sh
|
command=/sbin/genHugo
|
||||||
|
@ -2,5 +2,5 @@
|
|||||||
|
|
||||||
pidfile="/run/$RC_SVCNAME.pid"
|
pidfile="/run/$RC_SVCNAME.pid"
|
||||||
command="/usr/bin/webhook"
|
command="/usr/bin/webhook"
|
||||||
command_args="-hooks /srv/hugo/hooks.json -verbose"
|
command_args="-hooks /etc/webhooks.json -verbose"
|
||||||
command_background="yes"
|
command_background="yes"
|
||||||
|
5
files/sbin/genHugo
Normal file
5
files/sbin/genHugo
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
cd /srv/hugo
|
||||||
|
git pull
|
||||||
|
HUGO_ENV="production" hugo
|
@ -8,6 +8,18 @@
|
|||||||
dest: /srv/hugo
|
dest: /srv/hugo
|
||||||
version: master
|
version: master
|
||||||
|
|
||||||
|
- name: install genHugo
|
||||||
|
copy:
|
||||||
|
src: sbin/genHugo
|
||||||
|
dest: /sbin/genHugo
|
||||||
|
mode: 0755
|
||||||
|
|
||||||
|
- name: deploy webhook config
|
||||||
|
copy:
|
||||||
|
src: etc/webhooks.json
|
||||||
|
dest: /etc/webhooks.json
|
||||||
|
mode: 0644
|
||||||
|
|
||||||
- name: deploy init scripts
|
- name: deploy init scripts
|
||||||
copy:
|
copy:
|
||||||
src: "openrc/{{ item }}"
|
src: "openrc/{{ item }}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user