Skip to content

Commit

Permalink
v2 volume: expose all replica instances
Browse files Browse the repository at this point in the history
Expose all logical volume and attach it to attached node.

Longhorn 8551

Signed-off-by: Derek Su <derek.su@suse.com>
  • Loading branch information
derekbit committed May 16, 2024
1 parent 7e3b690 commit 41ab9a5
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions controller/replica_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -376,18 +376,13 @@ func (rc *ReplicaController) CreateInstance(obj interface{}) (*longhorn.Instance
return nil, err
}

exposeRequired := true
if v.Spec.NodeID == rc.controllerID {
exposeRequired = false
}

return c.ReplicaInstanceCreate(&engineapi.ReplicaInstanceCreateRequest{
Replica: r,
DiskName: diskName,
DataPath: dataPath,
BackingImagePath: backingImagePath,
DataLocality: v.Spec.DataLocality,
ExposeRequired: exposeRequired,
ExposeRequired: true,
ImIP: im.Status.IP,
EngineCLIAPIVersion: cliAPIVersion,
})
Expand Down

0 comments on commit 41ab9a5

Please sign in to comment.