|
| 1 | +--- |
| 2 | +title: TRACEE-ENRICHMENT |
| 3 | +section: 1 |
| 4 | +header: Tracee Enrichment Flag Manual |
| 5 | +date: 2025/12 |
| 6 | +... |
| 7 | + |
| 8 | +## NAME |
| 9 | + |
| 10 | +tracee **\-\-enrichment** - Configure enrichment for container events and other enrichment options |
| 11 | + |
| 12 | +## SYNOPSIS |
| 13 | + |
| 14 | +tracee **\-\-enrichment** [container|container.cgroupfs.path=*path*|container.cgroupfs.force|container.docker.socket=*socket_path*|container.containerd.socket=*socket_path*|container.crio.socket=*socket_path*|container.podman.socket=*socket_path*|resolve-fd|exec-hash|exec-hash.mode=*mode*|user-stack-trace] [**\-\-enrichment** ...] |
| 15 | + |
| 16 | +## DESCRIPTION |
| 17 | + |
| 18 | +The `--enrichment` flag allows you to configure enrichment options for container events and other enrichment features. |
| 19 | + |
| 20 | +### Flags |
| 21 | + |
| 22 | +- **container**: Enable container enrichment with default settings. When enabled, Tracee will enrich container events with container information. |
| 23 | + |
| 24 | +- **container.cgroupfs.path**=*path*: Enable container enrichment and configure the path to the cgroupfs where container cgroups are created. This is used as a hint for auto-detection. **Note**: Using this option automatically enables container, so you don't need to also specify `--enrichment container`. |
| 25 | + Example: |
| 26 | + ```console |
| 27 | + --enrichment container.cgroupfs.path=/sys/fs/cgroup |
| 28 | + ``` |
| 29 | + |
| 30 | +- **container.cgroupfs.force**: Force the usage of the provided mountpoint path, skipping auto-detection. **Note**: This option requires `container.cgroupfs.path` to be set. It cannot be used alone. |
| 31 | + Example: |
| 32 | + ```console |
| 33 | + --enrichment container.cgroupfs.path=/sys/fs/cgroup container.cgroupfs.force |
| 34 | + ``` |
| 35 | + |
| 36 | +- **container.docker.socket**=*socket_path*: Enable container enrichment and configure container runtime sockets for enrichment. Configure the path to the Docker socket. **Note**: Using this option automatically enables container, so you don't need to also specify `--enrichment container`. |
| 37 | + Example: |
| 38 | + ```console |
| 39 | + --enrichment container.docker.socket=/var/run/docker.sock |
| 40 | + ``` |
| 41 | + |
| 42 | +- **container.containerd.socket**=*socket_path*: Enable container enrichment and configure container runtime sockets for enrichment. Configure the path to the Containerd socket. **Note**: Using this option automatically enables container, so you don't need to also specify `--enrichment container`. |
| 43 | + Example: |
| 44 | + ```console |
| 45 | + --enrichment container.containerd.socket=/var/run/containerd/containerd.sock |
| 46 | + ``` |
| 47 | + |
| 48 | +- **container.crio.socket**=*socket_path*: Enable container enrichment and configure container runtime sockets for enrichment. Configure the path to the CRI-O socket. **Note**: Using this option automatically enables container, so you don't need to also specify `--enrichment container`. |
| 49 | + Example: |
| 50 | + ```console |
| 51 | + --enrichment container.crio.socket=/var/run/crio/crio.sock |
| 52 | + ``` |
| 53 | + |
| 54 | +- **container.podman.socket**=*socket_path*: Enable container enrichment and configure container runtime sockets for enrichment. Configure the path to the Podman socket. **Note**: Using this option automatically enables container, so you don't need to also specify `--enrichment container`. |
| 55 | + Example: |
| 56 | + ```console |
| 57 | + --enrichment container.podman.socket=/var/run/podman/podman.sock |
| 58 | + ``` |
| 59 | + |
| 60 | + Supported container runtimes for socket configuration: |
| 61 | + - CRI-O (`crio`, `cri-o`) |
| 62 | + - Containerd (`containerd`) |
| 63 | + - Docker (`docker`) |
| 64 | + - Podman (`podman`) |
| 65 | + |
| 66 | +- **resolve-fd** |
| 67 | + Enable resolve-fd. Presence of the flag enables it, absence disables it. |
| 68 | + Example: |
| 69 | + ```console |
| 70 | + --enrichment resolve-fd |
| 71 | + ``` |
| 72 | + |
| 73 | +- **exec-hash**: Enable exec-hash with default settings. When enabled, Tracee will compute hash values for executed binaries. |
| 74 | + |
| 75 | +- **exec-hash.mode**=*mode*: Enable exec-hash and configure the mode for exec-hash. **Note**: Using this option automatically enables exec-hash, so you don't need to also specify `--enrichment exec-hash`. |
| 76 | + Example: |
| 77 | + ```console |
| 78 | + --enrichment exec-hash.mode=sha256 |
| 79 | + ``` |
| 80 | + |
| 81 | +- **user-stack-trace** |
| 82 | + Enable user-stack-trace. Presence of the flag enables it, absence disables it. |
| 83 | + Example: |
| 84 | + ```console |
| 85 | + --enrichment user-stack-trace |
| 86 | + ``` |
| 87 | + |
| 88 | +## EXAMPLES |
| 89 | + |
| 90 | +1. Enable container enrichment: |
| 91 | + ```console |
| 92 | + --enrichment container |
| 93 | + ``` |
| 94 | + |
| 95 | +2. Configure Docker socket: |
| 96 | + ```console |
| 97 | + --enrichment container.docker.socket=/var/run/docker.sock |
| 98 | + ``` |
| 99 | + Note: `container.docker.socket` automatically enables container, so `--enrichment container` is not needed. |
| 100 | + |
| 101 | +3. Set the cgroupfs path: |
| 102 | + ```console |
| 103 | + --enrichment container.cgroupfs.path=/sys/fs/cgroup |
| 104 | + ``` |
| 105 | + Note: `container.cgroupfs.path` automatically enables container, so `--enrichment container` is not needed. |
| 106 | + |
| 107 | +4. Combine multiple flags: |
| 108 | + ```console |
| 109 | + --enrichment container.docker.socket=/var/run/docker.sock container.cgroupfs.path=/sys/fs/cgroup |
| 110 | + ``` |
| 111 | + Note: Since `container.docker.socket` and `container.cgroupfs.path` automatically enable container, you don't need `--enrichment container`. |
| 112 | + |
| 113 | +5. Enable resolve-fd and exec-hash: |
| 114 | + ```console |
| 115 | + --enrichment resolve-fd exec-hash |
| 116 | + ``` |
| 117 | + |
| 118 | +6. Enable exec-hash with custom mode: |
| 119 | + ```console |
| 120 | + --enrichment exec-hash.mode=sha256 |
| 121 | + ``` |
| 122 | + Note: `exec-hash.mode` automatically enables exec-hash, so `--enrichment exec-hash` is not needed. |
| 123 | + |
| 124 | +Please refer to the [documentation](../install/container-engines.md) for more information on container events enrichment. |
| 125 | + |
0 commit comments