use fallback instead of failing

This commit is contained in:
Nicolai Ort 2023-05-10 19:37:18 +02:00
parent 39d1286800
commit 79f2a6cb62
Signed by: niggl
GPG Key ID: 13AFA55AF62F269F

View File

@ -15,9 +15,12 @@ if [[ "${PLUGIN_GITEA_DOMAIN:-}" == "true" ]]; then
echo "No api key provided";
exit 1;
fi
if [[ -n "${PLUGIN_REPO:-}"]]; then
PLUGIN_REPO=$CI_REPO_NAME
fi
curl --request POST \
--url "https://$PLUGIN_GITEA_DOMAIN/api/v1/repos/$CI_REPO_NAME/releases" \
--url "https://$PLUGIN_GITEA_DOMAIN/api/v1/repos/$PLUGIN_REPO/releases" \
--header "Content-Type: application/json" \
--header "Authorization: token $PLUGIN_GITEA_APIKEY" \
--data "{