3636 - name: Build Package
3737 run: python3 -m build
3838
39- - name: Publish Test Package
40- uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
41- with:
42- user: __token__
43- password: ${{ secrets.TEST_PYPI_API_TOKEN }}
44- repository_url: https://test.pypi.org/legacy/
45-
46- - name: Temporarily Store the Python Package in GitHub # for convenient reference, troubleshooting, investigation, etc...
47- uses: actions/upload-artifact@v2
48- with:
49- name: netfoundry-pypi-${{ github.run_id }}
50- path: dist/netfoundry-*.tar.gz
39+ - name: Install NetFoundry from build tarball
40+ run: |
41+ pip3 install ./dist/netfoundry-*.tar.gz
5142
5243 - name: Read version string
5344 id: read_version
@@ -59,15 +50,12 @@ jobs:
5950 }
6051 echo ::set-output name=pypi_version::${PYPI_VERSION}
6152
62- - name: Install NetFoundry from build tarball
63- run: |
64- pip3 install ./dist/netfoundry-*.tar.gz
65-
6653 - name: Compare installed version to PyPi version
6754 env:
6855 PYPI_VERSION: ${{ steps.read_version.outputs.pypi_version }}
6956 run: |
7057 INSTALLED_VERSION="$(python3 -m netfoundry.version)"
58+ echo "PYPI_VERSION=${PYPI_VERSION}, INSTALLED_VERSION=${INSTALLED_VERSION#v}"
7159 if ! [[ ${PYPI_VERSION} == ${INSTALLED_VERSION#v} ]]; then
7260 echo "ERROR: PyPi and installed version do not match." >&2
7361 exit 1
@@ -85,30 +73,38 @@ jobs:
8573 NETFOUNDRY_OAUTH_URL: ${{ secrets.NETFOUNDRY_OAUTH_URL }}
8674 run: |
8775 set -x
88- nfdemo \
89- --verbose \
90- --network ${NETWORK_NAME} \
91- --create-client \
92- --create-private \
93- --regions Americas \
94- -- create
95- nfctl \
96- --verbose \
97- --profile default \
98- --network ${NETWORK_NAME}
76+ nfctl config \
77+ general.network=${NETWORK_NAME} \
78+ general.yes=True \
79+ general.verbose=yes || true # workaround https://github.com/netfoundry/python-netfoundry/issues/29
80+ nfctl demo \
81+ --regions us-west-2 us-east-2 \
82+ --provider AWS
9983 nfctl \
100- --verbose \
101- --profile default \
102- --network ${NETWORK_NAME} \
10384 list services
10485 nfctl \
105- --verbose \
106- --profile default \
107- --network ${NETWORK_NAME} \
108- --yes \
86+ get service name=echo% > /tmp/echo.yml
87+ nfctl \
88+ delete service name=echo%
89+ nfctl \
90+ create service --file /tmp/echo.yml
91+ nfctl \
10992 delete network
11093
111- - name: Append 'latest' tag if release published
94+ - name: Publish Test Package
95+ uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29
96+ with:
97+ user: __token__
98+ password: ${{ secrets.TEST_PYPI_API_TOKEN }}
99+ repository_url: https://test.pypi.org/legacy/
100+
101+ - name: Temporarily Store the Python Package in GitHub # for convenient reference, troubleshooting, investigation, etc...
102+ uses: actions/upload-artifact@v2
103+ with:
104+ name: netfoundry-pypi-${{ github.run_id }}
105+ path: dist/netfoundry-*.tar.gz
106+
107+ - name: Append 'latest' tag if release
112108 env:
113109 GITHUB_EVENT_ACTION: ${{ github.event.action }}
114110 PYPI_VERSION: ${{ steps.read_version.outputs.pypi_version }}
0 commit comments