ci: publish site deployment to netlify as well

This commit is contained in:
鲁树人 2024-01-18 00:29:37 +00:00
parent f09aa84984
commit 741e302ea7
2 changed files with 5 additions and 3 deletions

View File

@ -27,7 +27,9 @@ steps:
NETLIFY_API_KEY:
from_secret: NETLIFY_API_KEY
commands:
# - git config --global --add safe.directory "/drone/src"
- python3 -m zipfile -c um-react.zip dist/.
- |
python3 -m zipfile -c um-react.zip dist/.
cp um-react.zip dist/release-"${DRONE_COMMIT_SHA}".zip
python3 -m zipfile -c um-react-site.zip dist/.
# - ./scripts/publish.sh
- ./scripts/deploy.sh

View File

@ -104,7 +104,7 @@ deploy_netlify() {
# For deployment, we care a bit less
if [[ -n "${NETLIFY_API_KEY}" && -n "${NETLIFY_SITE_ID}" ]]; then
echo "Deploy to netlify..."
deploy_netlify um-react.zip
deploy_netlify um-react-site.zip
else
echo "skip netlify deployment."
fi