From 1bf13c60ca23e693e90dc8c97cf5d5422db6da58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82?= Date: Mon, 12 Jun 2023 11:40:31 +0200 Subject: [PATCH] Add Rust in Dockerfile --- label_studio_ml/examples/ner/Dockerfile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/label_studio_ml/examples/ner/Dockerfile b/label_studio_ml/examples/ner/Dockerfile index b7ad93f44..8c799a7ac 100644 --- a/label_studio_ml/examples/ner/Dockerfile +++ b/label_studio_ml/examples/ner/Dockerfile @@ -7,6 +7,20 @@ ENV PYTHONUNBUFFERED=True \ PORT=${PORT:-9090} \ PIP_CACHE_DIR=/.cache +# Update default packages +RUN apt-get -qq update + +# Get Ubuntu packages +RUN apt-get install -y -q \ + build-essential \ + curl + +# Get Rust; NOTE: using sh for better compatibility with other base images +RUN curl https://sh.rustup.rs -sSf | sh -s -- -y + +# Add .cargo/bin to PATH +ENV PATH="/root/.cargo/bin:${PATH}" + RUN --mount=type=cache,target=$PIP_CACHE_DIR \ pip install -r requirements.txt