Docker
Dockerize your applications for easy deployment
List out all the running containers
docker ps
List out the images
docker image list
Build out your image
docker build -t {desired image name} {folder location}
Run your docker image on port number
docker run -t -p 443:443 streamlit.latest
Prune to clean
docker system prune
debug ye file
#insert into entry point
tail -f /dev/null
Example docker script
# app/Dockerfile
FROM python:3.9-slim
EXPOSE 8501
WORKDIR /app
RUN apt-get update && apt-get install -y \
build-essential \
software-properties-common \
git \
&& rm -rf /var/lib/apt/lists/*
COPY . /app/
RUN pip3 install -r requirements.txt
ENTRYPOINT ["streamlit", "run", "/app/streamlit-survey.py", "--server.port=8501"]