mirror of https://github.com/sysown/proxysql
Debian controlfile and systemd's service update. Package ctl file will use service file and not /etc/init.d and service file has more systemd's parameters. Both have changes to make proxysql running under a non root user (arbitrary named proxysql).
parent
a20617ecd9
commit
4f800f908a
@ -0,0 +1,34 @@
|
||||
[Unit]
|
||||
Description=High Performance Advanced Proxy for MySQL
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
RuntimeDirectory=proxysql
|
||||
#PermissionsStartOnly=true
|
||||
#ExecStartPre=/usr/bin/mkdir -p /var/run/proxysql
|
||||
#ExecStartPre=/usr/bin/chown -R proxysql: /var/run/proxysql/
|
||||
ExecStart=/usr/bin/proxysql -f -c /etc/proxysql.cnf
|
||||
PIDFile=/var/run/proxysql/proxysql.pid
|
||||
#StandardError=null # all output is in stderr
|
||||
SyslogIdentifier=proxysql
|
||||
Restart=always
|
||||
User=proxysql
|
||||
Group=proxysql
|
||||
PermissionsStartOnly=true
|
||||
UMask=0007
|
||||
LimitNOFILE=102400
|
||||
LimitCORE=1073741824
|
||||
ProtectHome=yes
|
||||
ReadOnlyPaths=/
|
||||
ReadWritePaths=/var/lib/proxysql /var/run/proxysql
|
||||
NoNewPrivileges=true
|
||||
CapabilityBoundingSet=CAP_SETGID CAP_SETUID CAP_SYS_RESOURCE
|
||||
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX AF_ALG
|
||||
ProtectSystem=full
|
||||
PrivateDevices=yes
|
||||
ProtectKernelTunables=true
|
||||
ProtectControlGroups=true
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Loading…
Reference in new issue