ci: use curl for PyPI upload with SSL skip
[ray-serve only] Twine lacks SSL skip option, use curl -k for self-signed internal cert
This commit is contained in:
@@ -63,16 +63,19 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
TWINE_USERNAME: ${{ secrets.REGISTRY_USER }}
|
TWINE_USERNAME: ${{ secrets.REGISTRY_USER }}
|
||||||
TWINE_PASSWORD: ${{ secrets.REGISTRY_TOKEN }}
|
TWINE_PASSWORD: ${{ secrets.REGISTRY_TOKEN }}
|
||||||
# Disable SSL verification for internal self-signed cert
|
|
||||||
CURL_CA_BUNDLE: ""
|
|
||||||
run: |
|
run: |
|
||||||
cd ray-serve
|
cd ray-serve
|
||||||
# Use internal registry URL to bypass Cloudflare 100MB limit
|
# Use internal registry URL to bypass Cloudflare 100MB limit
|
||||||
# --disable-certificate-verification for self-signed internal cert
|
# curl with -k to skip SSL verification for self-signed cert
|
||||||
twine upload \
|
for file in dist/*.whl dist/*.tar.gz; do
|
||||||
--disable-certificate-verification \
|
if [ -f "$file" ]; then
|
||||||
--repository-url https://registry.lab.daviestechlabs.io/api/packages/daviestechlabs/pypi \
|
echo "Uploading $file..."
|
||||||
dist/*
|
curl -k --fail -X POST \
|
||||||
|
-u "$TWINE_USERNAME:$TWINE_PASSWORD" \
|
||||||
|
-F "content=@$file" \
|
||||||
|
"https://registry.lab.daviestechlabs.io/api/packages/daviestechlabs/pypi/upload"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
- name: Notify on success
|
- name: Notify on success
|
||||||
if: success()
|
if: success()
|
||||||
|
|||||||
Reference in New Issue
Block a user