cloudx

package
v0.0.364 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 25, 2022 License: Apache-2.0 Imports: 43 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PortFlag               = "port"
	OpenFlag               = "open"
	WithoutJWTFlag         = "no-jwt"
	CookieDomainFlag       = "cookie-domain"
	DefaultRedirectURLFlag = "default-redirect-url"
	ServiceURL             = "sdk-url"
)
View Source
const (
	FormatKratosConfig = "kratos-config"
)
View Source
const PasswordReader = "password_reader"

Variables

View Source
var ErrNoConfig = errors.New("no ory configuration file present")
View Source
var ErrNoConfigQuiet = errors.New("please run `ory auth` to initialize your configuration or remove the `--quiet` flag")

Functions

func NewAuthCmd

func NewAuthCmd() *cobra.Command

func NewAuthLogoutCmd

func NewAuthLogoutCmd() *cobra.Command

func NewCloudHTTPClient

func NewCloudHTTPClient(token string) *http.Client

func NewCreateCmd

func NewCreateCmd() *cobra.Command

func NewCreateProjectCmd

func NewCreateProjectCmd() *cobra.Command

func NewGetCmd

func NewGetCmd() *cobra.Command

func NewGetKratosConfigCmd added in v0.0.362

func NewGetKratosConfigCmd() *cobra.Command

func NewGetProjectCmd

func NewGetProjectCmd() *cobra.Command

func NewListCmd

func NewListCmd() *cobra.Command

func NewListProjectsCmd

func NewListProjectsCmd() *cobra.Command

func NewPatchCmd

func NewPatchCmd() *cobra.Command

func NewPatchKratosConfigCmd added in v0.0.362

func NewPatchKratosConfigCmd() *cobra.Command

func NewProjectsPatchCmd

func NewProjectsPatchCmd() *cobra.Command

func NewProjectsUpdateCmd

func NewProjectsUpdateCmd() *cobra.Command

func NewProxyCommand

func NewProxyCommand(self string, version string) *cobra.Command

func NewRootCommand

func NewRootCommand(project string, version string) *cobra.Command

func NewTunnelCommand

func NewTunnelCommand(self string, version string) *cobra.Command

func NewUpdateCmd

func NewUpdateCmd() *cobra.Command

func NewUpdateIdentityConfigCmd added in v0.0.362

func NewUpdateIdentityConfigCmd() *cobra.Command

func PrintOpenAPIError

func PrintOpenAPIError(cmd *cobra.Command, err error) error

func ReadConfigFile

func ReadConfigFile(source string) (json.RawMessage, error)

func ReadConfigFiles

func ReadConfigFiles(files []string) ([]json.RawMessage, error)

func RegisterConfigFlag

func RegisterConfigFlag(f *pflag.FlagSet)

func RegisterYesFlag

func RegisterYesFlag(f *pflag.FlagSet)

Types

type AuthContext

type AuthContext struct {
	Version         string       `json:"version"`
	SessionToken    string       `json:"session_token"`
	SelectedProject uuid.UUID    `json:"selected_project"`
	IdentityTraits  AuthIdentity `json:"session_identity_traits"`
}

func (*AuthContext) Columns

func (i *AuthContext) Columns() []string

func (*AuthContext) Header

func (*AuthContext) Header() []string

func (*AuthContext) ID

func (i *AuthContext) ID() string

func (*AuthContext) Interface

func (i *AuthContext) Interface() interface{}

type AuthIdentity

type AuthIdentity struct {
	ID    uuid.UUID
	Email string `json:"email"`
}

type AuthProject

type AuthProject struct {
	ID   uuid.UUID `json:"id"`
	Slug string    `json:"slug"`
}

type SnakeCharmer

type SnakeCharmer struct {
	// contains filtered or unexported fields
}

func NewSnakeCharmer

func NewSnakeCharmer(cmd *cobra.Command) (*SnakeCharmer, error)

NewSnakeCharmer creates a new SnakeCharmer instance which handles cobra CLI commands.

func (*SnakeCharmer) Authenticate

func (h *SnakeCharmer) Authenticate() (*AuthContext, error)

func (*SnakeCharmer) CreateProject

func (h *SnakeCharmer) CreateProject(name string) (*cloud.Project, error)

func (*SnakeCharmer) EnsureContext

func (h *SnakeCharmer) EnsureContext() (*AuthContext, error)

func (*SnakeCharmer) GetProject

func (h *SnakeCharmer) GetProject(id string) (*cloud.Project, error)

func (*SnakeCharmer) ListProjects

func (h *SnakeCharmer) ListProjects() ([]cloud.Project, error)

func (*SnakeCharmer) PatchProject

func (h *SnakeCharmer) PatchProject(id string, raw []json.RawMessage, add, replace, del []string) (*cloud.SuccessfulProjectUpdate, error)

func (*SnakeCharmer) PrintUpdateProjectWarnings added in v0.0.362

func (h *SnakeCharmer) PrintUpdateProjectWarnings(p *client.SuccessfulProjectUpdate) error

func (*SnakeCharmer) SetDefaultProject

func (h *SnakeCharmer) SetDefaultProject(id string) error

func (*SnakeCharmer) SignOut

func (h *SnakeCharmer) SignOut() error

func (*SnakeCharmer) Stdin

func (h *SnakeCharmer) Stdin() *bufio.Reader

func (*SnakeCharmer) UpdateProject

func (h *SnakeCharmer) UpdateProject(id string, name string, configs []json.RawMessage) (*cloud.SuccessfulProjectUpdate, error)

func (*SnakeCharmer) WriteConfig

func (h *SnakeCharmer) WriteConfig(c *AuthContext) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL