models

package
v1.63.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2025 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Assistant

type Assistant struct {

	/* 云助手版本 (Optional) */
	Version string `json:"version"`

	/* 云助手运行状态 (Optional) */
	Status string `json:"status"`

	/* 云主机的操作系统类型 (Optional) */
	OsType string `json:"osType"`

	/* 云主机的操作系统版本 (Optional) */
	OsVersion string `json:"osVersion"`

	/* 云主机Id (Optional) */
	InstanceId string `json:"instanceId"`

	/* 最近一次心跳时间 (Optional) */
	LastHeartBeat string `json:"lastHeartBeat"`
}

type Command

type Command struct {

	/* 命令Id
	(Optional) */
	CommandId string `json:"commandId"`

	/* 命令名称,长度为1\~128个字符,只允许中文、数字、大小写字母、英文下划线(\_)、连字符(-)及点(.)。
	(Optional) */
	CommandName string `json:"commandName"`

	/* 命令类型,可选值:shell和powershell,默认shell
	(Optional) */
	CommandType string `json:"commandType"`

	/* 以base64编码的命令内容,编码后长度小于16KB
	(Optional) */
	CommandContent string `json:"commandContent"`

	/* 超时时间,取值范围:[10, 86400], 超过该时间后,尚未执行完的命令会置为失败。默认60s
	(Optional) */
	Timeout int `json:"timeout"`

	/* 用户名,执行该命令时的用户身份。在linux上默认是root,windows上默认是administrator。长度小于256。
	(Optional) */
	Username string `json:"username"`

	/* 命令执行路径。在linux上默认是/root,windows上默认是C:\Windows\System32。长度小于256。
	(Optional) */
	Workdir string `json:"workdir"`

	/* 命令描述,描述该命令详细信息,如功能、使用注意事项等。长度小于256。
	(Optional) */
	CommandDescription string `json:"commandDescription"`

	/* 是否使用参数, 默认false,不使用参数 (Optional) */
	EnableParameter bool `json:"enableParameter"`

	/* 脚本中用户自定义的参数,最多20个。 (Optional) */
	Parameters []Parameter `json:"parameters"`

	/* 命令创建时间 (Optional) */
	CreateTime string `json:"createTime"`

	/* 命令更新时间 (Optional) */
	UpdateTime string `json:"updateTime"`
}

type Invocation

type Invocation struct {

	/* 命令执行状态,取值为:[`waiting`,`pending`,`running`,`stopping`,`failed`,`partial_failed`,`stopped`,`finish`] (Optional) */
	Status string `json:"status"`

	/* 命令Id (Optional) */
	CommandId string `json:"commandId"`

	/* 命令名称 (Optional) */
	CommandName string `json:"commandName"`

	/* 命令来源,[`jdcloud`:公共命令, `self`:私有命令] (Optional) */
	SourceType string `json:"sourceType"`

	/* 命令内容调用Id (Optional) */
	InvokeId string `json:"invokeId"`

	/* 请求执行命令的云主机Id (Optional) */
	Instances []string `json:"instances"`

	/* 请求执行命令的云主机标签 (Optional) */
	Tags []common.TagFilter `json:"tags"`

	/* 执行命令的云主机 (Optional) */
	InvokeInstances []string `json:"invokeInstances"`

	/* 命令类型 (Optional) */
	CommandType string `json:"commandType"`

	/* 命令内容,base64编码 (Optional) */
	CommandContent string `json:"commandContent"`

	/* 命令描述 (Optional) */
	CommandDescription string `json:"commandDescription"`

	/* 每个云主机的执行详情 (Optional) */
	InvocationInstances []InvocationInstance `json:"invocationInstances"`

	/* 命令参数 (Optional) */
	Parameters string `json:"parameters"`

	/* 命令超时时间 (Optional) */
	Timeout string `json:"timeout"`

	/* 用户名 (Optional) */
	Username string `json:"username"`

	/* 命令执行路径 (Optional) */
	Workdir string `json:"workdir"`

	/* 命令调用的错误信息 (Optional) */
	ErrorInfo string `json:"errorInfo"`

	/* 该次命令调用的开始时间 (Optional) */
	CreateTime string `json:"createTime"`

	/* 该次命令配置的定时执行时间 (Optional) */
	ExecTime string `json:"execTime"`
}

type InvocationInstance

type InvocationInstance struct {

	/* 云主机Id (Optional) */
	InstanceId string `json:"instanceId"`

	/* 云主机名字 (Optional) */
	InstanceName string `json:"instanceName"`

	/* 单个云主机命令执行状态, 取值为:[pending,running,stopping,aborted,invalid,timeout,terminated,cancel,error,failed,finish] (Optional) */
	Status string `json:"status"`

	/* 命令执行退出码 (Optional) */
	ExitCode string `json:"exitCode"`

	/* 命令执行错误原因 (Optional) */
	ErrorInfo string `json:"errorInfo"`

	/* 命令执行的开始时间 (Optional) */
	StartTime string `json:"startTime"`

	/* 命令执行的结束时间 (Optional) */
	EndTime string `json:"endTime"`

	/* 命令执行的输出内容,长度小于6000B,超出6000的取前面5000B和最后1000B拼接在一起。 (Optional) */
	Output string `json:"output"`

	/* 第几次执行该命令 (Optional) */
	InvokeTimes string `json:"invokeTimes"`

	/* 该命令对应的任务创建时间 (Optional) */
	CreateTime string `json:"createTime"`

	/* 该命令对应的任务更新时间 (Optional) */
	UpdateTime string `json:"updateTime"`
}

type Parameter

type Parameter struct {

	/* 参数名称, 长度小于64 (Optional) */
	Key *string `json:"key"`

	/* 参数值,长度小于64 (Optional) */
	Value *string `json:"value"`
}

Jump to

Keyboard shortcuts

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