From 278a5d62932dcaf2796f0b69386054af5dfc9b59 Mon Sep 17 00:00:00 2001 From: adrien Date: Thu, 29 Jun 2023 07:55:56 +0200 Subject: [PATCH] add devcontainer --- .devcontainer/devcontainer.json | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .devcontainer/devcontainer.json diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 0000000..757af22 --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,30 @@ +{ + "name": "Python Dev Container", + "image": "python:3.9", + "customizations": { + "terminal.integrated.profiles.linux": { + "bash": { + "path": "/bin/bash" + } + }, + "vscode": { + "settings": { + "terminal.integrated.defaultProfile.linux": "bash" + }, + "extensions": [ + "ms-python.python" + ] + } + }, + "containerEnv": { + "DATABASE_URL": "sqlite:///database.db", + "FLASK_APP": "app.py", + "FLASK_ENV": "development" + }, + "mounts": [ + "source=${localWorkspaceFolder}/database.db,target=/workspace/database.db,type=bind", + "source=${localWorkspaceFolder},target=/workspace/app,type=bind,consistency=cached" + ], + "postCreateCommand": "pip install -r requirements.txt" +} + \ No newline at end of file