Docker Community Forums

Share and learn in the Docker community.

Problem with repositories for Ubuntu 18.04

I am going to build a docker container for TensorFlow. This is my script build.bat file.

FROM tensorflow/tensorflow:nightly-gpu-jupyter
RUN apt-get update
RUN apt-get install -y gcc

RUN groupadd -r algorithm && useradd -m --no-log-init -r -g algorithm algorithm
RUN mkdir -p /opt/algorithm /input /output
&& chown algorithm:algorithm /opt/algorithm /input /output
USER algorithm

WORKDIR /opt/algorithm

ENV PATH="/home/algorithm/.local/bin:${PATH}"

RUN python -m pip install --user -U pip

Copy all required files such that they are available within the docker image (code, weights, …)

COPY --chown=algorithm:algorithm requirements.txt /opt/algorithm/

COPY --chown=algorithm:algorithm model/ /opt/algorithm/model/
COPY --chown=algorithm:algorithm util/ /opt/algorithm/util/
COPY --chown=algorithm:algorithm model_weights/ /opt/algorithm/checkpoints/
COPY --chown=algorithm:algorithm /opt/algorithm/
COPY --chown=algorithm:algorithm /opt/algorithm/
COPY --chown=algorithm:algorithm efficientnet-1.1.0-py3-none-any.whl /opt/algorithm/
COPY --chown=algorithm:algorithm image_classifiers-0.2.2-py2.py3-none-any.whl /opt/algorithm/

Install required python packages via pip - you may adapt the requirements.txt to your needs

RUN python -m pip install --user -rrequirements.txt

Entrypoint to your python code - executes as a script

ENTRYPOINT python -m process $0 $@


These labels are required


These labels are required and describe what kind of hardware your algorithm requires to run.

LABEL nl.diagnijmegen.rse.algorithm.hardware.cpu.count=2
LABEL nl.diagnijmegen.rse.algorithm.hardware.cpu.capabilities=()
LABEL nl.diagnijmegen.rse.algorithm.hardware.memory=16G
LABEL nl.diagnijmegen.rse.algorithm.hardware.gpu.count=1
LABEL nl.diagnijmegen.rse.algorithm.hardware.gpu.cuda_compute_capability=6.0
LABEL nl.diagnijmegen.rse.algorithm.hardware.gpu.memory=8G


When I execute the build.bat file it returns following error.
Can anyone help me?