auto-labeler / Dockerfile
dillonlaird's picture
make user to remove permissions issue
a3ebaa7
raw
history blame
646 Bytes
FROM node:slim
WORKDIR /code
# python setup
COPY ./requirements.txt /code/requirements.txt
RUN apt-get update && apt-get install -y python3 python3-pip python3-venv ffmpeg libsm6 libxext6 pkg-config libpixman-1-dev libcairo2-dev libpango1.0-dev libgif-dev
RUN python3 -m venv .venv
RUN /code/.venv/bin/pip3 install --no-cache --upgrade -r /code/requirements.txt
RUN useradd -m -u 1001 user
USER user
ENV HOME=/home/user \
PATH=/home/user/.local/bin:$PATH
WORKDIR $HOME/app
COPY . .
COPY --chown=user . $HOME/app
# nextjs setup
WORKDIR $HOME/app/instance-labeler
RUN yarn install && yarn build
CMD ["/code/.venv/bin/python3", "main.py"]