persistentconfig

package
v1.5.3 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: MPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultConfigFolder        = ".pagerduty"
	DefaultConfigProfileTag    = "profile"
	DefaultConfigProfile       = "default"
	DefaultConfigFileName      = "config"
	DefaultCredentialsFileName = "credentials"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AppOauthScopedTokenParams

type AppOauthScopedTokenParams struct {
	ClientID     string
	ClientSecret string
	PDSubDomain  string
	Region       string
	Token        string // App Oauth Scoped Token
}

AppOauthScopedTokenParams parameters for setting up API calls authentication using App Scoped Oauth Token

type ClientPersistentConfig

type ClientPersistentConfig struct {
	AppOauthScopedTokenParams
	Profile string
	Fs      afero.Fs
	// contains filtered or unexported fields
}

func (ClientPersistentConfig) GetCredential

func (c ClientPersistentConfig) GetCredential(k string) (string, error)

func (*ClientPersistentConfig) Load

func (c *ClientPersistentConfig) Load() error

func (ClientPersistentConfig) ReadConfigFile

func (c ClientPersistentConfig) ReadConfigFile() (*ini.File, error)

func (ClientPersistentConfig) ReadCredentialsFile

func (c ClientPersistentConfig) ReadCredentialsFile() (*ini.File, error)

func (ClientPersistentConfig) SetActiveProfile

func (c ClientPersistentConfig) SetActiveProfile(profile string) error

func (*ClientPersistentConfig) SetCredential

func (c *ClientPersistentConfig) SetCredential(k, v string) error

func (ClientPersistentConfig) WriteConfigFile

func (c ClientPersistentConfig) WriteConfigFile(cfg *ini.File) error

func (ClientPersistentConfig) WriteCredentialsFile

func (c ClientPersistentConfig) WriteCredentialsFile(cfg *ini.File) error

Jump to

Keyboard shortcuts

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