Explicitly provide Python toolchain, provide `python` in build container
This fixes being able to run py_binary targets within the build
container.
Each py_binary creates a stub that always has the #!/usr/bin/env python
shebang, and as such we need to have `python` available in the build
container. The stub then dispatches into the right Python interpreter,
which we now configure explicitely via rules_python's py_runtime_pair.
Test Plan: nothing breaks, future uses of py_binary (eg D389) will make actual use of this
X-Origin-Diff: phab/D390
GitOrigin-RevId: 78b6c51f09c720a46fbe2e6cbadb2a97d1161f7b
diff --git a/WORKSPACE b/WORKSPACE
index 62796fb..3f3598a 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -183,3 +183,5 @@
strip_prefix = "repo-infra-9f4571ad7242bf3ec4b47365062498c2528f9a5f",
urls = mirror("https://github.com/kubernetes/repo-infra/archive/9f4571ad7242bf3ec4b47365062498c2528f9a5f.tar.gz"),
)
+
+register_toolchains("//:host_python")