[Unit]
Description=NanoPow Server
-[Service]
-# Must point at install path, often in `npm_config_prefix` directory:
-WorkingDirectory=%h/.local/lib/node_modules/nano-pow
+[Install]
+WantedBy=default.target
+[Service]
Type=simple
ExecStart=/usr/bin/npm start
EnvironmentFile=-%h/.nano-pow/config
PassEnvironment=NANO_POW_DEBUG NANO_POW_EFFORT NANO_POW_PORT
+StandardOutput=journal
+StandardError=journal
-[Install]
-WantedBy=default.target
+## Path must point at the nano-pow package in the global npm installation
+## directory. This is usually defined as the `npm_config_prefix` directory and
+## can be discovered using `npm -g prefix`. Append "/lib/node_modules/nano-pow"
+## to this path; if it's in your home directory, replace that with "%h". A full
+## example is as follows:
+##
+WorkingDirectory=%h/.local/lib/node_modules/nano-pow