You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: api/core/v1alpha2/cluster_virtual_image.go
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,7 @@ const (
32
32
//
33
33
// With this resource in the cluster, a container image is created and stored in a dedicated Deckhouse Virtualization Container Registry (DVCR).
34
34
//
35
+
// **Note:** The `metadata.name` field must comply with [Kubernetes object naming conventions](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/) and must not exceed 48 characters.
Copy file name to clipboardExpand all lines: api/core/v1alpha2/virtual_disk.go
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,9 @@ const (
29
29
30
30
// The VirtualDisk resource describes the desired virtual machine disk configuration. A VirtualDisk can be mounted statically in the virtual machine by specifying it in the `.spec.blockDeviceRefs` disk list, or mounted on-the-fly using the VirtualMachineBlockDeviceAttachments resource.
31
31
//
32
-
// Once a VirtualDisk is created, only the disk size field `.spec.persistentVolumeClaim.size` can be changed. All other fields are immutable.
32
+
// Once a VirtualDisk is created, the following fields in `.spec.persistentVolumeClaim` can be changed: `size` and `storageClassName`. All other fields are immutable.
33
+
//
34
+
// **Note:** The `metadata.name` field must comply with [Kubernetes object naming conventions](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/) and must not exceed 60 characters.
Copy file name to clipboardExpand all lines: api/core/v1alpha2/virtual_image.go
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -31,6 +31,8 @@ const (
31
31
// > This resource cannot be modified once it has been created.
32
32
//
33
33
// With this resource in the cluster, a container image is created and stored in a dedicated Deckhouse Virtualization Container Registry (DVCR) or PVC, with the data filled in from the source.
34
+
//
35
+
// **Note:** The `metadata.name` field must comply with [Kubernetes object naming conventions](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/) and must not exceed 49 characters.
Copy file name to clipboardExpand all lines: crds/doc-ru-virtualdisks.yaml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ spec:
6
6
description: |
7
7
Ресурс VirtualDisk описывает желаемую конфигурацию диска виртуальной машины. VirtualDisk можно смонтировать в виртуальной машине статически, указав его в списке дисков `.spec.blockDeviceRefs`, или «на лету» – с помощью ресурса VirtualMachineBlockDeviceAttachments.
8
8
9
-
После создания VirtualDisk можно изменить только размер диска с помощью поля `.spec.persistentVolumeClaim.size`. Все остальные поля изменить нельзя.
9
+
После создания VirtualDisk в `.spec.persistentVolumeClaim` можно изменить поля `size` и `storageClassName`. Все остальные поля неизменяемы.
10
10
11
11
**Важно:** Поле `metadata.name` должно соответствовать [правилам именования объектов Kubernetes](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/) и не должно превышать 60 символов.
Copy file name to clipboardExpand all lines: crds/virtualdisks.yaml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -57,7 +57,7 @@ spec:
57
57
description: |-
58
58
The VirtualDisk resource describes the desired virtual machine disk configuration. A VirtualDisk can be mounted statically in the virtual machine by specifying it in the `.spec.blockDeviceRefs` disk list, or mounted on-the-fly using the VirtualMachineBlockDeviceAttachments resource.
59
59
60
-
Once a VirtualDisk is created, only the disk size field `.spec.persistentVolumeClaim.size` can be changed. All other fields are immutable.
60
+
Once a VirtualDisk is created, the following fields in `.spec.persistentVolumeClaim` can be changed: `size` and `storageClassName`. All other fields are immutable.
61
61
62
62
**Note:** The `metadata.name` field must comply with [Kubernetes object naming conventions](https://kubernetes.io/docs/concepts/overview/working-with-objects/names/) and must not exceed 60 characters.
Copy file name to clipboardExpand all lines: docs/ADMIN_GUIDE.md
+52-13Lines changed: 52 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -194,26 +194,65 @@ Where:
194
194
Not available in CE edition.
195
195
{{< /alert >}}
196
196
197
-
{{< alert level="warning" >}}
198
-
To set up auditing, the following modules must be enabled:
197
+
To enable security event auditing:
199
198
200
-
- `log-shipper`,
201
-
- `runtime-audit-engine`.
202
-
{{< /alert >}}
199
+
1. Enable `log-shipper` and `runtime-audit-engine` modules.
200
+
1. Enable Kubernetes API audit by setting `.spec.settings.apiserver.auditPolicyEnabled: true` in the `control-plane-manager` module.
201
+
1. Set `.spec.settings.audit.enabled: true` in the `virtualization` module:
203
202
204
-
To enable security event auditing, set the module’s `.spec.settings.audit.enabled` parameter to `true`:
203
+
```yaml
204
+
spec:
205
+
settings:
206
+
audit:
207
+
enabled: true
208
+
```
209
+
210
+
For a complete list of configuration options, see [Configuration](./configuration.html).
211
+
212
+
Events are collected by the `virtualization-audit-*` pod in the `d8-virtualization` namespace. To forward events to the cluster logging system (e.g., Loki), create a ClusterLoggingConfig:
205
213
206
214
```yaml
215
+
apiVersion: deckhouse.io/v1alpha1
216
+
kind: ClusterLoggingConfig
217
+
metadata:
218
+
name: virtualization-audit-logs
207
219
spec:
208
-
enabled: true
209
-
settings:
210
-
audit:
211
-
enabled: true
220
+
destinationRefs:
221
+
- d8-loki
222
+
kubernetesPods:
223
+
namespaceSelector:
224
+
matchNames:
225
+
- d8-virtualization
226
+
labelSelector:
227
+
matchLabels:
228
+
app: virtualization-audit
229
+
type: KubernetesPods
212
230
```
213
231
214
-
{{< alert level="info" >}}
215
-
For a complete list of configuration options, see [Configuration](./configuration.html).
- `type`: Event type (Access to VM, VM Management, etc.).
240
+
- `name`: Human-readable description.
241
+
- `request_subject`: Username or ServiceAccount.
242
+
- `datetime`: Event timestamp.
243
+
- `virtualmachine_name`: Affected VM.
244
+
- `source_ip`: Request source IP (for forbidden operations).
245
+
246
+
### Security events
247
+
248
+
The audit system logs the following events:
249
+
250
+
- Access to VM: Connection via console, VNC, or port forward. Includes VM name, OS, versions, storage, and node address.
251
+
- VM Management: Create, update, patch, or delete operations on [VirtualMachine](/modules/virtualization/cr.html#virtualmachine) resources.
252
+
- VM Control Operations: Start, stop, restart, migrate, or evict via [VirtualMachineOperation](/modules/virtualization/cr.html#virtualmachineoperation) resource.
253
+
- Integrity Check: SHA256 verification of VM configuration. Logs when checksum changes.
254
+
- Module Control: Create, update, or delete operations on ModuleConfig.
255
+
- Forbidden Operations: Operations blocked by the platform. Includes user, operation, resource, source IP, and denial reason.
1. Установить `.spec.settings.audit.enabled: true` в модуле `virtualization`:
202
+
203
+
```yaml
204
+
spec:
205
+
settings:
206
+
audit:
207
+
enabled: true
208
+
```
209
+
210
+
Полный перечень параметров конфигурации приведён в разделе [Настройки](./configuration.html).
203
211
204
-
Чтобы включить аудит событий безопасности, установите параметр `.spec.settings.audit.enabled` настроек модуля в `true`:
212
+
События собираются подом `virtualization-audit-*` в пространстве имён `d8-virtualization`. Чтобы перенаправить события в систему логирования кластера (например, Loki), создайте ClusterLoggingConfig:
205
213
206
214
```yaml
215
+
apiVersion: deckhouse.io/v1alpha1
216
+
kind: ClusterLoggingConfig
217
+
metadata:
218
+
name: virtualization-audit-logs
207
219
spec:
208
-
enabled: true
209
-
settings:
210
-
audit:
211
-
enabled: true
220
+
destinationRefs:
221
+
- d8-loki
222
+
kubernetesPods:
223
+
namespaceSelector:
224
+
matchNames:
225
+
- d8-virtualization
226
+
labelSelector:
227
+
matchLabels:
228
+
app: virtualization-audit
229
+
type: KubernetesPods
212
230
```
213
231
214
-
{{< alert level="info" >}}
215
-
Полный перечень параметров конфигурации приведен в разделе [Настройки](./configuration.html).
216
-
{{< /alert >}}
232
+
Для просмотра событий в Grafana используйте запрос к Loki:
- `type`— тип события (Access to VM, VM Management и т.д.);
240
+
- `name`— описание события;
241
+
- `request_subject`— username или ServiceAccount;
242
+
- `datetime`— время события;
243
+
- `virtualmachine_name`— имя ВМ;
244
+
- `source_ip`— IP-адрес источника (для запрещённых операций).
245
+
246
+
### События безопасности
247
+
248
+
Система аудита фиксирует следующие события:
249
+
250
+
- Доступ к ВМ — подключение через console, VNC или port forward. Включает имя ВМ, ОС, версии, хранилище и адрес узла.
251
+
- Управление ВМ — создание, обновление, изменение или удаление ресурсов [VirtualMachine](/modules/virtualization/cr.html#virtualmachine).
252
+
- Управление ВМ через операции — Start, Stop, Restart, Migrate или Evict через ресурс [VirtualMachineOperation](/modules/virtualization/cr.html#virtualmachineoperation).
0 commit comments