-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdiscord-account-verification.service
62 lines (53 loc) · 1.49 KB
/
discord-account-verification.service
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
[Unit]
Description=discord account verification Account verification bot for club elec's Discord server
After=network.target
[Service]
Type=exec
# environment variables
Environment=HOME=/opt/discord-account-verification/
Environment=SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt
Environment=BOT_TOKEN=
Environment=PUBLIC_CHANNEL=
ROLE=
Environment=DATABASE_PATH=/opt/discord-account-verification/database.db
# working directory and exec
WorkingDirectory=/opt/discord-account-verification
ExecStart=/opt/discord-account-verification/.env/bin/python3 main.py
ExecStop=/usr/bin/kill -9 $MAINPID
Restart=on-failure
RestartSec=10s
User=discord-account-verification
Group=discord-account-verification
# filesystem
TemporaryFileSystem=/:ro
BindReadOnlyPaths=/lib/ /lib64/ /usr/lib/ /usr/lib64/ /etc/ssl/certs/
BindReadOnlyPaths=/usr/bin/python3 /usr/bin/python3.9 /usr/bin/kill
BindPaths=/opt/discord-account-verification/
PrivateTmp=true
PrivateDevices=true
ProtectControlGroups=true
ProtectKernelModules=true
ProtectKernelTunables=true
ProtectKernelLogs=true
ReadWritePaths=
# network
RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
# misc
SystemCallArchitectures=native
SystemCallFilter=
NoNewPrivileges=true
RestrictRealtime=true
MemoryDenyWriteExecute=true
ProtectKernelLogs=true
LockPersonality=true
ProtectHostname=true
RemoveIPC=true
RestrictSUIDSGID=true
ProtectClock=true
ProtectProc=invisible
# capabilities
RestrictNamespaces=yes
CapabilityBoundingSet=
AmbientCapabilities=
[Install]
WantedBy=multi-user.target