This repo demonstrates how to use rules_pycross, rules_py and rules_oci to create Docker images from Python apps.
First, setup your .bazelrc:
$ cp .bazelrc.example .bazelrcTo run the app outside of Docker:
$ bazel run //cowapp
_________________
/ \
| [[ 0 1 2 3 4] |
| [ 5 6 7 8 9] |
| [10 11 12 13 14]] |
\ /
=================
\
\
^__^
(oo)\_______
(__)\ )\/\
||----w |
|| ||To build and register the Docker image:
$ bazel run //cowapp:tarball_linux_x86_64To run the image:
$ docker run --rm bazel/cowapp_linux_x86_64:latest
_________________
/ \
| [[ 0 1 2 3 4] |
| [ 5 6 7 8 9] |
| [10 11 12 13 14]] |
\ /
=================
\
\
^__^
(oo)\_______
(__)\ )\/\
||----w |
|| ||