Sign inSign up

thx123/python3.8-with-bazel

By thx123

•Updated over 1 year ago

Python3.8.10-buster with Bazel

Image
Developer tools
0

321

thx123/python3.8-with-bazel repository overview

⁠Dockerfile:

FROM python:3.8.10-buster

# Install sudo, etc.
RUN apt-get update && apt-get install -y sudo wget git make

# Install Bazel
RUN wget https://github.com/bazelbuild/bazelisk/releases/download/v1.19.0/bazelisk-linux-amd64 \
    && chmod +x bazelisk-linux-amd64 \
    && mv bazelisk-linux-amd64 /usr/local/bin/bazel

# Create a user 'builder', having sudo, and switch to its home folder
RUN useradd -ms /bin/bash builder \
    && echo "builder ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/builder

USER builder
WORKDIR /home/builder

# Install pip and pipenv
RUN python3 -m pip install --upgrade pip \
    && python3 -m pip install pipenv

# Set the entrypoint to bash
ENTRYPOINT ["/bin/bash"]

⁠Build

docker build --platform linux/amd64 -t thx123/python3.8-with-bazel:latest -t thx123/python3.8-with-bazel:1.0 .

⁠Push

docker login ...
docker push thx123/python3.8-with-bazel:latest
docker push thx123/python3.8-with-bazel:1.0

Tag summary

Content type

Image

Digest

sha256:98433bb42…

Size

271.6 MB

Last updated

over 1 year ago

docker pull thx123/python3.8-with-bazel