rootless `--in-vm` bootc disk image generation fails with SELinux
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 48/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Ít trao đổi
- Công nghệ
- linux
- Lĩnh vực
- operating-systems
Hướng nghiên cứu
Tái hiện lệnh ibc build qcow2 --in-vm ở chế độ rootless và bắt đầu từ bước org.osbuild.selinux, đặc biệt là lời gọi setfiles được hiển thị trong traceback. Điều tra lý do việc gán nhãn cho /usr/bin/pesto trả về Invalid argument ở chế độ này; hoàn tất có nghĩa là cùng một bản build hoàn thành thành công ở chế độ rootless khi SELinux được bật.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Trying to build a bootc disk image rootless using the new --in-vm flag :
ibc build qcow2 \ tekton ✭
--in-vm \
--bootc-build-ref $BUILDER \
--bootc-ref $TARGET_FCOS_IMAGE \
--output-name fedora-coreos-rawhide \
--output-dir output \
--with-buildlog --with-manifest \
--blueprint /srv/shared/blueprint.toml \
--blueprint /srv/qemu/x86_64.toml
Manifest generation step
Building manifest for bootc-based-qcow2
Image building step
starting -Pipeline source org.osbuild.containers-storage: 0079d3e26b7100b691705910fb02815586246c11b4bcff17e455be7741ce6bb4
Build
root: <host>
Pipeline target: 1a68fb1a34ab1c055377e67097c58060f09e7df2a3483577a5eb7f2d94d992e1
Build
root: <host>
runner: org.osbuild.fedora38 (org.osbuild.fedora38)
org.osbuild.container-deploy: 3f49744f03469239837affabb6ae2cc3318ec0c0590801028be6ed896f22d2ba {
"remove-signatures": true
}
075c3ef3bd4cb4de9a23cf92a141f58c0b8f8bf525c86cad2f0fa46571eee94e
umount: /run/osbuild/containers/storage/overlay: not mounted.
WARNING: umount of overlay dir failed with an error: CompletedProcess(args=['umount', '-f', '--lazy', '/run/osbuild/containers/storage/overlay'], returncode=32)
⏱ Duration: 7.71s
org.osbuild.mkdir: 8ad59a9faebf034417cd3cffc15a693bf520e2a5eef30cc46f73635676bdd709 {
"paths": [
{
"path": "/usr/lib/bootc/install",
"parents": true,
"exist_ok": true
},
{
"path": "/usr/lib/ostree",
"parents": true,
"exist_ok": true
}
]
}
⏱ Duration: 0.23s
org.osbuild.selinux: 1a68fb1a34ab1c055377e67097c58060f09e7df2a3483577a5eb7f2d94d992e1 {
"file_contexts": "etc/selinux/targeted/contexts/files/file_contexts",
"exclude_paths": [
"/sysroot"
],
"labels": {
"/usr/bin/mount": "system_u:object_r:install_exec_t:s0",
"/usr/bin/ostree": "system_u:object_r:install_exec_t:s0",
"/usr/bin/umount": "system_u:object_r:install_exec_t:s0"
}
}
setfiles: Could not set context for /run/osbuild/tree/usr/bin/pesto: Invalid argument
Traceback (most recent call last):
File "/run/osbuild/bin/org.osbuild.selinux", line 45, in <module>
r = main(osbuild.api.arguments())
File "/run/osbuild/bin/org.osbuild.selinux", line 26, in main
selinux.setfiles(file_contexts, os.path.normpath(root), target, exclude_paths=exclude_paths)
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/run/osbuild/lib/osbuild/util/selinux.py", line 55, in setfiles
subprocess.run(["setfiles", "-F",
~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^
"-r", root,
^^^^^^^^^^^
...<2 lines>...
f"{root}{path}"],
^^^^^^^^^^^^^^^^^
check=True)
^^^^^^^^^^^
File "/usr/lib64/python3.14/subprocess.py", line 578, in run
raise CalledProcessError(retcode, process.args,
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['setfiles', '-F', '-r', '/run/osbuild/tree', '-e', '/run/osbuild/tree/sysroot', '/run/osbuild/tree/etc/selinux/targeted/contexts/files/file_contexts', '/run/osbuild/tree/']' returned non-zero exit status 255.
⏱ Duration: 0.81s
manifest - failed
Failed
error: error running osbuild: exit status 1
- Ngôn ngữ chính
- Go
- Star
- 86
- Fork
- 115
- Merge trung bình
- 2 ngày 6 giờ
- Pull request đã merge (30 ngày)
- 48
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của osbuild/image-builder
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
osbuild/image-builder#2796 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
admin/has-jira area/bootc area/docs
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
osbuild/image-builder#2695 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
admin/has-jira area/docs
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
osbuild/image-builder#2363 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Multi-step buildsCó thể đã có người làm @achilleas-k đã nhận 12 ngày trước. Đang mởdiscussion
osbuild/image-builder#2802 · 4 bình luận · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
osbuild/image-builder#2791 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của osbuild/image-builder
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày
-
security trivy
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
kubefleet-dev/kubefleet#1038 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
koordinator-sh/koordinator#3257 ·
Maintainer thường phản hồi trong vòng 6 ngày
-
A non-terminal `tool.execution_partial_result` clears the `report_intent` suppression filterĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 92/100
Maintainer thường phản hồi trong vòng 1 ngày