Repository navigation
chore(ci): Replace Travis with Github Actions #652
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,38 @@ | ||
| name: Kazoo Awesome Release | ||
|
|
||
| on: [push] | ||
|
|
||
| jobs: | ||
| build-and-release: | ||
| name: Build and release Kazoo to Pypi | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Handle the code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Set up Python 3.9 | ||
| uses: actions/setup-python@v2 | ||
| with: | ||
| python-version: 3.9 | ||
|
|
||
| - name: Install pypa/build | ||
| run: >- | ||
| python -m | ||
| pip install | ||
| build | ||
| --user | ||
|
|
||
| - name: Build a binary wheel and a source tarball | ||
| run: >- | ||
| python -m | ||
| build | ||
| --sdist | ||
| --wheel | ||
| --outdir dist/ | ||
| . | ||
|
|
||
| - name: Publish Kazoo to PyPI | ||
| if: startsWith(github.ref, 'refs/tags') | ||
| uses: pypa/gh-action-pypi-publish@master | ||
| with: | ||
| password: ${{ secrets.PYPI_API_TOKEN }} | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,68 @@ | ||
| name: Kazoo Awesome Testing | ||
|
|
||
| on: [push] | ||
|
|
||
| jobs: | ||
| test: | ||
| name: > | ||
| Test Python ${{ matrix.python-version }}, | ||
| ZK ${{ matrix.zk-version }} | ||
|
|
||
| runs-on: ubuntu-latest | ||
|
|
||
| strategy: | ||
| matrix: | ||
| python-version: [3.7, 3.8, 3.9, pypy-3.7] | ||
| zk-version: [3.4.14, 3.5.8] | ||
| include: | ||
| - python-version: 3.7 | ||
| tox-env: py37 | ||
| - python-version: 3.8 | ||
| tox-env: py38 | ||
| - python-version: 3.9 | ||
| tox-env: py39 | ||
| - python-version: pypy-3.7 | ||
| tox-env: pypy3 | ||
| steps: | ||
| - name: Handle the code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Set up Python ${{ matrix.python-version }} | ||
| uses: actions/setup-python@v2 | ||
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
|
|
||
| - name: Handle pip cache | ||
| uses: actions/cache@v2 | ||
| with: | ||
| path: ~/.cache/pip | ||
| key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements*.txt') }} | ||
| restore-keys: | | ||
| ${{ runner.os }}-pip- | ||
|
|
||
| - name: Handle ZK installation cache | ||
| uses: actions/cache@v2 | ||
| with: | ||
| path: zookeeper | ||
| key: ${{ runner.os }}-zookeeper | ||
| restore-keys: | | ||
| ${{ runner.os }}-zookeeper | ||
|
|
||
| - name: Install required dependencies | ||
| run: | | ||
| sudo apt-get -y install libevent-dev krb5-kdc krb5-admin-server libkrb5-dev | ||
| python -m pip install --upgrade pip | ||
| pip install tox | ||
|
|
||
| - name: Test with tox | ||
| run: tox -e ${TOX_VENV} | ||
| env: | ||
| TOX_VENV: ${{ format('{0}-{1}', matrix.tox-env, 'gevent-eventlet-sasl,codecov') }} | ||
| ZOOKEEPER_VERSION: ${{ matrix.zk-version }} | ||
| # TODO: can be removed once tests for ZK 3.4 are removed | ||
| ZOOKEEPER_PREFIX: "${{ !contains(matrix.zk-version, '3.4') && 'apache-' || '' }}" | ||
| ZOOKEEPER_SUFFIX: "${{ !contains(matrix.zk-version, '3.4') && '-bin' || '' }}" | ||
| ZOOKEEPER_LIB: "${{ !contains(matrix.zk-version, '3.4') && 'lib' || '' }}" | ||
|
|
||
| - name: Publish Codecov report | ||
| uses: codecov/codecov-action@v2 |
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bbangert I, unfortunately, don't have any access to the account used to publish to Pypi. Can you please add a secret called
PYPI_API_TOKENso that the CI will use to publish future versions of Kazoo? (here the documentation if needed)