Documentation
¶
Index ¶
Constants ¶
View Source
const ( ResponseStatusOk = "ok" ResponseStatusError = "error" )
View Source
const TTContainer = "container"
Variables ¶
View Source
var (
ErrUnknownMessage = errors.New("unknown command type")
)
Message errors
Functions ¶
Types ¶
type Message ¶
type Message interface {
GetName() MessageName
}
Message represents the message interface
type MessageName ¶
type MessageName string
MessageName is a message ID type
const ( StartMonitorName MessageName = "cmd.monitor.start" StopMonitorName MessageName = "cmd.monitor.stop" ShutdownSensorName MessageName = "cmd.sensor.shutdown" )
Supported messages
type Response ¶
type Response struct {
Status string `json:"status"`
}
Response contains the command response status information
type ShutdownSensor ¶
type ShutdownSensor struct{}
ShutdownSensor contains the 'shutdown sensor' command fields
func (*ShutdownSensor) GetName ¶
func (m *ShutdownSensor) GetName() MessageName
GetName returns the command message ID for the 'shutdown sensor' command
type StartMonitor ¶
type StartMonitor struct {
TargetType string `json:"target_type"`
TargetID string `json:"target_id"`
ImageID string `json:"image_id"`
ObfuscateMetadata bool `json:"obfuscate_metadata"`
ObfuscateAppPackageNames string `json:"obfuscate_apn"`
RTASourcePT bool `json:"rta_source_ptrace"`
AppName string `json:"app_name"`
AppArgs []string `json:"app_args,omitempty"`
AppEntrypoint []string `json:"app_entrypoint,omitempty"`
AppCmd []string `json:"app_cmd,omitempty"`
AppUser string `json:"app_user,omitempty"`
AppStdoutToFile bool `json:"app_stdout_to_file"`
AppStderrToFile bool `json:"app_stderr_to_file"`
RunTargetAsUser bool `json:"run_tas_user,omitempty"`
ReportOnMainPidExit bool `json:"report_on_main_pid_exit"`
KeepPerms bool `json:"keep_perms,omitempty"`
Perms map[string]*fsutil.AccessInfo `json:"perms,omitempty"`
Excludes []string `json:"excludes,omitempty"`
ExcludeVarLockFiles bool `json:"exclude_varlock_files,omitempty"`
Preserves map[string]*fsutil.AccessInfo `json:"preserves,omitempty"`
Includes map[string]*fsutil.AccessInfo `json:"includes,omitempty"`
IncludeBins []string `json:"include_bins,omitempty"`
IncludeDirBinsList map[string]*fsutil.AccessInfo `json:"include_dir_bins_list,omitempty"`
IncludeExes []string `json:"include_exes,omitempty"`
IncludeShell bool `json:"include_shell,omitempty"`
IncludeHealthcheck []string `json:"include_healthcheck,omitempty"`
IncludeDistroInfo bool `json:"include_distro_info,omitempty"`
IncludeWorkdir string `json:"include_workdir,omitempty"`
IncludeCertAll bool `json:"include_cert_all,omitempty"`
IncludeCertBundles bool `json:"include_cert_bundles,omitempty"`
IncludeCertDirs bool `json:"include_cert_dirs,omitempty"`
IncludeCertPKAll bool `json:"include_cert_pk_all,omitempty"`
IncludeCertPKDirs bool `json:"include_cert_pk_dirs,omitempty"`
IncludeNew bool `json:"include_new,omitempty"`
IncludeSSHClient bool `json:"include_ssh_client,omitempty"`
IncludeOSLibsNet bool `json:"include_oslibs_net,omitempty"`
IncludeZoneInfo bool `json:"include_zoneinfo,omitempty"`
IncludeAppNuxtDir bool `json:"include_app_nuxt_dir,omitempty"`
IncludeAppNuxtBuildDir bool `json:"include_app_nuxt_build,omitempty"`
IncludeAppNuxtDistDir bool `json:"include_app_nuxt_dist,omitempty"`
IncludeAppNuxtStaticDir bool `json:"include_app_nuxt_static,omitempty"`
IncludeAppNuxtNodeModulesDir bool `json:"include_app_nuxt_nm,omitempty"`
IncludeAppNextDir bool `json:"include_app_next_dir,omitempty"`
IncludeAppNextBuildDir bool `json:"include_app_next_build,omitempty"`
IncludeAppNextDistDir bool `json:"include_app_next_dist,omitempty"`
IncludeAppNextStaticDir bool `json:"include_app_next_static,omitempty"`
IncludeAppNextNodeModulesDir bool `json:"include_app_next_nm,omitempty"`
IncludeNodePackages []string `json:"include_node_packages,omitempty"`
}
StartMonitor contains the start monitor command fields
func (*StartMonitor) GetName ¶
func (m *StartMonitor) GetName() MessageName
GetName returns the command message ID for the start monitor command
type StopMonitor ¶
type StopMonitor struct {
}
StopMonitor contains the stop monitor command fields
func (*StopMonitor) GetName ¶
func (m *StopMonitor) GetName() MessageName
GetName returns the command message ID for the stop monitor command
Click to show internal directories.
Click to hide internal directories.