Skip to content

Commit b90e08d

Browse files
DemetrisChrbrett19
authored andcommitted
Allow setting 0 replicas in buckets add command
1 parent e948ceb commit b90e08d

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

deployment/dockerdeploy/deployer.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -638,11 +638,6 @@ func (d *Deployer) CreateBucket(ctx context.Context, clusterID string, opts *dep
638638
ramQuotaMb = opts.RamQuotaMB
639639
}
640640

641-
numReplicas := 1
642-
if opts.NumReplicas > 1 {
643-
numReplicas = opts.NumReplicas
644-
}
645-
646641
err = agent.CreateBucket(ctx, &cbmgmtx.CreateBucketOptions{
647642
BucketName: opts.Name,
648643
BucketSettings: cbmgmtx.BucketSettings{
@@ -652,7 +647,7 @@ func (d *Deployer) CreateBucket(ctx context.Context, clusterID string, opts *dep
652647
ConflictResolutionType: "seqno",
653648
MutableBucketSettings: cbmgmtx.MutableBucketSettings{
654649
EvictionPolicy: "valueOnly",
655-
ReplicaNumber: uint32(numReplicas),
650+
ReplicaNumber: uint32(opts.NumReplicas),
656651
DurabilityMinLevel: "none",
657652
CompressionMode: "passive",
658653
MaxTTL: 0,

0 commit comments

Comments
 (0)