models

package
v0.0.0-...-6410feb Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CommandTypeSSH = "ssh"
)

Variables

This section is empty.

Functions

func InitCommandLog

func InitCommandLog()

func InitDB

func InitDB() error

Types

type CommandLogCreateInput

type CommandLogCreateInput struct {
	ObjId           string
	ObjName         string
	ObjType         string
	Action          string
	UserId          string
	User            string
	TenantId        string
	Tenant          string
	DomainId        string
	Domain          string
	ProjectDomainId string
	ProjectDomain   string
	Roles           string
	SessionId       string
	AccessedAt      time.Time
	Type            CommandType
	LoginUser       string
	StartTime       time.Time
	Ps1             string `json:"ps1"`
	Command         string
	Notes           jsonutils.JSONObject
}

type CommandType

type CommandType string

type SCommandLog

type SCommandLog struct {
	db.SOpsLog

	SessionId  string      `width:"128" charset:"ascii" list:"user"`
	AccessedAt time.Time   `nullable:"false" list:"user" create:"required"`
	Type       CommandType `width:"32" charset:"utf8" nullable:"true" list:"user" create:"required"`
	LoginUser  string      `charset:"utf8" list:"user" create:"required"`
	StartTime  time.Time   `list:"user" create:"required"`
	Ps1        string      `charset:"utf8" list:"user" create:"optional" json:"ps1"`
	Command    string      `charset:"utf8" list:"user" create:"required"`
}

type SCommandLogManager

type SCommandLogManager struct {
	db.SOpsLogManager
}

func GetCommandLogManager

func GetCommandLogManager() *SCommandLogManager

func (*SCommandLogManager) Create

func (*SCommandLogManager) ListItemFilter

Jump to

Keyboard shortcuts

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