Skip to content
This repository was archived by the owner on Sep 6, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/contributing/integrating-a-hook/templates-dir.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,9 @@ spec:
env:
- name: WEBHOOK_URL
value: {{ .Values.webhookUrl | quote }}
affinity:
{{- toYaml .Values.hook.affinity | nindent 4 }}
tolerations:
{{- toYaml .Values.hook.tolerations | nindent 4 }}
```

8 changes: 8 additions & 0 deletions docs/contributing/integrating-a-hook/values.yaml.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,14 @@ Adds Kubernetes labels to the Hook definition. See the [Hooks HowTo](/docs/how-t
You can specify the priority of the hook with `hook.priorty`.
By default, this priority should be zero since they regard deployment-specific configurations which the secureCodeBox team does not manage.

### Affinity

Optional affinity settings that control how the hook is scheduled (see: [Node Affinity | Kubernetes](https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/))

### Tolerations

Optional tolerations settings that control how the hook is scheduled (see: [Tolerations | Kubernetes](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/))

## Additional Values

If your hook needs some additional information like an URL (`webhookUrl` in the example above), environment variables or volume mounts, you need to provide an option to specify them in your `values.yaml` and access them in the hook implementation (See [templates](/docs/contributing/integrating-a-hook/templates-dir) for information on how to access the provided values, and [ScanCompletionHook](/docs/api/crds/scan-completion-hook) for a list of possible keys you can set in the template).
8 changes: 8 additions & 0 deletions docs/contributing/integrating-a-scanner/values.yaml.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,3 +147,11 @@ Optional securityContext set on the container (see: [Configure a Security Contex
### scopeLimiterAliases

Optional scopeLimiterAliases set on the parse definition (see [ScopeLimiterAliases](/docs/api/crds/parse-definition#scopelimiteraliases-optional))

### affinity

Optional affinity settings that control how the job is scheduled (see: [Node Affinity | Kubernetes](https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes-using-node-affinity/))

### tolerations

Optional tolerations settings that control how the job is scheduled (see: [Tolerations | Kubernetes](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/))