Documentation
¶
Index ¶
Constants ¶
const (
// rshell commands belong to a namespace, currently only "rshell:" is supported.
RshellCommandNamespacePrefix = "rshell:"
)
Variables ¶
var BundleInheritedAllowedActions = []BundleInheritedAllowedAction{
{ActionFQN: "com.datadoghq.gitlab.users.testConnection", ExpectedPrefix: "com.datadoghq.gitlab"},
{ActionFQN: "com.datadoghq.kubernetes.core.testConnection", ExpectedPrefix: "com.datadoghq.kubernetes"},
{ActionFQN: "com.datadoghq.script.testConnection", ExpectedPrefix: "com.datadoghq.script"},
{ActionFQN: "com.datadoghq.script.enrichScript", ExpectedPrefix: "com.datadoghq.script"},
{ActionFQN: "com.datadoghq.http.testConnection", ExpectedPrefix: "com.datadoghq.http"},
{ActionFQN: "com.datadoghq.remoteaction.testConnection", ExpectedPrefix: "com.datadoghq.remoteaction"},
}
BundleInheritedAllowedActions is a list of actions that are automatically allowed if at least one other action matching their expected prefix is allowed
var DefaultActionFQNs = append([]string{}, defaultCommonActionFQNs...)
DefaultActionFQNs is a list of action FQNs that are enabled by default for non-Cluster-Agent flavors. Users can opt out by setting private_action_runner.default_actions_enabled to false.
var DefaultClusterAgentActionFQNs = append([]string{
"com.datadoghq.kubernetes.apps.listDeployment",
"com.datadoghq.kubernetes.apps.getDeployment",
"com.datadoghq.kubernetes.apps.getDaemonSet",
"com.datadoghq.kubernetes.apps.listDaemonSet",
"com.datadoghq.kubernetes.apps.getStatefulSet",
"com.datadoghq.kubernetes.apps.listStatefulSet",
"com.datadoghq.kubernetes.core.getPod",
"com.datadoghq.kubernetes.core.listPod",
"com.datadoghq.kubernetes.core.getConfigMap",
"com.datadoghq.kubernetes.core.listConfigMap",
"com.datadoghq.kubernetes.core.getService",
"com.datadoghq.kubernetes.core.listService",
"com.datadoghq.kubernetes.core.getNode",
"com.datadoghq.kubernetes.core.listNode",
"com.datadoghq.kubernetes.core.listEvent",
"com.datadoghq.kubernetes.core.listNamespace",
"com.datadoghq.kubernetes.batch.getJob",
"com.datadoghq.kubernetes.batch.listJob",
"com.datadoghq.kubernetes.batch.getCronJob",
"com.datadoghq.kubernetes.batch.listCronJob",
}, defaultCommonActionFQNs...)
DefaultClusterAgentActionFQNs is a list of action FQNs that are enabled by default when the agent runs as a Cluster Agent flavor. Users can opt out by setting private_action_runner.default_actions_enabled to false.
Functions ¶
Types ¶
type BundleInheritedAllowedAction ¶
BundleInheritedAllowedAction represents an action that is automatically allowed if at least one other action matching the expected prefix is allowed
type Config ¶
type Config struct {
ActionsAllowlist map[string]sets.Set[string] // map of allowed bundle IDs to a set of allowed action names
Allowlist []string
AllowIMDSEndpoint bool
RShellAllowedPaths []string
RShellAllowedCommands []string
DDHost string
DDApiHost string
Modes []modes.Mode
OrgId int64
PrivateKey *ecdsa.PrivateKey
RunnerId string
Urn string
Tags []observability.Tag
// RemoteConfig related fields
DatadogSite string
// the following are constants with default values. They are part of the config struct to allow for the ability to be overwritten in the YAML config file if needed
MaxBackoff time.Duration
MinBackoff time.Duration
MaxAttempts int32
WaitBeforeRetry time.Duration
LoopInterval time.Duration
OpmsRequestTimeout int32
RunnerPoolSize int32
HealthCheckInterval int32
HttpServerReadTimeout int32
HttpServerWriteTimeout int32
HTTPTimeout time.Duration
TaskTimeoutSeconds *int32
RunnerAccessTokenHeader string
RunnerAccessTokenIdHeader string
Port int32
JWTRefreshInterval time.Duration
HealthCheckEndpoint string
HeartbeatInterval time.Duration
EnableProfiling bool
DisableCredentialTemplates bool
Version string
OpmsExtraHeaders map[string]string
MetricsClient statsd.ClientInterface
}