Documentation
¶
Overview ¶
Package auth: Auth controller
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AuthFileProvider ¶
type AuthFileProvider struct {
// contains filtered or unexported fields
}
AuthFileProvider: Implementation of IAuthProvider using files in the ".auth" subdirectory
func NewAuthFileProvider ¶
func NewAuthFileProvider(profile def.ConfProfile) *AuthFileProvider
NewAuthFileProvider: Constructor of AuthFileProvider @param: profile: Definition of profile
func (*AuthFileProvider) GetProfile ¶
GetProfile: Implementation of IAuthProvider.GetProfile @param: cloudType: Type of the cloud @return: Profile that can be accessed as Viper @return: Error
func (*AuthFileProvider) GetProfilePathname ¶
func (p *AuthFileProvider) GetProfilePathname(cloudType def.CloudType) (string, error)
GetProfilePathname: Implement of IAuthProvider.GetProfilePathname @param: cloudType: Type of the cloud @return: Pathname of profile @return: Error
type IAuthProvider ¶
type IAuthProvider interface {
// GetProfile: Get profile for the cloud to connect to
// @param: cloudType: Type of the cloud
// @return: Profile that can be accessed as Viper
// @return: Error
GetProfile(cloudType def.CloudType) (*viper.Viper, error)
// GetProfilePathname:
// Get pathname of profile for the cloud connector that needs to read it directly
// @param: cloudType: Type of the cloud
// @return: Pathname of profile
// @return: Error
GetProfilePathname(cloudType def.CloudType) (string, error)
}
IAuthProvider: Interface that provides different management of the profile of Auth
type ProfileNotDefinedError ¶
type ProfileNotDefinedError struct {
// contains filtered or unexported fields
}
ProfileNotDefinedError: Error of profile not defined It may be acceptable to use one conf file in different projects with different cloud environments
func (ProfileNotDefinedError) Error ¶
func (e ProfileNotDefinedError) Error() string
Error: Output error string @return: Error string