Refactor Dockerfile to clone aerospace-chatbot repository and update file paths
Browse files- Dockerfile +7 -7
Dockerfile
CHANGED
@@ -7,9 +7,9 @@ RUN useradd -m -u 1000 user
|
|
7 |
USER user
|
8 |
|
9 |
# Clone aerospace-chatbot github repository
|
10 |
-
RUN apt-get update &&
|
11 |
-
|
12 |
-
RUN git clone -b rag_study https://github.com/dan-s-mueller/aerospace_chatbot.git
|
13 |
|
14 |
# Set home to the user's home directory
|
15 |
ENV HOME=/home/user \
|
@@ -23,7 +23,7 @@ RUN mkdir -p $HOME/src $HOME/data $HOME/config
|
|
23 |
RUN pip3 install poetry==1.7.1
|
24 |
|
25 |
# Copy poetry files
|
26 |
-
COPY --chown=user /app/pyproject.toml /app/poetry.lock* $HOME
|
27 |
|
28 |
# Disable virtual environments creation by Poetry
|
29 |
# as the Docker container itself is an isolated environment
|
@@ -39,9 +39,9 @@ ENV PATH="$HOME/.venv/bin:$PATH"
|
|
39 |
RUN poetry install --no-dev
|
40 |
|
41 |
# Copy the rest of your application code
|
42 |
-
COPY --chown=user /app/src $HOME/src
|
43 |
-
COPY --chown=user /app/data $HOME/data
|
44 |
-
COPY --chown=user /app/config $HOME/config
|
45 |
|
46 |
# Expose the port Streamlit runs on
|
47 |
EXPOSE 8501
|
|
|
7 |
USER user
|
8 |
|
9 |
# Clone aerospace-chatbot github repository
|
10 |
+
RUN apt-get update && \
|
11 |
+
apt-get install -y git
|
12 |
+
RUN git clone -b rag_study https://github.com/dan-s-mueller/aerospace_chatbot.git /app
|
13 |
|
14 |
# Set home to the user's home directory
|
15 |
ENV HOME=/home/user \
|
|
|
23 |
RUN pip3 install poetry==1.7.1
|
24 |
|
25 |
# Copy poetry files
|
26 |
+
COPY --chown=user /app/aerospace_chatbot/pyproject.toml /app/aerospace_chatbot/poetry.lock* $HOME
|
27 |
|
28 |
# Disable virtual environments creation by Poetry
|
29 |
# as the Docker container itself is an isolated environment
|
|
|
39 |
RUN poetry install --no-dev
|
40 |
|
41 |
# Copy the rest of your application code
|
42 |
+
COPY --chown=user /app/aerospace_chatbot/src $HOME/src
|
43 |
+
COPY --chown=user /app/aerospace_chatbot/data $HOME/data
|
44 |
+
COPY --chown=user /app/aerospace_chatbot/config $HOME/config
|
45 |
|
46 |
# Expose the port Streamlit runs on
|
47 |
EXPOSE 8501
|