Documentation ¶
Overview ¶
Copyright 2012-2016 Canonical Ltd. Licensed under the AGPLv3, see LICENCE file for details.
Index ¶
- func NewAddCommand() cmd.Command
- func NewChangePasswordCommand() cmd.Command
- func NewDisableCommand() cmd.Command
- func NewEnableCommand() cmd.Command
- func NewListCommand() cmd.Command
- func NewLoginCommand() cmd.Command
- func NewLogoutCommand() cmd.Command
- func NewRemoveCommand() cmd.Command
- func NewShowUserCommand() cmd.Command
- func NewWhoAmICommand() cmd.Command
- type AddUserAPI
- type ChangePasswordAPI
- type RemoveUserAPI
- type UserInfo
- type UserInfoAPI
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewAddCommand ¶
func NewDisableCommand ¶
func NewEnableCommand ¶
func NewListCommand ¶
func NewLoginCommand ¶
NewLoginCommand returns a new cmd.Command to handle "juju login".
func NewLogoutCommand ¶
NewLogoutCommand returns a new cmd.Command to handle "juju logout".
func NewRemoveCommand ¶
NewRemoveCommand constructs a wrapped unexported removeCommand.
func NewShowUserCommand ¶
func NewWhoAmICommand ¶
NewWhoAmICommand returns a command to print login details.
Types ¶
type AddUserAPI ¶
type AddUserAPI interface { AddUser(username, displayName, password string) (names.UserTag, []byte, error) Close() error }
AddUserAPI defines the usermanager API methods that the add command uses.
type ChangePasswordAPI ¶
type ChangePasswordAPI interface { SetPassword(username, password string) error ResetPassword(username string) ([]byte, error) BestAPIVersion() int Close() error }
ChangePasswordAPI defines the usermanager API methods that the change password command uses.
type RemoveUserAPI ¶
RemoveUserAPI defines the usermanager API methods that the remove command uses.
type UserInfo ¶
type UserInfo struct { Username string `yaml:"user-name" json:"user-name"` DisplayName string `yaml:"display-name,omitempty" json:"display-name,omitempty"` Access string `yaml:"access" json:"access"` DateCreated string `yaml:"date-created,omitempty" json:"date-created,omitempty"` LastConnection string `yaml:"last-connection,omitempty" json:"last-connection,omitempty"` Disabled bool `yaml:"disabled,omitempty" json:"disabled,omitempty"` }
UserInfo defines the serialization behaviour of the user information.
type UserInfoAPI ¶
type UserInfoAPI interface { UserInfo([]string, usermanager.IncludeDisabled) ([]params.UserInfo, error) Close() error }
UserInfoAPI defines the API methods that the info command uses.