24 lines
623 B
JavaScript
24 lines
623 B
JavaScript
|
// .deployrc.js (ESM 格式)
|
||
|
import { readFileSync } from 'node:fs';
|
||
|
import { resolve } from 'node:path';
|
||
|
|
||
|
export default {
|
||
|
host: '112.74.106.216',
|
||
|
port: 22, // 默认 SSH 端口
|
||
|
username: 'root',
|
||
|
|
||
|
// 密码和私钥二选一
|
||
|
password: 'Smt1618?',
|
||
|
privateKey: null, // 示例: readFileSync(resolve(process.env.HOME, '.ssh/id_rsa')),
|
||
|
|
||
|
// 部署路径
|
||
|
remotePath: '/opt/1panel/apps/openresty/openresty/www/sites/www.amzups.com/index',
|
||
|
|
||
|
// 是否清空目标目录
|
||
|
cleanRemote: true
|
||
|
|
||
|
// 高级选项 (可选)
|
||
|
// uploadIgnore: ['*.map', 'tmp/*'],
|
||
|
// execAfterDeploy: 'sudo systemctl restart nginx'
|
||
|
};
|