Spaces:
Runtime error
Runtime error
File size: 1,076 Bytes
58661f4 cf13325 d4d41c8 cf13325 d4d41c8 b2577d0 d4d41c8 cf13325 b2577d0 44b1b38 b2577d0 d4d41c8 58661f4 b2577d0 8376488 cf13325 d4d41c8 b2577d0 cf13325 d4d41c8 8b609c0 d4d41c8 5c1d3e0 1fdc52f 5e42df4 8376488 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
FROM python:3.9-slim
# Exposing ports
EXPOSE 6900
# Environment variables
ENV ARGILLA_LOCAL_AUTH_USERS_DB_FILE=/packages/users.yml
ENV UVICORN_PORT=6900
# Copying argilla distribution files
COPY *.whl /packages/
# Copy users db file along with execution script
COPY start.sh /
COPY load_data.py /
COPY users.yml /packages/
# Install packages
RUN apt update
RUN apt -y install python3.9-dev gcc gnupg apache2-utils systemctl curl sudo vim
# Create new user for starting elasticsearch
RUN useradd -ms /bin/bash user -p "$(openssl passwd -1 ubuntu)"
RUN echo 'user ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
# Install argilla
RUN chmod +x /start.sh \
&& for wheel in /packages/*.whl; do pip install "$wheel"[server]; done
# Install Elasticsearch
RUN curl -fsSL https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -
RUN echo "deb https://artifacts.elastic.co/packages/8.x/apt stable main" | tee -a /etc/apt/sources.list.d/elastic-8.x.list
RUN apt update
RUN apt -y install elasticsearch
# Executing argilla along with elasticsearch
CMD /bin/bash /start.sh
|