2018-09-04 14:19:01 +02:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2018-09-04 16:17:35 +02:00
|
|
|
if [ -n "$DOCKER_USERNAME" ] && [ -n "$DOCKER_PASSWORD" ]; then
|
2018-09-04 14:19:01 +02:00
|
|
|
echo "Login to the docker..."
|
2018-12-10 17:45:01 +02:00
|
|
|
docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD $DOCKER_REGISTRY
|
2018-09-04 14:19:01 +02:00
|
|
|
fi
|
|
|
|
|
2019-03-14 14:13:12 +02:00
|
|
|
# Workaround for github actions when access to different repositories is needed.
|
|
|
|
# Github actions provides a GITHUB_TOKEN secret that can only access the current
|
|
|
|
# repository and you cannot configure it's value.
|
|
|
|
# Access to different repositories is needed by brew for example.
|
|
|
|
|
|
|
|
if [ -n "$GORELEASER_GITHUB_TOKEN" ] ; then
|
|
|
|
export GITHUB_TOKEN=$GORELEASER_GITHUB_TOKEN
|
|
|
|
fi
|
|
|
|
|
2018-09-04 14:19:01 +02:00
|
|
|
goreleaser $@
|