Skip to content

Commit

Permalink
NXPY-259: Deploy artifacts to packages.nuxeo.com (#312)
Browse files Browse the repository at this point in the history
* Release fix: Upload nuxeo-python-client to packages
  • Loading branch information
swetayadav1 authored May 2, 2024
1 parent cebf0c6 commit 36d82c7
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 9 deletions.
25 changes: 16 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ jobs:
python-version: 3.9
- run: python -m pip install -U pip setuptools wheel
- run: python setup.py bdist_wheel
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: python-package-distributions
name: python-package-distributions-wheel
path: ./dist/*.whl

source-distribution:
Expand All @@ -37,9 +37,9 @@ jobs:
with:
python-version: 3.9
- run: python setup.py sdist
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
name: python-package-distributions
name: python-package-distributions-source
path: dist

publish:
Expand All @@ -48,13 +48,20 @@ jobs:
- source-distribution
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
name: python-package-distributions
pattern: python-package-distributions-*
path: dist/
merge-multiple: true
- run: ls -l dist
- uses: pypa/gh-action-pypi-publish@release/v1

- name: Upload Python Client on PyPi API Packages
uses: pypa/gh-action-pypi-publish@release/v1
env:
PYPI_API_REPO_URL: ${{ github.ref == 'refs/heads/master' && 'public' || 'private' }}
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
repository-url: "https://packages.nuxeo.com/repository/pypi-${{ env.PYPI_API_REPO_URL }}/"
user: ${{ secrets.PYPI_API_NUXEO_PACKAGE_USERNAME }}
password: ${{ secrets.PYPI_API_NUXEO_PACKAGE_TOKEN }}
skip_existing: true
verbose: true
3 changes: 3 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Release date: ``2024-04-18``
- `NXPY-255 <https://jira.nuxeo.com/browse/NXPY-255>`__: Fix Test cases for moto3
- `NXPY-256 <https://jira.nuxeo.com/browse/NXPY-256>`__: Upgrade from Node 16 to 20
- `NXPY-258 <https://jira.nuxeo.com/browse/NXPY-258>`__: File download from aws S3 with auto-redirect not working in case of OAuth
- `NXPY-259 <https://jira.nuxeo.com/browse/NXPY-259>`__: Deploy artifacts to packages.nuxeo.com

Technical changes
-----------------
Expand All @@ -23,6 +24,8 @@ Minor changes
-----------------

- Upgraded `actions/checkout` from 3 to 4
- Upgraded `actions/download-artifact` from 3 to 4
- Upgraded `actions/upload-artifact` from 3 to 4
- Upgraded `actions/setup-python` from 4 to 5
- Upgraded `codecov/codecov-action` from 3.1.2 to 3.1.5
- Upgraded `pypa/gh-action-pypi-publish` from master to release/v1
Expand Down

0 comments on commit 36d82c7

Please sign in to comment.