Skip to content

Commit

Permalink
hypervisor/rpcd: add ChangeVmVolumeInterfaces SRPC method.
Browse files Browse the repository at this point in the history
  • Loading branch information
rgooch committed Sep 24, 2024
1 parent b094a39 commit 742f074
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
1 change: 1 addition & 0 deletions hypervisor/rpcd/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ func Setup(manager *manager.Manager, dhcpServer DhcpServer,
"ChangeVmOwnerUsers",
"ChangeVmSize",
"ChangeVmTags",
"ChangeVmVolumeInterfaces",
"ChangeVmVolumeSize",
"CommitImportedVm",
"ConnectToVmConsole",
Expand Down
17 changes: 17 additions & 0 deletions hypervisor/rpcd/changeVmVolumeInterfaces.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package rpcd

import (
"github.com/Cloud-Foundations/Dominator/lib/errors"
"github.com/Cloud-Foundations/Dominator/lib/srpc"
"github.com/Cloud-Foundations/Dominator/proto/hypervisor"
)

func (t *srpcType) ChangeVmVolumeInterfaces(conn *srpc.Conn,
request hypervisor.ChangeVmVolumeInterfacesRequest,
reply *hypervisor.ChangeVmVolumeInterfacesResponse) error {
*reply = hypervisor.ChangeVmVolumeInterfacesResponse{
errors.ErrorToString(
t.manager.ChangeVmVolumeInterfaces(request.IpAddress,
conn.GetAuthInformation(), request.Interfaces))}
return nil
}

0 comments on commit 742f074

Please sign in to comment.