[Unit]
Description=Plumber API

[Service]
ExecStart=/usr/bin/Rscript -e "pr <- plumber::pr('/var/plumber$PATH$/plumber.R'); pr$setDocs($DOCS$); $PREFLIGHT$ pr$run(port=$PORT$)"
Restart=on-abnormal
WorkingDirectory=/var/plumber/$PATH$/

[Install]
WantedBy=multi-user.target
