Helps to add all the files

This commit is contained in:
Ubergeek 2019-03-22 21:53:49 +00:00
parent dda65471d9
commit cb610066db
3 changed files with 24 additions and 0 deletions

View File

@ -0,0 +1,14 @@
#!/bin/bash
export RUNNING="/dev/shm/gopher_is_running"
if [ -f $RUNNING ]; then
echo "Gopher is currently running."
exit 1
else
touch $RUNNING
cd /var/gopher
/usr/bin/git pull
touch /dev/shm/ansible-hook-last-run
rm $RUNNING
exit 0
fi

View File

@ -0,0 +1,6 @@
[Unit]
Description=gopher-run path
[Path]
PathModified=/dev/shm/gopher-ansible
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,4 @@
[Unit]
Description=gopher-run
[Service]
ExecStart=/usr/local/bin/gopher-run