[Unit] Description=PostgreSQL <%= version %> After=network.target [Service] Type=notify #Type=simple User=postgres Group=services ExecStart=<%= postgres_bin %> -D <%= database_dir %> StandardOutput=journal StandardError=journal ExecReload=/bin/kill -HUP $MAINPID KillMode=mixed TimeoutSec=300 Restart=on-failure NotifyAccess=all # Security #ProtectSystem=full #ProtectHome=true ReadWritePaths=<%= database_dir %> # PrivateTmp=true NoNewPrivileges=true # Resource Limits LimitNOFILE=65536 [Install] WantedBy=multi-user.target