Merge pull request #67 from digitalocean/dkomsa/prepare-release #14
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: release | |
on: | |
push: | |
tags: | |
- v** | |
env: | |
GITHUB_ENV: ".env" | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install go | |
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2 | |
with: | |
go-version: ^1.23 | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
- name: Validate that the release manifest exists | |
run: | | |
[[ -f "releases/do-operator-$(git describe --tags).yaml" ]] || false | |
- name: Login to dockerhub to push the image | |
run: echo "${{ secrets.DockerHubToken }}" | docker login --username ${DOCKER_USER} --password-stdin | |
env: | |
DOCKER_USER: ${{ secrets.DockerHubUser }} | |
- name: Build and push docker image | |
run: | | |
make docker-build docker-push IMG_TAG="$(git describe --tags)" |