Obviously, you’ll want to replace [yourdirectory] with the location of your Hexo blog.
Start Hexo
1
$ sudo systemctl start hexo
View status of Hexo
1 2 3 4 5 6 7 8 9 10 11 12
$ sudo systemctl status hexo ● hexo.service Loaded: loaded (/usr/lib/systemd/system/hexo.service; disabled; vendor preset: disabled) Active: active (running) since Sat 2017-10-07 02:27:36 UTC; 7min ago Main PID: 8997 (hexo) CGroup: /system.slice/hexo.service └─8997 hexo
Oct 07 02:27:36 centos-2gb-nyc1-01 systemd[1]: Started hexo.service. Oct 07 02:27:36 centos-2gb-nyc1-01 systemd[1]: Starting hexo.service... Oct 07 02:27:38 centos-2gb-nyc1-01 hexo[8997]: INFO Start processing Oct 07 02:27:38 centos-2gb-nyc1-01 hexo[8997]: INFO Hexo is running at http://localhost:80/. Press Ctrl+C to stop.