models

package
v1.7.5 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

type Application struct {
	ID          ID                 `json:"id"`
	Name        string             `json:"name"`
	Description string             `json:"description"`
	Href        string             `json:"href"`
	IconName    string             `json:"icon" gorm:"column:icon"`
	UseProjects bool               `json:"use_projects"`
	IsInBeta    bool               `json:"is_in_beta"`
	IsDisabled  bool               `json:"is_disabled"`
	Config      *ApplicationConfig `json:"config"`
}

type ApplicationConfig added in v1.4.10

type ApplicationConfig struct {
	Sections []ApplicationSection `json:"sections"`
}

func (*ApplicationConfig) Scan added in v1.4.10

func (c *ApplicationConfig) Scan(value interface{}) error

func (ApplicationConfig) Value added in v1.4.10

func (c ApplicationConfig) Value() (driver.Value, error)

type ApplicationSection added in v1.4.10

type ApplicationSection struct {
	Name string `json:"name"`
	Href string `json:"href"`
}

func (*ApplicationSection) Scan added in v1.4.10

func (c *ApplicationSection) Scan(value interface{}) error

func (ApplicationSection) Value added in v1.4.10

func (c ApplicationSection) Value() (driver.Value, error)

type CreatedUpdated

type CreatedUpdated struct {
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

type ID added in v1.7.5

type ID int

func ParseID added in v1.7.5

func ParseID(id string) (ID, error)

func (ID) String added in v1.7.5

func (id ID) String() string

type Label

type Label struct {
	Key   string `json:"key"`
	Value string `json:"value"`
}

type Labels

type Labels []Label

func (*Labels) Scan

func (labels *Labels) Scan(value interface{}) error

func (Labels) Value

func (labels Labels) Value() (driver.Value, error)

type Project

type Project struct {
	ID   ID     `json:"id"`
	Name string `json:"name" validate:"required,min=3,max=50,subdomain_rfc1123"`
	// nolint:lll // Next line is 121 characters (lll)
	MLFlowTrackingURL string         `json:"mlflow_tracking_url" gorm:"column:mlflow_tracking_url" validate:"omitempty,url"`
	Administrators    pq.StringArray `json:"administrators" gorm:"column:administrators;type:varchar(256)[]"`
	Readers           pq.StringArray `json:"readers" gorm:"column:readers;type:varchar(256)[]"`
	Team              string         `json:"team" validate:"required,min=1,max=64"`
	Stream            string         `json:"stream" validate:"required,min=1,max=64"`
	Labels            Labels         `json:"labels,omitempty" gorm:"column:labels"`
	CreatedUpdated
}

type Secret

type Secret struct {
	ID        ID     `json:"id"`
	ProjectID ID     `json:"project_id"`
	Name      string `json:"name"`
	Data      string `json:"data"`
	CreatedUpdated
}

func (*Secret) CopyValueFrom

func (s *Secret) CopyValueFrom(secret *Secret)

func (*Secret) DecryptData

func (s *Secret) DecryptData(passphrase string) (*Secret, error)

func (*Secret) EncryptData

func (s *Secret) EncryptData(passphrase string) (*Secret, error)

func (*Secret) IsValidForInsertion

func (s *Secret) IsValidForInsertion() bool

func (*Secret) IsValidForMutation

func (s *Secret) IsValidForMutation() bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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