CodeBuild 使用 aws codebuild cli 设置无 VPC

问题描述 投票:0回答:2

如何使用 aws codebuild cli 设置无 VPC? 我尝试使用:

aws codebuild update-project \
  --name <PROJECT_NAME> \
  --vpc-config vpcId='',subnets='',securityGroupIds=''

但我收到错误:

Invalid length for parameter vpcConfig.subnets[0], value: 0, valid range: 1-inf
Invalid length for parameter vpcConfig.vpcId, value: 0, valid range: 1-inf
Invalid length for parameter vpcConfig.securityGroupIds[0], value: 0, valid range: 1-inf
aws-codebuild
2个回答
1
投票

使用

null
代替空字符串
''
:

--vpc-config vpcId=null,subnets=null,securityGroupIds=null

0
投票

这是对我有用的解决方案

aws codebuild update-project --name <projName> --vpc-config {}

© www.soinside.com 2019 - 2024. All rights reserved.