Add script to create deb package
This commit is contained in:
54
assets/systemd/mysqladm.service
Normal file
54
assets/systemd/mysqladm.service
Normal file
@@ -0,0 +1,54 @@
|
||||
[Unit]
|
||||
Description=MySQL administration tool for non-admin users
|
||||
Requires=mysqladm.socket
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/bin/mysqladm-rs server --systemd socket-activate
|
||||
|
||||
WatchdogSec=15
|
||||
|
||||
User=mysqladm
|
||||
Group=mysqladm
|
||||
DynamicUser=yes
|
||||
|
||||
ConfigurationDirectory=mysqladm
|
||||
RuntimeDirectory=mysqladm
|
||||
|
||||
# This is required to read unix user/group details.
|
||||
PrivateUsers=false
|
||||
|
||||
# Needed to communicate with MySQL.
|
||||
PrivateNetwork=false
|
||||
PrivateIPC=false
|
||||
|
||||
AmbientCapabilities=
|
||||
CapabilityBoundingSet=
|
||||
DeviceAllow=
|
||||
DevicePolicy=closed
|
||||
LockPersonality=true
|
||||
MemoryDenyWriteExecute=true
|
||||
NoNewPrivileges=true
|
||||
PrivateDevices=true
|
||||
PrivateMounts=true
|
||||
PrivateTmp=yes
|
||||
ProcSubset=pid
|
||||
ProtectClock=true
|
||||
ProtectControlGroups=strict
|
||||
ProtectHome=true
|
||||
ProtectHostname=true
|
||||
ProtectKernelLogs=true
|
||||
ProtectKernelModules=true
|
||||
ProtectKernelTunables=true
|
||||
ProtectProc=invisible
|
||||
ProtectSystem=strict
|
||||
RemoveIPC=true
|
||||
RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6
|
||||
RestrictNamespaces=true
|
||||
RestrictRealtime=true
|
||||
RestrictSUIDSGID=true
|
||||
SocketBindDeny=any
|
||||
SystemCallArchitectures=native
|
||||
SystemCallFilter=@system-service
|
||||
SystemCallFilter=~@privileged @resources
|
||||
UMask=0777
|
||||
8
assets/systemd/mysqladm.socket
Normal file
8
assets/systemd/mysqladm.socket
Normal file
@@ -0,0 +1,8 @@
|
||||
[Unit]
|
||||
Description=MySQL administration tool for non-admin users
|
||||
WantedBy=sockets.target
|
||||
|
||||
[Socket]
|
||||
ListenStream=/run/mysqladm/mysqladm.sock
|
||||
Accept=no
|
||||
PassCredentials=true
|
||||
Reference in New Issue
Block a user