From 9ee391fee8154ea03440d01fe10d0196ffe8d062 Mon Sep 17 00:00:00 2001 From: Mirko Milovanovic Date: Thu, 20 Feb 2025 21:13:02 +0100 Subject: [PATCH] feat: streamline Dockerfile and docker-compose configuration for improved build efficiency --- Monolith.dockerfile | 7 +++---- docker-compose.yml | 3 --- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/Monolith.dockerfile b/Monolith.dockerfile index 7807e7e..a18b21e 100644 --- a/Monolith.dockerfile +++ b/Monolith.dockerfile @@ -23,9 +23,8 @@ WORKDIR /tmp RUN wget -q https://repos.influxdata.com/influxdata-archive_compat.key && \ echo '393e8779c89ac8d958f81f942f9ad7fb82a25e133faddaf92e15b16e6ac9ce4c influxdata-archive_compat.key' | sha256sum -c && \ cat influxdata-archive_compat.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/influxdata-archive_compat.gpg > /dev/null && \ - echo 'deb [signed-by=/etc/apt/trusted.gpg.d/influxdata-archive_compat.gpg] https://repos.influxdata.com/debian stable main' | sudo tee /etc/apt/sources.list.d/influxdata.list - -RUN sudo apt-get update && sudo apt-get install -y telegraf + echo 'deb [signed-by=/etc/apt/trusted.gpg.d/influxdata-archive_compat.gpg] https://repos.influxdata.com/debian stable main' | sudo tee /etc/apt/sources.list.d/influxdata.list && \ + sudo apt-get update && sudo apt-get install -y telegraf # Create and activate a virtual environment RUN python3 -m venv ./venv @@ -35,7 +34,7 @@ ENV PATH="/tmp/venv/bin:$PATH" COPY requirements.txt ./requirements.txt RUN ./venv/bin/pip install -r ./requirements.txt -# Copy the application +# Copy files COPY main.py . COPY utils/ ./utils COPY telegraf.conf ./telegraf.conf diff --git a/docker-compose.yml b/docker-compose.yml index 72a6e69..570bc12 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -6,9 +6,6 @@ services: - build-extension:/tmp/webrtc-internals-exporter shm_size: "2g" attach: false - depends_on: - telegraf: - condition: service_healthy healthcheck: test: ["CMD", "curl", "-f", "http://localhost:4444/wd/hub/status"] interval: 5s