handle a missing file better in sample client #293
Workflow file for this run
This file contains 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
name: build wheels | |
on: | |
push: | |
pull_request: | |
jobs: | |
build_wheels: | |
strategy: | |
fail-fast: false | |
matrix: | |
spec: | |
- { name: 'linux x86_64', runner: ubuntu-20.04, target: manylinux_2_27_x86_64 } | |
- { name: 'macOS x86_64', runner: macos-11, target: macosx_10_14_x86_64 } | |
- { name: 'Windows x86_64', runner: windows-2019, target: win_amd64 } | |
name: building ${{ matrix.spec.name }} | |
runs-on: ${{ matrix.spec.runner }} | |
env: | |
HAVE_TEST_ID: ${{ secrets.ZITI_TEST_IDENTITY != '' }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python | |
uses: actions/setup-python@v3 | |
with: | |
python-version: '3.x' | |
- name: Install Python Tools | |
run: python -m pip install -U pip setuptools | |
- name: Run Integration Tests | |
if: ${{ env.HAVE_TEST_ID == 'true' }} | |
env: | |
ZITI_TEST_IDENTITY: ${{ secrets.ZITI_TEST_IDENTITY }} | |
ZITI_IDENTITIES: id.json | |
shell: bash | |
run: | | |
echo "${ZITI_TEST_IDENTITY}" > "${ZITI_IDENTITIES}" | |
ls | |
pip install -r tests/requirements.txt | |
pip install . | |
python -m unittest tests/ziti_tests.py | |
- name: Build distro | |
run: | | |
python setup.py sdist | |
- uses: actions/upload-artifact@v3 | |
if: startsWith(matrix.spec.name, 'linux') | |
with: | |
name: openziiti-sdist | |
path: ./dist/* | |
publish: | |
runs-on: ubuntu-20.04 | |
needs: [ build_wheels ] | |
steps: | |
- name: Download artifacts | |
uses: actions/download-artifact@v3 | |
with: | |
path: download | |
- name: check | |
run: | | |
ls -lR download | |
mkdir dist | |
cp download/*/* dist | |
- name: Publish wheels (TestPYPI) | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
with: | |
user: __token__ | |
password: ${{ secrets.TEST_PYPI_API_TOKEN }} | |
repository_url: https://test.pypi.org/legacy/ | |
packages_dir: dist | |
skip_existing: true | |
verbose: true | |
- name: Publish wheels (PyPI) | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
with: | |
user: __token__ | |
password: ${{ secrets.PYPI_API_TOKEN }} | |
packages_dir: dist | |
verbose: true |