Skip to content

Commit

Permalink
Merge pull request #324 from jsullivan-CS/be-main
Browse files Browse the repository at this point in the history
Adding backend support in Node/DaemonSet
  • Loading branch information
redhatrises authored Dec 8, 2022
2 parents acd9130 + 155a6ef commit 1ed2468
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 0 deletions.
5 changes: 5 additions & 0 deletions apis/falcon/v1alpha1/falconnodesensor_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,11 @@ type FalconNodeSensorConfig struct {
// +kubebuilder:default=false
// +operator-sdk:csv:customresourcedefinitions:type=spec,order=7
NodeCleanup *bool `json:"disableCleanup,omitempty"`
// Sets the backend to be used by the DaemonSet Sensor.
// +kubebuilder:default=kernel
// +kubebuilder:validation:Enum=kernel;bpf
// +operator-sdk-csv:customresourcedefinitions:type=spec,order=8
Backend string `json:"backend,omitempty"`

// Version of the sensor to be installed. The latest version will be selected when this version specifier is missing.
Version *string `json:"version,omitempty"`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,13 @@ spec:
node:
description: Various configuration for DaemonSet Deployment
properties:
backend:
default: kernel
description: Sets the backend to be used by the DaemonSet Sensor.
enum:
- kernel
- bpf
type: string
disableCleanup:
default: false
description: Disables the cleanup of the sensor through DaemonSet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,13 @@ spec:
node:
description: Various configuration for DaemonSet Deployment
properties:
backend:
default: kernel
description: Sets the backend to be used by the DaemonSet Sensor.
enum:
- kernel
- bpf
type: string
disableCleanup:
default: false
description: Disables the cleanup of the sensor through DaemonSet
Expand Down
7 changes: 7 additions & 0 deletions deploy/falcon-operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2053,6 +2053,13 @@ spec:
node:
description: Various configuration for DaemonSet Deployment
properties:
backend:
default: kernel
description: Sets the backend to be used by the DaemonSet Sensor.
enum:
- kernel
- bpf
type: string
disableCleanup:
default: false
description: Disables the cleanup of the sensor through DaemonSet
Expand Down
3 changes: 3 additions & 0 deletions pkg/node/config_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ func (cc *ConfigCache) SensorEnvVars() map[string]string {
if cc.cid != "" {
sensorConfig["FALCONCTL_OPT_CID"] = cc.cid
}
if cc.nodesensor.Spec.Node.Backend != "" {
sensorConfig["FALCONCTL_OPT_BACKEND"] = cc.nodesensor.Spec.Node.Backend
}
return sensorConfig
}

Expand Down

0 comments on commit 1ed2468

Please sign in to comment.