mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2025-01-18 00:48:10 +01:00
feat(aa): add the hat template.
This commit is contained in:
parent
3b0944c615
commit
0761a6c466
2 changed files with 22 additions and 0 deletions
18
pkg/aa/templates/hat.j2
Normal file
18
pkg/aa/templates/hat.j2
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
{{- /* apparmor.d - Full set of apparmor profiles */ -}}
|
||||||
|
{{- /* Copyright (C) 2021-2024 Alexandre Pujol <alexandre@pujol.io> */ -}}
|
||||||
|
{{- /* SPDX-License-Identifier: GPL-2.0-only */ -}}
|
||||||
|
|
||||||
|
{{- define "hat" -}}
|
||||||
|
|
||||||
|
{{- "hat" -}}
|
||||||
|
{{- with .Name -}}
|
||||||
|
{{ " " }}{{ . }}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{- " {\n" -}}
|
||||||
|
{{- setindent "++" -}}
|
||||||
|
{{- template "rules" .Rules -}}
|
||||||
|
{{- setindent "--" -}}
|
||||||
|
{{- indent "}" -}}
|
||||||
|
|
||||||
|
{{- end -}}
|
|
@ -114,6 +114,10 @@
|
||||||
{{- template "profile" . -}}
|
{{- template "profile" . -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{- if eq $kind "hat" -}}
|
||||||
|
{{- template "hat" . -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
{{- "\n" -}}
|
{{- "\n" -}}
|
||||||
{{- $oldkind = $kind -}}
|
{{- $oldkind = $kind -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
Loading…
Reference in a new issue