Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-treebeard committed Aug 1, 2024
1 parent 4a18c23 commit a6e7492
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .devcontainer/poetry.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[virtualenvs]
create = false
14 changes: 14 additions & 0 deletions .devcontainer/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
[tool.poetry]
name = "base"
version = "0.1.0"
description = ""
authors = ["Your Name <[email protected]>"]

[tool.poetry.dependencies]
python = "^3.11"

[tool.poetry.dev-dependencies]

[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
18 changes: 15 additions & 3 deletions .devcontainer/vm/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,25 @@ RUN if [ "${INSTALL_NODE}" = "true" ]; then su vscode -c "source /usr/local/shar

RUN pip3 --disable-pip-version-check --no-cache-dir install -U \
'poetry==1.1.13' \
'pip==22.1.2' \
'pip==22.1.2'

USER vscode
COPY pyproject.toml /opt/base/pyproject.toml
COPY poetry.toml /opt/base/poetry.toml
RUN sudo chown -R vscode:vscode /opt

ENV PIP_TARGET=/opt/pip
ENV PYTHONPATH=/opt/pip
ENV PATH="${PIP_TARGET}/bin:${PATH}"
WORKDIR /opt/base
RUN poetry add --no-interaction \
'ipykernel' \
'jupyter' \
'nbstripout' \
'pre-commit' \
'black'
USER vscode
'black' \
&& rm -rf ~/.cache/pypoetry/{cache,artifacts}

# prevent homebrew from updating or upgrading to save time
ENV HOMEBREW_NO_AUTO_UPDATE=1
ENV HOMEBREW_NO_INSTALL_UPGRADE=1
Expand Down

0 comments on commit a6e7492

Please sign in to comment.