Skip to content

Commit

Permalink
CI: devpi installed on ci dockerfiles with pipx
Browse files Browse the repository at this point in the history
  • Loading branch information
henryborchers committed Oct 19, 2023
1 parent ecbe8bb commit c5f9046
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 43 deletions.
13 changes: 13 additions & 0 deletions ci/docker/linux/tox/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
ARG PIPX_HOME=/pipx
ARG PIP_DOWNLOAD_CACHE=/.cache/pip
ARG TARGETARCH=amd64
ARG COMPILER_VERSION_FOR_PREBUILD_CONAN_PACKAGES=11.4
Expand Down Expand Up @@ -63,6 +64,18 @@ ARG PIP_DOWNLOAD_CACHE
RUN mkdir -p ${PIP_DOWNLOAD_CACHE} && \
chmod -R 777 ${PIP_DOWNLOAD_CACHE}
ENV PIP_DOWNLOAD_CACHE=${PIP_DOWNLOAD_CACHE}

ARG PIPX_HOME
ENV PIPX_HOME=${PIPX_HOME}
ENV PIPX_BIN_DIR=${PIPX_HOME}/bin
RUN pip3 install --no-cache-dir pipx && \
pipx ensurepath && \
mkdir -p $PIPX_HOME && chmod -R 777 $PIPX_HOME
RUN PIPX_HOME=/opt/pipx PIPX_BIN_DIR=/usr/local/bin pipx install 'devpi-client<7.0' && \
PIPX_HOME=/opt/pipx PIPX_BIN_DIR=/usr/local/bin pipx install pip-audit



WORKDIR /src

CMD ["tox", "--workdir", "/tmp/tox", "--recreate", "-p=auto"]
12 changes: 11 additions & 1 deletion ci/docker/windows/tox/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# escape=`
ARG PIPX_HOME=c:\pipx
ARG CONAN_USER_HOME=C:/Users/ContainerAdministrator
ARG PIP_DOWNLOAD_CACHE=c:/users/containeradministrator/appdata/local/pip
ARG VS_INSTALL_PATH="C:\BuildTools\"
Expand Down Expand Up @@ -118,7 +119,7 @@ RUN C:\ProgramData\chocolatey\bin\choco.exe install -y --stoponfirstfailure --no
Write-Host "Installing Python with Chocolatey - Done"
# ==============================================================================
FROM BASE_BUILDER as CONAN_BUILDER
FROM BASE_BUILDER AS CONAN_BUILDER
ARG CONAN_USER_HOME
ARG PIP_EXTRA_INDEX_URL
ARG PIP_INDEX_URL
Expand Down Expand Up @@ -174,5 +175,14 @@ RUN conan config home ; `
conan remove "*" -b --src -f ; `
conan remove --locks
ARG PIPX_HOME
ENV PIPX_HOME=${PIPX_HOME}
ENV PIPX_BIN_DIR=${PIPX_HOME}\bin
RUN py -3 -m pip install --no-cache-dir pipx ; `
py -3 -m pipx ensurepath
RUN py -3 -m pipx install 'devpi-client<7.0'
WORKDIR C:/src
CMD ["tox", "--workdir", "${Env:TEMP}\tox\\", "-vv", "--recreate", "-p=auto"]
17 changes: 14 additions & 3 deletions ci/docker/windows/tox_no_vs/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# escape=`
ARG PIPX_HOME=c:\pipx
ARG PIP_DOWNLOAD_CACHE=c:/users/containeradministrator/appdata/local/pip
ARG FROM_IMAGE=mcr.microsoft.com/dotnet/framework/sdk:4.8
FROM ${FROM_IMAGE} as certsgen
FROM ${FROM_IMAGE} AS certsgen
RUN certutil -generateSSTFromWU roots.sst

FROM ${FROM_IMAGE} as BASE_BUILDER
FROM ${FROM_IMAGE} AS BASE_BUILDER

SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop';"]

FROM BASE_BUILDER as CHOCOLATEY_BASE
FROM BASE_BUILDER AS CHOCOLATEY_BASE
ARG CHOCOLATEY_SOURCE=https://chocolatey.org/api/v2
ARG ChocolateyEnvironmentDebug=false
COPY ci/docker/shared/chocolatey/install_choco.ps1 c:/choco/install_choco.ps1
Expand Down Expand Up @@ -68,5 +69,15 @@ ARG PIP_DOWNLOAD_CACHE
RUN New-Item -type directory -path ${Env:PIP_DOWNLOAD_CACHE} -Force
ENV PIP_DOWNLOAD_CACHE=${PIP_DOWNLOAD_CACHE}

