add dockerfile

pull/9/head
Bastien OLLIER 10 months ago committed by clfreville2
parent 7ceae78dfc
commit 48229b5462

@ -11,3 +11,28 @@ steps:
commands: commands:
- pip install --root-user-action=ignore -r requirements.txt - pip install --root-user-action=ignore -r requirements.txt
- ruff check . - ruff check .
- name: docker-image
image: plugins/docker
settings:
context: frontend/
dockerfile: Dockerfile
registry: hub.codefirst.iut.uca.fr
repo: hub.codefirst.iut.uca.fr/bastien.ollier/miner
username:
from_secret: REGISTRY_USER
password:
from_secret: REGISTRY_PASSWORD
cache_from:
- hub.codefirst.iut.uca.fr/bastien.ollier/miner:latest
depends_on: [ lint ]
- name: deploy-miner
image: hub.codefirst.iut.uca.fr/thomas.bellembois/codefirst-dockerproxy-clientdrone:latest
environment:
IMAGENAME: hub.codefirst.iut.uca.fr/bastien.ollier/miner:latest
CONTAINERNAME: miner
COMMAND: create
OVERWRITE: true
ADMINS: baollier1
depends_on: [ docker-image ]

@ -0,0 +1,20 @@
FROM python:3.9-slim
WORKDIR /app
RUN apt-get update && apt-get install -y \
build-essential \
curl \
software-properties-common \
git \
&& rm -rf /var/lib/apt/lists/*
RUN ls
RUN pip3 install -r requirements.txt
EXPOSE 8501
HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health
ENTRYPOINT ["streamlit", "run", "streamlit_app.py", "--server.port=8501", "--server.address=0.0.0.0"]
Loading…
Cancel
Save