18 lines
		
	
	
		
			467 B
		
	
	
	
		
			SYSTEMD
		
	
	
	
	
	
		
		
			
		
	
	
			18 lines
		
	
	
		
			467 B
		
	
	
	
		
			SYSTEMD
		
	
	
	
	
	
|  | # https://www.digitalocean.com/community/tutorials/how-to-deploy-node-js-applications-using-systemd-and-nginx | ||
|  | # goes in /etc/systemd/system/holepunch.service | ||
|  | # systemctl enable holepunch | ||
|  | # systemctl start holepunch | ||
|  | 
 | ||
|  | [Service] | ||
|  | ExecStart=/usr/local/bin/node /srv/holepunch/bin/service.js | ||
|  | Restart=always | ||
|  | StandardOutput=syslog | ||
|  | StandardError=syslog | ||
|  | SyslogIdentifier=node-holepunch | ||
|  | User=root | ||
|  | Group=root | ||
|  | Environment=NODE_ENV=production | ||
|  | 
 | ||
|  | [Install] | ||
|  | WantedBy=multi-user.target |