From 9d27b94bccbafe958f66805f46d45e313eca875e Mon Sep 17 00:00:00 2001 From: ZanzyTHEbar Date: Sat, 25 Mar 2023 19:35:36 +0000 Subject: [PATCH] fix: docker container failing to build --- .devcontainer/devcontainer.json | 15 +++++++++++++++ Dockerfile | 14 +++++++------- 2 files changed, 22 insertions(+), 7 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 0422608..bdb1b11 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -16,6 +16,21 @@ "version": "3.11" } }, + "customizations": { + "vscode": { + "settings": {}, + "extensions": [ + "streetsidesoftware.code-spell-checker", + "ms-python.python", + "ms-python.vscode-pylance", + "ms-azuretools.vscode-docker", + "wayou.vscode-todo-highlight", + "gruntfuggly.todo-tree", + "eamodio.gitlens", + "github.vscode-pull-request-github" + ] + } + }, // Features to add to the dev container. More info: https://containers.dev/features. // "features": {}, // Use 'forwardPorts' to make a list of ports inside the container available locally. diff --git a/Dockerfile b/Dockerfile index cb8f6e0..f24089b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,17 +12,17 @@ ENV PYTHONUNBUFFERED=1 WORKDIR /app COPY . /app -ADD scripts/setup.sh /app/setup.sh - # Install pip requirements COPY pyproject.toml . -RUN chmod +x setup.sh && ./setup.sh - +RUN apt-get update &&\ + apt-get install ffmpeg libsm6 libxext6 -y &&\ + apt install libgl1-mesa-glx &&\ + apt install build-essential -y --no-install-recommends &&\ + apt-get install make &&\ + apt-get install python3-pip -y --no-install-recommends &&\ + pip3 install poetry # Creates a non-root user with an explicit UID and adds permission to access the /app folder # For more info, please refer to https://aka.ms/vscode-docker-python-configure-containers RUN adduser -u 5678 --disabled-password --gecos "" appuser && chown -R appuser /app USER appuser - -# During debugging, this entry point will be overridden. For more information, please refer to https://aka.ms/vscode-docker-python-debug -CMD ["make"]