From 657452f2b4070dc2b23f1fe390f176b6f9a6e4ff Mon Sep 17 00:00:00 2001
From: Christian Heller <c.heller@plomlompom.de>
Date: Sat, 15 Dec 2018 02:06:09 +0100
Subject: [PATCH] Regularly pull website repo on web server.

---
 .../web/etc/systemd/system/pull_website.service           | 5 +++++
 .../systemd/system/timers.target.wants/pull_website.timer | 8 ++++++++
 2 files changed, 13 insertions(+)
 create mode 100644 all_new_2018/linkable_etc_files/web/etc/systemd/system/pull_website.service
 create mode 100644 all_new_2018/linkable_etc_files/web/etc/systemd/system/timers.target.wants/pull_website.timer

diff --git a/all_new_2018/linkable_etc_files/web/etc/systemd/system/pull_website.service b/all_new_2018/linkable_etc_files/web/etc/systemd/system/pull_website.service
new file mode 100644
index 0000000..ea32ec7
--- /dev/null
+++ b/all_new_2018/linkable_etc_files/web/etc/systemd/system/pull_website.service
@@ -0,0 +1,5 @@
+[Unit]
+Description=Pull website repo
+[Service]
+Type=oneshot
+ExecStart=/bin/sh -c 'cd /var/www && git pull'
diff --git a/all_new_2018/linkable_etc_files/web/etc/systemd/system/timers.target.wants/pull_website.timer b/all_new_2018/linkable_etc_files/web/etc/systemd/system/timers.target.wants/pull_website.timer
new file mode 100644
index 0000000..6a42507
--- /dev/null
+++ b/all_new_2018/linkable_etc_files/web/etc/systemd/system/timers.target.wants/pull_website.timer
@@ -0,0 +1,8 @@
+[Unit]
+Description=Pull website repo every minute
+
+[Timer]
+OnCalendar=*-*-* *:*:00,15,30,45
+
+[Install]
+WantedBy=timers.target
-- 
2.30.2