ARG PIPX_HOME
ENV PIPX_HOME=${PIPX_HOME}
ENV PIPX_BIN_DIR=${PIPX_HOME}\bin


RUN py -3 -m pip install --no-cache-dir pipx ; `
py -3 -m pipx ensurepath
RUN py -3 -m pipx install 'devpi-client<7.0'


WORKDIR C:/src
CMD ["tox", "--workdir", "${Env:TEMP}\tox\\", "-vv", "--recreate"]
67 changes: 29 additions & 38 deletions requirements/requirements-ci-freeze.txt
Original file line number Diff line number Diff line change
@@ -1,27 +1,23 @@
alabaster==0.7.13
astroid==2.15.6
Babel==2.12.1
astroid==3.0.1
Babel==2.13.0
bcrypt==4.0.1
bleach==6.0.0
bottle==0.12.25
build==0.10.0
build==1.0.3
certifi==2023.7.22
cffi==1.15.1
charset-normalizer==3.2.0
check-manifest==0.49
cmake==3.27.2
cffi==1.16.0
charset-normalizer==3.3.0
cmake==3.27.7
colorama==0.4.6
conan==1.60.2
coverage==7.3.0
cryptography==41.0.3
devpi-client==6.0.5
devpi-common==3.7.2
conan==1.61.0
coverage==7.3.2
cryptography==41.0.4
dill==0.3.7
distlib==0.3.7
docutils==0.20.1
exceptiongroup==1.1.3
fasteners==0.18
filelock==3.12.2
fasteners==0.19
filelock==3.12.4
flake8==6.1.0
gcovr==6.0
idna==3.4
Expand All @@ -32,70 +28,65 @@ isort==5.12.0
jaraco.classes==3.3.0
Jinja2==3.1.2
keyring==24.2.0
lazy==1.5
lazy-object-proxy==1.9.0
lxml==4.9.3
Mako==1.2.4
markdown-it-py==3.0.0
MarkupSafe==2.1.3
mccabe==0.7.0
mdurl==0.1.2
more-itertools==10.1.0
mypy==1.5.0
mypy==1.6.1
mypy-extensions==1.0.0
ninja==1.11.1
nh3==0.2.14
ninja==1.11.1.1
node-semver==0.6.1
packaging==21.3
packaging==23.2
paramiko==3.3.1
parse==1.19.1
parse-type==0.6.2
patch-ng==1.17.4
pep517==0.13.0
pkginfo==1.9.6
platformdirs==3.10.0
pluggy==1.2.0
platformdirs==3.11.0
pluggy==1.3.0
pluginbase==1.0.1
py==1.11.0
pybind11==2.10.4
pycodestyle==2.11.0
pycodestyle==2.11.1
pycparser==2.21
pyflakes==3.1.0
Pygments==2.16.1
PyJWT==2.8.0
pylint==2.17.5
pylint==3.0.1
PyNaCl==1.5.0
pyparsing==3.1.1
pyproject_hooks==1.0.0
pytest==7.4.0
pytest-bdd==6.1.1
pytest==7.4.2
pytest-bdd==7.0.0
pytest-cov==4.1.0
pytest-runner==6.0.0
python-dateutil==2.8.2
PyYAML==6.0.1
readme-renderer==40.0
readme-renderer==42.0
requests==2.31.0
requests-toolbelt==1.0.0
rfc3986==2.0.0
rich==13.5.2
rich==13.6.0
six==1.16.0
snowballstemmer==2.2.0
Sphinx==7.1.2
Sphinx==7.2.6
sphinxcontrib-applehelp==1.0.7
sphinxcontrib-devhelp==1.0.5
sphinxcontrib-htmlhelp==2.0.4
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.6
sphinxcontrib-serializinghtml==1.1.8
sphinxcontrib-serializinghtml==1.1.9
toml==0.10.2
tomli==2.0.1
tomlkit==0.12.1
tox==3.28.0
tqdm==4.66.1
twine==4.0.2
typing_extensions==4.7.1
typing_extensions==4.8.0
uiucprescon.build @ git+https://github.com/UIUCLibrary/uiucprescon_build.git@v0.1.0
urllib3==1.26.16
virtualenv==20.24.3
webencodings==0.5.1
wrapt==1.15.0
zipp==3.16.2
urllib3==1.26.18
virtualenv==20.24.5
zipp==3.17.0
1 change: 0 additions & 1 deletion requirements/requirements-ci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ build
cmake
conan
coverage
devpi-client
flake8
gcovr
importlib-metadata>=0.12; python_version < "3.8"
Expand Down

0 comments on commit c5f9046

Please sign in to comment.