Documentation ¶
Index ¶
- func GenerateUserPrincipal(serverUUID, userUUID string) string
- func RenderKnownHostsRow(s ext.Server) string
- func RenderSSHConfigEntry(project iam.Project, s ext.Server, user auth.User) string
- type Session
- func (s *Session) Close() error
- func (s *Session) RefreshClientCertificates() error
- func (s *Session) RenderBashRCToFile() error
- func (s *Session) RenderKnownHostsToFile() error
- func (s *Session) RenderSSHConfigToFile() error
- func (s *Session) Start() error
- func (s *Session) StartSSHAgent() error
- func (s *Session) StartShell() error
- func (s *Session) SyncServersFromVault() error
- type VaultAuthReader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateUserPrincipal ¶
func RenderKnownHostsRow ¶
Types ¶
type Session ¶
type Session struct { UUID string PermanentCache model.Cache CachePath string User auth.User ServerList *model.ServerList ServerFilter model.ServerFilter VaultAuthReader VaultAuthReader SSHAgent agent.Agent SSHAgentSocketPath string SSHConfigFile *os.File KnownHostsFile *os.File BashRCFile *os.File // contains filtered or unexported fields }
func New ¶
func New(vaultService vault.VaultService, serverFilter model.ServerFilter, cacheFilePath string, cacheTTL time.Duration) (*Session, error)
func (*Session) RefreshClientCertificates ¶
func (*Session) RenderBashRCToFile ¶
func (*Session) RenderKnownHostsToFile ¶
func (*Session) RenderSSHConfigToFile ¶
func (*Session) StartSSHAgent ¶
func (*Session) StartShell ¶
func (*Session) SyncServersFromVault ¶
type VaultAuthReader ¶
type VaultAuthReader interface { // GetUser returns user which credentials are recognized by vault GetUser() (*auth.User, error) // UpdateServersByFilter returns ServerList synchronized with vault, according filter, using given ServerList as cache UpdateServersByFilter(model.ServerFilter, *model.ServerList) (*model.ServerList, error) // UpdateTenants update oldTenants by vault requests, according specified identifiers given by args UpdateTenants(map[iam.TenantUUID]iam.Tenant, model.StringSet) (map[iam.TenantUUID]iam.Tenant, error) // UpdateProjects update oldProjects by vault requests, according specified identifiers given by args UpdateProjects(map[iam.ProjectUUID]iam.Project, map[iam.TenantUUID]iam.Tenant, model.StringSet) (map[iam.TenantUUID]iam.Tenant, map[iam.ProjectUUID]iam.Project, error) }
Click to show internal directories.
Click to hide internal directories.