bazel-contrib / bazel-contrib/rules_python
Support native binary-based stage1 bootstrap
- 主要语言
- Starlark
- 星标
- 688
- 派生
- 721
- 平均合并
- 15 小时 7 分钟
- 30 天内合并 PR
- 76
描述
# 🚀 feature request
### Relevant Rules
`py_binary`
### Description
With a similar motivation as #691, we would like to package a `py_binary` (including runfiles) into an `oci_image` and run it within a minimum base image like [distroless_base](https://github.com/GoogleContainerTools/distroless/tree/main/base) in order to minimize the attack surface. This does not come with a shell and other tools which are required by #1929 so this unfortunately doesn't help us.
### Describe the solution you'd like
Use a statically linked executable as loader.
### Describe alternatives you've considered
Add more stuff to the base image. This is suboptimal as this does not only increase the size but also the attack surface.
贡献指南
调研方向
首先检查现有的 py_binary 和 oci_image 集成,然后阅读 #691 和 #1929 中的相关讨论。issue 中没有指定源文件或测试。完成的标准是:py_binary(包括其 runfiles)可以使用静态链接的可执行文件作为 loader,从最小的 distroless_base 镜像中运行。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- python
- 领域
- build-system
- Issue 类型
- 功能
- 难度
- 5/5
- 预计耗时
- 一周以上
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 30/100