Skip to content

Apache DataFusion SQL Query Engine

ARROW-8165: [Packaging] Make nightly wheels available on a PyPI server

Krisztián Szűcs2b84fb49c8ac
diff --git a/dev/tasks/conda-recipes/azure.linux.yml b/dev/tasks/conda-recipes/azure.linux.yml
index 49bcd6057e..f89530814c 100755
--- a/dev/tasks/conda-recipes/azure.linux.yml
+++ b/dev/tasks/conda-recipes/azure.linux.yml
@@ -55,7 +55,9 @@ jobs:
CROSSBOW_GITHUB_TOKEN: $(CROSSBOW_GITHUB_TOKEN)
displayName: Upload packages as a GitHub release
+ {% if arrow.branch == 'master' %}
# Upload to custom anaconda channel
- script: |
anaconda -t $(CROSSBOW_ANACONDA_TOKEN) upload -l nightly --force build_artifacts/linux-64/*.tar.bz2
displayName: Upload packages to Anaconda
+ {% endif %}
diff --git a/dev/tasks/conda-recipes/azure.osx.yml b/dev/tasks/conda-recipes/azure.osx.yml
index dea639183e..1c463808e3 100755
--- a/dev/tasks/conda-recipes/azure.osx.yml
+++ b/dev/tasks/conda-recipes/azure.osx.yml
@@ -87,6 +87,7 @@ jobs:
CROSSBOW_GITHUB_TOKEN: $(CROSSBOW_GITHUB_TOKEN)
displayName: Upload packages as a GitHub release
+ {% if arrow.branch == 'master' %}
# Upload to custom anaconda channel
- script: |
source activate base
@@ -94,3 +95,4 @@ jobs:
anaconda -t $(CROSSBOW_ANACONDA_TOKEN) upload -l nightly --force build_artifacts/osx-64/*.tar.bz2
displayName: Upload packages to Anaconda
workingDirectory: arrow/dev/tasks/conda-recipes
+ {% endif %}
diff --git a/dev/tasks/conda-recipes/azure.win.yml b/dev/tasks/conda-recipes/azure.win.yml
index f9f0ab5ca8..c2755c3dd4 100755
--- a/dev/tasks/conda-recipes/azure.win.yml
+++ b/dev/tasks/conda-recipes/azure.win.yml
@@ -102,6 +102,7 @@ jobs:
CROSSBOW_GITHUB_TOKEN: $(CROSSBOW_GITHUB_TOKEN)
displayName: Upload packages as a GitHub release
+ {% if arrow.branch == 'master' %}
# Upload to custom anaconda channel
- script: |
source activate base
@@ -109,3 +110,4 @@ jobs:
anaconda -t $(CROSSBOW_ANACONDA_TOKEN) upload -l nightly --force D:\bld\win-64\*.tar.bz2
displayName: Upload packages to Anaconda
workingDirectory: arrow/dev/tasks/conda-recipes
+ {% endif %}
diff --git a/dev/tasks/crossbow.py b/dev/tasks/crossbow.py
index ce61ece8ee..59cf782441 100755
--- a/dev/tasks/crossbow.py
+++ b/dev/tasks/crossbow.py
@@ -602,6 +602,7 @@ class Repo:
command = [
'curl',
+ '--fail',
'-H', "Authorization: token {}".format(self.github_token),
'-H', "Content-Type: {}".format(mime),
'--data-binary', '@{}'.format(path),
diff --git a/dev/tasks/python-wheels/appveyor.yml b/dev/tasks/python-wheels/appveyor.yml
index 6be2417241..c4e3d547bb 100644
--- a/dev/tasks/python-wheels/appveyor.yml
+++ b/dev/tasks/python-wheels/appveyor.yml
@@ -53,6 +53,12 @@ build_script:
after_build:
# the artifacts must be uploaded from a directory relative to the build root
- xcopy %ARROW_SRC%\python\dist\* wheels\
+{% if arrow.branch == 'master' %}
+ # upload to gemfury
+ - conda install -y curl
+ - for /f %%i in ('dir /b wheels\*.whl') do set WHEEL_PATH=wheels\%%i
+ - curl.exe -f -F "package=@%WHEEL_PATH%" "https://%CROSSBOW_GEMFURY_TOKEN%@push.fury.io/ursa-labs/"
+{% endif %}
#on_finish:
#- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1'))
diff --git a/dev/tasks/python-wheels/azure.linux.yml b/dev/tasks/python-wheels/azure.linux.yml
index 87510b8f30..6e37781330 100644
--- a/dev/tasks/python-wheels/azure.linux.yml
+++ b/dev/tasks/python-wheels/azure.linux.yml
@@ -90,3 +90,13 @@ jobs:
env:
CROSSBOW_GITHUB_TOKEN: $(CROSSBOW_GITHUB_TOKEN)
displayName: Upload packages as a GitHub release
+
+ {% if arrow.branch == 'master' %}
+ # upload to gemfury
+ - script: |
+ path=$(ls arrow/python/{{ wheel_dir }}/dist/*.whl)
+ curl -f -F "package=@${path}" https://${CROSSBOW_GEMFURY_TOKEN}@push.fury.io/ursa-labs/
+ env:
+ CROSSBOW_GEMFURY_TOKEN: $(CROSSBOW_GEMFURY_TOKEN)
+ displayName: Upload packages to Gemfury
+ {% endif %}
diff --git a/dev/tasks/python-wheels/travis.osx.yml b/dev/tasks/python-wheels/travis.osx.yml
index dab58d7bce..68b3e4952a 100644
--- a/dev/tasks/python-wheels/travis.osx.yml
+++ b/dev/tasks/python-wheels/travis.osx.yml
@@ -75,10 +75,23 @@ install:
- sudo mv $(brew --cellar){.bak,}
# before_install activates a virtualenv but we need the system python3
- deactivate
+
# crossbow dependencies for deployment
- unset MACOSX_DEPLOYMENT_TARGET
- pip3 install click ruamel.yaml setuptools_scm github3.py toolz requests[security]
- - python3 arrow/dev/tasks/crossbow.py --queue-path $(pwd) --queue-remote {{ queue.remote_url }} upload-artifacts --sha {{ task.branch }} --tag {{ task.tag }} --pattern "arrow/python/dist/*.whl"
+ - python3 arrow/dev/tasks/crossbow.py
+ --queue-path $(pwd)
+ --queue-remote {{ queue.remote_url }}
+ upload-artifacts
+ --sha {{ task.branch }}
+ --tag {{ task.tag }}
+ --pattern "arrow/python/dist/*.whl"
+
+ {% if arrow.branch == 'master' %}
+ # upload to gemfury pypi repository, there should be a single wheel
+ - path=$(ls arrow/python/dist/*.whl)
+ - curl -f -F "package=@${path}" https://${CROSSBOW_GEMFURY_TOKEN}@push.fury.io/ursa-labs/
+ {% endif %}
notifications:
email: