This commit is contained in:
parent
7e44b8dac6
commit
fd79aff597
6 changed files with 79 additions and 0 deletions
13
files/davmail
Normal file
13
files/davmail
Normal file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
|
||||
JAVA_OPTS="-Xmx512M -Dsun.net.inetaddr.ttl=60 --add-exports java.base/sun.net.www.protocol.https=ALL-UNNAMED"
|
||||
|
||||
if [ -z "$JAVA_HOME" ]; then
|
||||
export JAVA_HOME=/usr/lib64/openjdk-21
|
||||
fi
|
||||
|
||||
if [ -z "$JAVA" ]; then
|
||||
export JAVA=$JAVA_HOME/bin/java
|
||||
fi
|
||||
|
||||
exec ${JAVA} $JAVA_OPTS -cp /usr/share/davmail/davmail.jar:/usr/share/davmail/lib/* davmail.DavGateway $@
|
21
files/davmail.service
Normal file
21
files/davmail.service
Normal file
|
@ -0,0 +1,21 @@
|
|||
[Unit]
|
||||
Description=Davmail Exchange gateway
|
||||
Documentation=http://davmail.sourceforge.net/serversetup.html
|
||||
Documentation=http://davmail.sourceforge.net/advanced.html
|
||||
Documentation=http://davmail.sourceforge.net/sslsetup.html
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=davmail
|
||||
PermissionsStartOnly=true
|
||||
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
||||
ExecStart=/usr/bin/davmail -server /etc/davmail.properties
|
||||
StateDirectory=davmail
|
||||
SuccessExitStatus=143
|
||||
PrivateTmp=yes
|
||||
ProtectSystem=full
|
||||
ProtectHome=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
1
files/davmail.sysusers
Normal file
1
files/davmail.sysusers
Normal file
|
@ -0,0 +1 @@
|
|||
u davmail - "DavMail Exchange and Office 365 Gateway" - -
|
1
files/davmail.tmpfiles
Normal file
1
files/davmail.tmpfiles
Normal file
|
@ -0,0 +1 @@
|
|||
f /var/log/davmail.log 0640 davmail davmail -
|
Loading…
Add table
Add a link
Reference in a new issue