name: Release on: push: tags: - "v*" jobs: release: runs-on: ubuntu-latest permissions: contents: write packages: write steps: - name: Checkout repository uses: actions/checkout@v4 with: fetch-depth: 0 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 with: driver: docker-container cache-to: type=gha cache-from: type=gha - name: Log in to Docker Hub uses: docker/login-action@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_PASSWORD }} - name: Log in to GitHub Container Registry uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - name: Set up Go uses: actions/setup-go@v5 with: go-version: "1.25.0" cache: false - name: Restore Go build cache uses: actions/cache/restore@v4 with: path: | ~/.cache/go-build ~/go/pkg/mod key: release-go-${{ runner.os }}-${{ hashFiles('go.sum') }} restore-keys: release-go-${{ runner.os }}- - name: Set up Node.js uses: actions/setup-node@v3 with: node-version: "20" - name: Install pnpm run: npm install -g pnpm@9.15.3 - name: Run GoReleaser uses: goreleaser/goreleaser-action@v5 with: version: latest args: release --clean env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} DOCKER_ORG: libredesk GITHUB_ORG: ${{ github.repository_owner }}