通过AWS Amplify Console进入您的项目。
选择您的应用程序。
选择'部署中”选项卡。
单击'手动部署”。
在'高级字段”下,找到'前往部署开始阶段”字段并将其设置为'是”。
单击'部署”。
以下是一个示例Amplify配置文件,在其中可以启用startDeployment:
{
"version": "1.0",
"frontend": {
"phase": "build",
"config": {
"build": {
"commands": [
"npm ci",
"npm run build"
]
},
"start": {
"command": "npm start"
}
}
},
"deploy": {
"production": {
"files": [
"build/**"
],
"cacheControl": "max-age=31536000,public",
"startDeployment": true
}
}
}
在上面的配置文件中,'startDeployment”设置为true。