Skip to content

Commit ea55ec2

Browse files
committed
Fix dev-container setup
1 parent 08e045c commit ea55ec2

File tree

3 files changed

+6
-18
lines changed

3 files changed

+6
-18
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ RUN if [ "${NODE_VERSION}" != "none" ]; then su vscode -c "umask 0002 && . /usr/
1010

1111
RUN apt update && \
1212
apt install -y entr snmp && \
13-
pip install -U pip && \
14-
pip install fabric pre-commit docutils
13+
pip install -U pip
1514

1615
# [Optional] If your requirements rarely change, uncomment this section to add them to the image.
1716
# COPY requirements.txt /tmp/pip-tmp/

.devcontainer/devcontainer.json

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
"dockerComposeFile": "docker-compose.yml",
77
"service": "app",
88
"workspaceFolder": "/workspace",
9-
109
// Configure tool-specific properties.
1110
"customizations": {
1211
// Configure properties specific to VS Code.
@@ -15,19 +14,8 @@
1514
"settings": {
1615
"python.defaultInterpreterPath": "/usr/local/bin/python",
1716
"python.linting.enabled": true,
18-
"python.linting.pylintEnabled": true,
19-
"python.formatting.autopep8Path": "/usr/local/py-utils/bin/autopep8",
20-
"python.formatting.blackPath": "/usr/local/py-utils/bin/black",
21-
"python.formatting.yapfPath": "/usr/local/py-utils/bin/yapf",
22-
"python.linting.banditPath": "/usr/local/py-utils/bin/bandit",
23-
"python.linting.flake8Path": "/usr/local/py-utils/bin/flake8",
24-
"python.linting.mypyPath": "/usr/local/py-utils/bin/mypy",
25-
"python.linting.pycodestylePath": "/usr/local/py-utils/bin/pycodestyle",
26-
"python.linting.pydocstylePath": "/usr/local/py-utils/bin/pydocstyle",
27-
"python.linting.pylintPath": "/usr/local/py-utils/bin/pylint",
28-
"python.testing.pytestPath": "/usr/local/py-utils/bin/pytest"
17+
"python.linting.pylintEnabled": true
2918
},
30-
3119
// Add the IDs of extensions you want installed when the container is created.
3220
"extensions": [
3321
"ms-python.python",
@@ -36,14 +24,11 @@
3624
]
3725
}
3826
},
39-
4027
// Use 'forwardPorts' to make a list of ports inside the container available locally.
4128
// This can be used to network with other containers or the host.
4229
// "forwardPorts": [161],
43-
4430
// Use 'postCreateCommand' to run commands after the container is created.
4531
"postCreateCommand": "bash ./.devcontainer/init-devcontainer.bash",
46-
4732
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
4833
"remoteUser": "vscode"
4934
}

.devcontainer/init-devcontainer.bash

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,9 @@
33
# This script is executed in the root-folder (as non-root user) of the project
44
# when the container is created using the VS-Code Remote-Development extension.
55
# -----------------------------------------------------------------------------
6+
pip install --user pipx
7+
pipx install fabric
8+
pipx install pre-commit
9+
pipx install docutils
610
fab develop
711
pre-commit install

0 commit comments

Comments
 (0)