Documentation
¶
Overview ¶
Package server is a matchbox library package for implementing servers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoMatchingGroup = errors.New("matchbox: No matching Group") ErrNoMatchingProfile = errors.New("matchbox: No matching Profile") )
Possible service errors
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server interface {
// SelectGroup returns the Group matching the given labels.
SelectGroup(context.Context, *pb.SelectGroupRequest) (*storagepb.Group, error)
// SelectProfile returns the Profile matching the given labels.
SelectProfile(context.Context, *pb.SelectProfileRequest) (*storagepb.Profile, error)
// Create or update a Group.
GroupPut(context.Context, *pb.GroupPutRequest) (*storagepb.Group, error)
// Get a machine Group by id.
GroupGet(context.Context, *pb.GroupGetRequest) (*storagepb.Group, error)
// Delete a machine Group by id.
GroupDelete(context.Context, *pb.GroupDeleteRequest) error
// List all machine Groups.
GroupList(context.Context, *pb.GroupListRequest) ([]*storagepb.Group, error)
// Create or update a Profile.
ProfilePut(context.Context, *pb.ProfilePutRequest) (*storagepb.Profile, error)
// Get a Profile by id.
ProfileGet(context.Context, *pb.ProfileGetRequest) (*storagepb.Profile, error)
// Delete a Profile by id.
ProfileDelete(context.Context, *pb.ProfileDeleteRequest) error
// List all Profiles.
ProfileList(context.Context, *pb.ProfileListRequest) ([]*storagepb.Profile, error)
// Create or update an Ignition template.
IgnitionPut(context.Context, *pb.IgnitionPutRequest) (string, error)
// Get an Ignition template by name.
IgnitionGet(context.Context, *pb.IgnitionGetRequest) (string, error)
// Delete an Ignition template by name.
IgnitionDelete(context.Context, *pb.IgnitionDeleteRequest) error
// Get a Cloud-Config template by name.
CloudGet(ctx context.Context, name string) (string, error)
// Get a generic template by name.
GenericGet(ctc context.Context, name string) (string, error)
}
Server defines the matchbox server interface.
Click to show internal directories.
Click to hide internal directories.