auth

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	ActiveDomain string    `yaml:"active-domain"`
	Domains      []*Domain `yaml:"domains"`
}

func ReadConfig

func ReadConfig() (*Config, error)

func (*Config) Domain

func (config *Config) Domain(hostname string) *Domain

func (*Config) SetDomain

func (config *Config) SetDomain(hostname, token string)

func (*Config) Write

func (config *Config) Write() error

type Domain

type Domain struct {
	Hostname    string    `yaml:"hostname"`
	Token       string    `yaml:"token"`
	LastUpdated time.Time `yaml:"last_updated"`
}

func (*Domain) IsLocal

func (domain *Domain) IsLocal() (bool, error)

Jump to

Keyboard shortcuts

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