Documentation
¶
Overview ¶
Code generated by MockGen. DO NOT EDIT. Source: github.com/rancher-sandbox/cluster-api-provider-elemental/internal/agent/host (interfaces: InstallerSelector,Installer)
Generated by this command:
mockgen -copyright_file=hack/boilerplate.go.txt -destination=internal/agent/host/installer_mocks.go -package=host github.com/rancher-sandbox/cluster-api-provider-elemental/internal/agent/host InstallerSelector,Installer
Package host is a generated GoMock package.
Index ¶
Constants ¶
const (
IdentityFile = "private.key"
)
Variables ¶
var ( ErrManagedOSNotSupportedYet = errors.New("managed Elemental OS not supported yet") ErrUnmanagedOSNotReset = errors.New("unmanaged OS reset sentinel file still exists") ErrUnknownInstaller = errors.New("unknown installer") )
var ErrIdentityDoesNotExist = errors.New("no identity found")
Functions ¶
This section is empty.
Types ¶
type DummyIdentity ¶
type DummyIdentity struct {
// contains filtered or unexported fields
}
func NewDummyIdentity ¶
func NewDummyIdentity() (*DummyIdentity, error)
func (*DummyIdentity) GetSigningKey ¶
func (i *DummyIdentity) GetSigningKey() ([]byte, error)
func (*DummyIdentity) LoadFromFile ¶
func (i *DummyIdentity) LoadFromFile(fs vfs.FS, filePath string) error
func (*DummyIdentity) WriteToFile ¶
func (i *DummyIdentity) WriteToFile(fs vfs.FS, filePath string) error
type DummyManager ¶
type DummyManager struct {
// contains filtered or unexported fields
}
func (*DummyManager) GetOrCreateIdentity ¶
func (m *DummyManager) GetOrCreateIdentity() (Identity, error)
type ElementalInstaller ¶
type ElementalInstaller struct {
// contains filtered or unexported fields
}
func (*ElementalInstaller) Install ¶
func (i *ElementalInstaller) Install(_ api.RegistrationResponse, _ string) error
func (*ElementalInstaller) Reset ¶
func (i *ElementalInstaller) Reset(_ api.RegistrationResponse) error
func (*ElementalInstaller) TriggerReset ¶
func (i *ElementalInstaller) TriggerReset() error
type IdentityManager ¶
func NewDummyManager ¶
func NewDummyManager(fs vfs.FS, workDir string) IdentityManager
type Installer ¶
type Installer interface { Install(conf api.RegistrationResponse, hostnameToSet string) error TriggerReset() error Reset(conf api.RegistrationResponse) error }
func NewElementalInstaller ¶
func NewElementalInstaller(fs vfs.FS) Installer
type InstallerSelector ¶ added in v0.0.2
type InstallerSelector interface {
GetInstaller(fs vfs.FS, configPath string, conf config.Config) (Installer, error)
}
func NewInstallerSelector ¶ added in v0.0.2
func NewInstallerSelector() InstallerSelector
type MockInstaller ¶ added in v0.0.2
type MockInstaller struct {
// contains filtered or unexported fields
}
MockInstaller is a mock of Installer interface.
func NewMockInstaller ¶ added in v0.0.2
func NewMockInstaller(ctrl *gomock.Controller) *MockInstaller
NewMockInstaller creates a new mock instance.
func (*MockInstaller) EXPECT ¶ added in v0.0.2
func (m *MockInstaller) EXPECT() *MockInstallerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockInstaller) Install ¶ added in v0.0.2
func (m *MockInstaller) Install(arg0 api.RegistrationResponse, arg1 string) error
Install mocks base method.
func (*MockInstaller) Reset ¶ added in v0.0.2
func (m *MockInstaller) Reset(arg0 api.RegistrationResponse) error
Reset mocks base method.
func (*MockInstaller) TriggerReset ¶ added in v0.0.2
func (m *MockInstaller) TriggerReset() error
TriggerReset mocks base method.
type MockInstallerMockRecorder ¶ added in v0.0.2
type MockInstallerMockRecorder struct {
// contains filtered or unexported fields
}
MockInstallerMockRecorder is the mock recorder for MockInstaller.
func (*MockInstallerMockRecorder) Install ¶ added in v0.0.2
func (mr *MockInstallerMockRecorder) Install(arg0, arg1 any) *gomock.Call
Install indicates an expected call of Install.
func (*MockInstallerMockRecorder) Reset ¶ added in v0.0.2
func (mr *MockInstallerMockRecorder) Reset(arg0 any) *gomock.Call
Reset indicates an expected call of Reset.
func (*MockInstallerMockRecorder) TriggerReset ¶ added in v0.0.2
func (mr *MockInstallerMockRecorder) TriggerReset() *gomock.Call
TriggerReset indicates an expected call of TriggerReset.
type MockInstallerSelector ¶ added in v0.0.2
type MockInstallerSelector struct {
// contains filtered or unexported fields
}
MockInstallerSelector is a mock of InstallerSelector interface.
func NewMockInstallerSelector ¶ added in v0.0.2
func NewMockInstallerSelector(ctrl *gomock.Controller) *MockInstallerSelector
NewMockInstallerSelector creates a new mock instance.
func (*MockInstallerSelector) EXPECT ¶ added in v0.0.2
func (m *MockInstallerSelector) EXPECT() *MockInstallerSelectorMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockInstallerSelector) GetInstaller ¶ added in v0.0.2
func (m *MockInstallerSelector) GetInstaller(arg0 vfs.FS, arg1 string, arg2 config.Config) (Installer, error)
GetInstaller mocks base method.
type MockInstallerSelectorMockRecorder ¶ added in v0.0.2
type MockInstallerSelectorMockRecorder struct {
// contains filtered or unexported fields
}
MockInstallerSelectorMockRecorder is the mock recorder for MockInstallerSelector.
func (*MockInstallerSelectorMockRecorder) GetInstaller ¶ added in v0.0.2
func (mr *MockInstallerSelectorMockRecorder) GetInstaller(arg0, arg1, arg2 any) *gomock.Call
GetInstaller indicates an expected call of GetInstaller.
type UnmanagedInstaller ¶
type UnmanagedInstaller struct {
// contains filtered or unexported fields
}
func (*UnmanagedInstaller) Install ¶
func (i *UnmanagedInstaller) Install(conf api.RegistrationResponse, hostnameToSet string) error
func (*UnmanagedInstaller) Reset ¶
func (i *UnmanagedInstaller) Reset(conf api.RegistrationResponse) error
func (*UnmanagedInstaller) TriggerReset ¶
func (i *UnmanagedInstaller) TriggerReset() error