Skip to content

Commit

Permalink
Add revision to python-wheel-windows tag
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Jun 12, 2022
1 parent 21b3427 commit 083fdba
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 20 deletions.
6 changes: 6 additions & 0 deletions .env
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,12 @@ DEVTOOLSET_VERSION=-1
# https://github.com/ursacomputing/crossbow/blob/master/.github/workflows/cache_vcpkg.yml
VCPKG="38bb87c"

# This must be updated when we update
# ci/docker/python-wheel-windows-vs2017.dockerfile.
# This is a workaround for our CI problem that "archery docker build" doesn't
# use pulled built images in dev/tasks/python-wheels/github.windows.yml.
PYTHON_WHEEL_WINDOWS_IMAGE_REVISION=2022-06-12

# Use conanio/${CONAN} for "docker-compose run --rm conan". See
# https://github.com/conan-io/conan-docker-tools#readme for available
# images.
Expand Down
3 changes: 3 additions & 0 deletions ci/docker/python-wheel-windows-vs2017.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
# specific language governing permissions and limitations
# under the License.

# NOTE: You must update PYTHON_WHEEL_WINDOWS_IMAGE_REVISION in .env
# when you update this file.

# based on mcr.microsoft.com/windows/servercore:ltsc2019
# contains choco and vs2017 preinstalled
FROM abrarov/msvc-2017:2.11.0
Expand Down
19 changes: 13 additions & 6 deletions dev/tasks/python-wheels/github.windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,19 @@ jobs:
shell: cmd
run: |
cd arrow
archery docker run -e SETUPTOOLS_SCM_PRETEND_VERSION={{ arrow.no_rc_version }} python-wheel-windows-vs2017
@rem if errorlevel 0 (
@rem archery docker run --no-build -e SETUPTOOLS_SCM_PRETEND_VERSION={{ arrow.no_rc_version }} python-wheel-windows-vs2017
@rem ) else (
@rem archery docker run -e SETUPTOOLS_SCM_PRETEND_VERSION={{ arrow.no_rc_version }} python-wheel-windows-vs2017
@rem )
@rem We want to use only "archery docker run
@rem -e SETUPTOOLS_SCM_PRETEND_VERSION=...
@rem python-wheel-windows-vs2017" but it doesn't use pulled caches.
@rem It always build an image from scratch.
@rem We can remove this
@rem 'if pull; then; "run --no-build"; else; "run"; fi'
@rem workaround once we find a way to use pulled caches.
archery docker pull python-wheel-windows-vs2017
if errorlevel 0 (
archery docker run --no-build -e SETUPTOOLS_SCM_PRETEND_VERSION={{ arrow.no_rc_version }} python-wheel-windows-vs2017
) else (
archery docker run -e SETUPTOOLS_SCM_PRETEND_VERSION={{ arrow.no_rc_version }} python-wheel-windows-vs2017
)
- name: Test wheel
shell: cmd
Expand Down
18 changes: 4 additions & 14 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -945,17 +945,7 @@ services:
command: /arrow/ci/scripts/python_wheel_unix_test.sh /arrow

python-wheel-windows-vs2017:
# The windows images must be built locally and pushed to a remote registry:
# export REPO=ghcr.io/ursacomputing/arrow
# PYTHON=3.7 archery docker build --no-pull --using-docker-cli python-wheel-windows-vs2017
# PYTHON=3.8 archery docker build --no-pull --using-docker-cli python-wheel-windows-vs2017
# PYTHON=3.9 archery docker build --no-pull --using-docker-cli python-wheel-windows-vs2017
# PYTHON=3.10 archery docker build --no-pull --using-docker-cli python-wheel-windows-vs2017
# PYTHON=3.7 archery docker push python-wheel-windows-vs2017
# PYTHON=3.8 archery docker push python-wheel-windows-vs2017
# PYTHON=3.9 archery docker push python-wheel-windows-vs2017
# PYTHON=3.10 archery docker push python-wheel-windows-vs2017
image: ${REPO}:python-${PYTHON}-wheel-windows-vs2017-vcpkg-${VCPKG}
image: ${REPO}:python-${PYTHON}-wheel-windows-vs2017-vcpkg-${VCPKG}-${PYTHON_WHEEL_WINDOWS_IMAGE_REVISION}
build:
args:
vcpkg: ${VCPKG}
Expand All @@ -964,9 +954,9 @@ services:
dockerfile: ci/docker/python-wheel-windows-vs2017.dockerfile
# This should make the pushed images reusable, but the image gets rebuilt.
# Uncomment if no local cache is available.
cache_from:
- abrarov/msvc-2017:2.11.0
- ${REPO}:python-${PYTHON}-wheel-windows-vs2017-vcpkg-${VCPKG}
# cache_from:
# - abrarov/msvc-2017:2.11.0
# - ${REPO}:python-${PYTHON}-wheel-windows-vs2017-vcpkg-${VCPKG}-${PYTHON_WHEEL_WINDOWS_IMAGE_REVISION}
volumes:
- "${DOCKER_VOLUME_PREFIX}python-wheel-windows-clcache:C:/clcache"
- type: bind
Expand Down

0 comments on commit 083fdba

Please sign in to comment.