Feat: The crawler works on docker
This commit is contained in:
18
Dockerfile
Normal file
18
Dockerfile
Normal file
@@ -0,0 +1,18 @@
|
||||
# Utilise une image Python officielle
|
||||
FROM python:3.13-slim
|
||||
|
||||
|
||||
# Copie le projet dans le conteneur
|
||||
WORKDIR /app
|
||||
|
||||
# Copie les dépendances du projet
|
||||
COPY requirements.txt .
|
||||
|
||||
# Installe les dépendances
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
COPY ./crawler2 .
|
||||
COPY scrapy.cfg .
|
||||
|
||||
# Commande pour lancer le spider
|
||||
CMD ["scrapy", "crawl", "crawler_spider"]
|
||||
Reference in New Issue
Block a user