Skip to content

Commit

Permalink
Mark /boot rules as not applicable in bootable containers
Browse files Browse the repository at this point in the history
We will mark rules that checks files in the `/boot/grub2/` directory
as not applicable in the bootable containers. The reason is that
these files don't exist during the container image build. They are
generated from configuration during deployment of the image by
the bootc toolset.
  • Loading branch information
jan-cerny committed Jan 13, 2025
1 parent 6f3c152 commit 0e91e73
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ fixtext: '{{{ fixtext_file_group_owner(grub2_boot_path ~ "/grub.cfg", "root") }}

srg_requirement: '{{{ srg_requirement_file_group_owner(grub2_boot_path ~ "/grub.cfg", "root") }}}'

platform: not bootc

template:
name: file_groupowner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ fixtext: '{{{ fixtext_file_group_owner(grub2_boot_path ~ "/user.cfg", "root") }}

srg_requirement: '{{{ srg_requirement_file_group_owner(grub2_boot_path ~ "/user.cfg", "root") }}}'

platform: not bootc

template:
name: file_groupowner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ ocil_clause: '{{{ ocil_clause_file_owner(file=grub2_boot_path ~ "/grub.cfg", own
ocil: |-
{{{ ocil_file_owner(file=grub2_boot_path ~ "/grub.cfg", owner="root") }}}
platform: not bootc

template:
name: file_owner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ ocil_clause: '{{{ ocil_clause_file_owner(file=grub2_boot_path ~ "/user.cfg", own
ocil: |-
{{{ ocil_file_owner(file=grub2_boot_path ~ "/user.cfg", owner="root") }}}
platform: not bootc

template:
name: file_owner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ ocil: |-
If properly configured, the output should indicate the following
permissions: <tt>-rw-------</tt>
platform: not bootc

template:
name: file_permissions
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ ocil_clause: '{{{ ocil_clause_file_permissions(file=grub2_boot_path ~ "/user.cfg
ocil: |-
{{{ ocil_file_permissions(file=grub2_boot_path ~ "/user.cfg", perms="-rw-------") }}}
platform: not bootc

template:
name: file_permissions
Expand Down

0 comments on commit 0e91e73

Please sign in to comment.