|
@ -18,7 +18,7 @@ on: |
|
|
- "proto/*" |
|
|
- "proto/*" |
|
|
schedule: |
|
|
schedule: |
|
|
# run this job once a month to recieve any go or buf updates |
|
|
# run this job once a month to recieve any go or buf updates |
|
|
- cron: "* * 1 * *" |
|
|
|
|
|
|
|
|
- cron: "0 9 1 * *" |
|
|
|
|
|
|
|
|
env: |
|
|
env: |
|
|
REGISTRY: ghcr.io |
|
|
REGISTRY: ghcr.io |
|
@ -34,16 +34,16 @@ jobs: |
|
|
run: | |
|
|
run: | |
|
|
DOCKER_IMAGE="${REGISTRY}/${IMAGE_NAME}" |
|
|
DOCKER_IMAGE="${REGISTRY}/${IMAGE_NAME}" |
|
|
VERSION=noop |
|
|
VERSION=noop |
|
|
if [[ $GITHUB_REF == refs/tags/* ]]; then |
|
|
|
|
|
VERSION=${GITHUB_REF#refs/tags/} |
|
|
|
|
|
elif [[ $GITHUB_REF == refs/heads/* ]]; then |
|
|
|
|
|
VERSION=$(echo ${GITHUB_REF#refs/heads/} | sed -r 's#/+#-#g') |
|
|
|
|
|
if [ "${{ github.event.repository.default_branch }}" = "$VERSION" ]; then |
|
|
|
|
|
|
|
|
if [[ "$GITHUB_REF" == "refs/tags/*" ]]; then |
|
|
|
|
|
VERSION="${GITHUB_REF#refs/tags/}" |
|
|
|
|
|
elif [[ "$GITHUB_REF" == "refs/heads/*" ]]; then |
|
|
|
|
|
VERSION="$(echo "${GITHUB_REF#refs/heads/}" | sed -r 's#/+#-#g')" |
|
|
|
|
|
if [[ "${{ github.event.repository.default_branch }}" = "$VERSION" ]]; then |
|
|
VERSION=latest |
|
|
VERSION=latest |
|
|
fi |
|
|
fi |
|
|
fi |
|
|
fi |
|
|
TAGS="${DOCKER_IMAGE}:${VERSION}" |
|
|
TAGS="${DOCKER_IMAGE}:${VERSION}" |
|
|
echo ::set-output name=tags::${TAGS} |
|
|
|
|
|
|
|
|
echo ::set-output name=tags::"${TAGS}" |
|
|
|
|
|
|
|
|
- name: Set up docker buildx |
|
|
- name: Set up docker buildx |
|
|
uses: docker/setup-buildx-action@v1.6.0 |
|
|
uses: docker/setup-buildx-action@v1.6.0 |
|
|