Skip to content

Commit

Permalink
Added sample systemd unit files for deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardogsilva committed Dec 6, 2024
1 parent 09eed3e commit 6b18e98
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 0 deletions.
7 changes: 7 additions & 0 deletions deployments/systemd-unit-files/clean-docker-images.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[Unit]
Description="Clean up docker images"

[Service]
Type=simple
ExecStart=/usr/bin/docker system prune --all --force
User={CHANGE_ME}
10 changes: 10 additions & 0 deletions deployments/systemd-unit-files/clean-docker-images.timer
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[Unit]
Description="Timer for the clean-docker-images service"

[Timer]
Unit=clean-docker-images.service
OnCalendar=Sun *-*-* 01:00:00
Persistent=true

[Install]
WantedBy=timers.target
10 changes: 10 additions & 0 deletions deployments/systemd-unit-files/webhook.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# systemd service file for the webhook server
# - Create the `/etc/systemd/system/webhook.service` file with these contents
# - Run `sudo systemctl daemon-relaod`
# - Finally run sudo systemctl start webhook.conf

[Service]
Environment="WEBHOOK_SECRET={CHANGE_ME}"
ExecStart=/usr/bin/webhook -template -port {CHANGE_ME} -hooks {CHANGE_ME}
User={CHANGE_ME}
Group={CHANGE_ME}

0 comments on commit 6b18e98

Please sign in to comment.