@@ -102,30 +102,29 @@ when the base image is built, label metadata is included
102
102
in special metadata files in ` /sysroot/ostree ` that correspond
103
103
to components of the base image.
104
104
105
- When a bootc container is deployed, the system
106
- will use these default SELinux labels.
107
- Further non-OSTree layers will be dynamically labeled
108
- using the base policy.
109
-
110
- Hence, at the current time it will * not* work to override
111
- the labels for files in derived layers by using e.g.
105
+ File content in derived layers will be labeled using the default file
106
+ contexts (from ` /etc/selinux ` ). For example, you can do this (as of
107
+ bootc 1.1.0):
112
108
113
109
```
114
110
RUN semanage fcontext -a -t httpd_sys_content_t "/web(/.*)?"
115
111
```
116
112
117
113
(This command will write to ` /etc/selinux/$policy/policy/ ` .)
118
114
119
- It will * never * work to do e.g.:
115
+ It will currently not work to do e.g.:
120
116
121
117
```
122
118
RUN chcon -t foo_t /usr/bin/foo
123
119
```
124
120
125
121
Because the container runtime state will deny the attempt to
126
122
"physically" set the ` security.selinux ` extended attribute.
127
- In contrast per above, future support for custom labeling
128
- will by default be done by customizing the policy file_contexts.
123
+
124
+ In the future, it is likely however that we add support
125
+ for handling the ` security.selinux ` extended attribute in tar
126
+ streams; but this can only currently be done with a custom
127
+ build process.
129
128
130
129
### Toplevel directories
131
130
0 commit comments