ci(frontend-2): docker image should not be built if github token is not set (#1687)
This commit is contained in:
Родитель
2d0d4b3d9a
Коммит
f0c73012e9
|
@ -64,6 +64,7 @@ workflows:
|
|||
- get-version
|
||||
|
||||
- docker-build-frontend-2:
|
||||
context: *build-context
|
||||
filters: *filters-build
|
||||
requires:
|
||||
- get-version
|
||||
|
|
|
@ -4,10 +4,15 @@
|
|||
|
||||
set -euf -o pipefail
|
||||
|
||||
if [[ -z "$CIRCLE_PULL_REQUEST" ]]; then
|
||||
if [[ -z "${CIRCLE_PULL_REQUEST}" ]]; then
|
||||
echo "FALSE"
|
||||
fi
|
||||
|
||||
if [[ -z "${GITHUB_TOKEN}" ]]; then
|
||||
echo "GITHUB_TOKEN is not set"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
PR_NUMBER="${CIRCLE_PULL_REQUEST//[!0-9]/}"
|
||||
RESPONSE=$(curl --silent \
|
||||
-H "Authorization: token ${GITHUB_TOKEN}" \
|
||||
|
|
Загрузка…
Ссылка в новой задаче