rpc

package
v0.0.0-...-5a1019b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Copyright © 2022 Platform9, Inc.

Copyright © 2022 Platform9, Inc.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect(port string) (*rpc.Client, error)

func Register

func Register(data interface{})

func Start

func Start(port string) error

Types

type Conn

type Conn interface {
	GetLocalAddress() string
	Open() error
	UploadFile(local string, dest string, mode os.FileMode) error
	RunCommand(cmd string) ([]byte, []byte, error)
}

type RemoteRPCServer

type RemoteRPCServer struct {
	// contains filtered or unexported fields
}

func NewRemoteRPC

func NewRemoteRPC(conn Conn) (*RemoteRPCServer, error)

func SshRemoteRPC

func SshRemoteRPC(server, user, sshKey string) (*RemoteRPCServer, error)

func (*RemoteRPCServer) GetAddress

func (rc *RemoteRPCServer) GetAddress() string

GetAddress returns the address to connect o

func (*RemoteRPCServer) Start

func (rc *RemoteRPCServer) Start() error

func (*RemoteRPCServer) Stop

func (rc *RemoteRPCServer) Stop() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL