Cleanup Docker clean steps
This commit is contained in:
@@ -23,8 +23,7 @@ ENV PYTHONUNBUFFERED=1
|
|||||||
WORKDIR /home/${USERNAME}
|
WORKDIR /home/${USERNAME}
|
||||||
|
|
||||||
# 3. A: Install dependencies
|
# 3. A: Install dependencies
|
||||||
RUN apt-get update
|
RUN apt-get update && apt-get install -y \
|
||||||
RUN apt-get install -y \
|
|
||||||
--no-install-recommends \
|
--no-install-recommends \
|
||||||
--no-install-suggests \
|
--no-install-suggests \
|
||||||
tree
|
tree
|
||||||
@@ -52,11 +51,11 @@ RUN ollama serve & sleep 5 && ollama pull llama3.1:8b
|
|||||||
USER root
|
USER root
|
||||||
|
|
||||||
# 5. Cleanup
|
# 5. Cleanup
|
||||||
RUN apt-get autoremove --purge
|
RUN apt-get autoremove -yqq --purge \
|
||||||
RUN apt-get autoclean
|
&& apt-get clean \
|
||||||
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
|
&& rm -rf /tmp/*
|
||||||
|
|
||||||
RUN rm -rf /var/lib/apt/lists/*
|
|
||||||
RUN rm -rf /tmp/*
|
|
||||||
RUN mkdir -p /tmp/apps
|
RUN mkdir -p /tmp/apps
|
||||||
|
|
||||||
# 6. Expose Port and define the command used to run the app
|
# 6. Expose Port and define the command used to run the app
|
||||||
|
|||||||
@@ -58,10 +58,10 @@ RUN apt-get update && apt-get install -y \
|
|||||||
# 4. Copy files over
|
# 4. Copy files over
|
||||||
|
|
||||||
# 5. Cleanup
|
# 5. Cleanup
|
||||||
RUN apt-get autoremove -y --purge && apt-get autoclean
|
RUN apt-get autoremove -yqq --purge \
|
||||||
|
&& apt-get clean \
|
||||||
RUN rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
RUN rm -rf /tmp/*
|
&& rm -rf /tmp/*
|
||||||
|
|
||||||
# 6. Expose Port and define the command used to run the app
|
# 6. Expose Port and define the command used to run the app
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|||||||
@@ -92,12 +92,11 @@ RUN npm --version
|
|||||||
# 4. ...
|
# 4. ...
|
||||||
|
|
||||||
# 5. Cleanup
|
# 5. Cleanup
|
||||||
RUN apt-get autoremove -y --purge
|
RUN apt-get autoremove -yqq --purge \
|
||||||
RUN apt-get autoclean
|
&& apt-get clean \
|
||||||
|
&& rm -rf /var/lib/apt/lists/* \
|
||||||
RUN rm -rf /var/lib/apt/lists/*
|
&& rm -rf /tmp/*
|
||||||
RUN rm -rf /tmp/*
|
&& rm requirements.txt
|
||||||
RUN rm requirements.txt
|
|
||||||
|
|
||||||
# 6. Expose Port and define the command used to run the app
|
# 6. Expose Port and define the command used to run the app
|
||||||
CMD ["bash"]
|
CMD ["bash"]
|
||||||
|
|||||||
Reference in New Issue
Block a user