Skip to content
Snippets Groups Projects
Commit 04929c7c authored by Nicolas KAROLAK's avatar Nicolas KAROLAK
Browse files

update devcontainer

parent dff626f5
No related branches found
No related tags found
No related merge requests found
FROM registry.ubicast.net/docker/debian-dev:buster
FROM registry.ubicast.net/docker/debian-dev:latest
# avoid warnings by switching to noninteractive
ENV DEBIAN_FRONTEND=noninteractive
......@@ -11,15 +11,22 @@ RUN \
# install required tools
sudo apt-get update && \
sudo apt-get install -y \
libffi-dev \
libssl-dev \
bsd-mailx \
python3-defusedxml \
python3-dnspython \
python3-openssl \
python3-psutil \
python3-psycopg2 \
python3-pydbus \
python3-requests \
python3-spf \
&& \
# clean up
sudo apt-get autoremove -y && \
sudo apt-get clean -y && \
sudo rm -rf /var/lib/apt/lists/* && \
# create pyvenv
python3 -m venv ${PYVENV} && \
python3 -m venv --system-site-packages ${PYVENV} && \
# update pip tools into pyvenv
pip install -U \
pip \
......@@ -28,10 +35,13 @@ RUN \
:
RUN \
# requirements
pip install psutil pyOpenSSL pyspf requests defusedxml && \
# dev requirements
pip install black flake8 pre-commit pylint pysnooper && \
pip install \
black \
flake8 \
pylint \
pysnooper \
&& \
:
# switch back to dialog for any ad-hoc use of apt-get
......
{
"name": "envsetup",
"dockerComposeFile": "docker-compose.yml",
"service": "app",
"workspaceFolder": "/workspace",
"postCreateCommand": "bash .devcontainer/scripts/postcreate.sh",
"extensions": [
// python
"ms-python.python",
],
"settings": {
"python.pythonPath": "/home/vscode/pyvenv/bin/python",
"python.formatting.provider": "black",
},
}
#!/usr/bin/env bash
# make the GID match with docker on the host
sudo groupmod -g $(ls -ln /var/run/docker.sock | awk '{ print $4 }') docker
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment