如何使用
1
| npm install hexo-deployer-rsync --save
|
然后配置_config.yml
1 2 3 4 5 6 7 8 9
| deploy: type: rsync host: <your-host-ip> user: root root: /var/www/blog port: 22 delete: true verbose: true ignore_errors: false
|
对于nginx
1 2 3 4 5 6 7 8 9 10 11 12 13 14
| server { listen 10004; listen [::]:10004;
# server_name grasscube.top;
root /var/www/blog; index index.html;
location / { try_files $uri $uri/ /404.html; } }
|
Ref
https://hexo.io/zh-cn/docs/one-command-deployment