venv and pip install in dockerfile

This commit is contained in:
Dobromir Popov
2023-12-19 20:44:51 +00:00
parent 2a947d6c7c
commit b27700ae5c
6 changed files with 103 additions and 22 deletions

18
.vscode/launch.json vendored
View File

@ -12,13 +12,25 @@
"platform": "node"
},
{
"name": "Docker Python Launch",
"name": "Docker Python Launch?",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/agent-py-bot/agent.py",
"console": "integratedTerminal",
"pythonPath": "${command:python.interpreterPath}", // Assumes Python extension is installed
"preLaunchTask": "docker-run: python-debug", // You may need to create this task
// "python": "${command:python.interpreterPath}", // Assumes Python extension is installed
// "preLaunchTask": "docker-run: python-debug", // You may need to create this task
// "env": {
// "PYTHONUNBUFFERED": "1"
// }
},
{
"name": "Docker Python Launch with venv",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/agent-py-bot/agent.py",
"console": "integratedTerminal",
"preLaunchTask": "activate-venv", // Custom task to activate venv and run Docker
"python": "/venv/bin/python", // Path to the Python interpreter in your venv
"env": {
"PYTHONUNBUFFERED": "1"
}