Skip to content

Instantly share code, notes, and snippets.

@samicrusader
Created April 1, 2024 04:41
Show Gist options
  • Save samicrusader/efc6ef68b09f289779b77115fbdbed65 to your computer and use it in GitHub Desktop.
Save samicrusader/efc6ef68b09f289779b77115fbdbed65 to your computer and use it in GitHub Desktop.
glftpd systemd listen + reset timer
[Unit]
Description=glFTPd stats reset
[Service]
Type=oneshot
ExecStart=-/glftpd/bin/reset
RemainAfterExit=no
[Unit]
Description=glFTPd stats reset
[Timer]
# crontab time: 0 0 * * *
OnCalendar=daily
Unit=glftpd-reset.service
[Install]
WantedBy=timers.target
[Unit]
Description=glFTPd server
[Socket]
ReusePort=true
ListenStream=[::]:990
Accept=yes
#MaxConnections=64
[Install]
WantedBy=sockets.target
[Unit]
Description=glFTPd server
[Service]
ExecStart=-/glftpd/bin/glftpd -l -i -o
StandardInput=socket
SyslogFacility=ftp
# !!OPTIONAL!!
# disables ident checking (-I 0) and specifies full path for glstrings.bin when using glftpd in rootfs space (-s)
[Service]
ExecStart=
ExecStart=-/glftpd/bin/glftpd -l -i -o -I 0 -s /glftpd/bin/glstrings.bin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment