https://github.com/chineseengineer/ali-oss-deploy-plus
https://github.com/chineseengineer/ali-oss-deploy-plus
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/chineseengineer/ali-oss-deploy-plus
- Owner: ChineseEngineer
- License: mit
- Created: 2022-05-06T07:10:24.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2023-05-16T01:00:08.000Z (about 3 years ago)
- Last Synced: 2025-01-28T17:07:42.653Z (over 1 year ago)
- Language: JavaScript
- Size: 40 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 前端项目部署到 OSS
## Usage
```bash
# 安装
npm install ali-oss-deploy-plus
```
```js
// 使用
const aliOssDeployPlus = require('ali-oss-deploy-plus')
const ossOpts = {
bucket: '', // 桶名称
region: '', // 区域
accessKeyId: '', // AK
accessKeySecret: '', // AS
internal: true, // 默认内网传输
}
const proOpts = {
projectPath: '', // oss 存放项目的路径
currentProjectPath: '', // 当前发布项目的文件夹路径 ps: dist
maxRetryTimes: 3, // 上传失败重试次数 默认 3
maxConcurrency: 100, // 上传最大并发数 默认 100
}
const aliDeploy = new aliOssDeployPlus({
ossOpts,
proOpts
})
aliDeploy.start()
```