project-path> go run main.go
proejct-path> go run main.go [full-path-to-project]
connect with localhost:8080
- Install deployer project
project-path> go install
- Edit deployer.service file
Original
ExecStart=/GOBIN/deployer /PROJECT-PATH
Example
ExecStart=/home/pi/go/bin/deployer /home/pi/deployer
- Copy system unit
project-path> sudo cp ./deployer.service /etc/systemd/system/deployer.serive
- Start system unit
> sudo systemctl start deployer.service
- (Optional) Restart unit on reboot
> sudo systemctl enable deployer.service
- connect with localhost:8080