Debian Codegraph @

.github/workflows/release.yaml

raw
1 name: release
2 on:
3 push:
4 tags:
5 - 'v[0-9]+.[0-9]+.[0-9]+'
6 jobs:
7 release:
8 runs-on: ubuntu-latest
9 services:
10 postgres:
11 image: postgres:17
12 env:
13 POSTGRES_USER: ntfy
14 POSTGRES_PASSWORD: ntfy
15 POSTGRES_DB: ntfy_test
16 ports:
17 - 5432:5432
18 options: >-
19 --health-cmd "pg_isready -U ntfy"
20 --health-interval 10s
21 --health-timeout 5s
22 --health-retries 5
23 env:
24 NTFY_TEST_DATABASE_URL: "postgres://ntfy:ntfy@localhost:5432/ntfy_test?sslmode=disable"
25 NTFY_TEST_S3_URL: ${{ secrets.NTFY_TEST_S3_URL }}
26 steps:
27 - name: Checkout code
28 uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
29 - name: Install Go
30 uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
31 with:
32 go-version-file: '.go-version'
33 - name: Install node
34 uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
35 with:
36 node-version: '24'
37 cache: 'npm'
38 cache-dependency-path: './web/package-lock.json'
39 - name: Docker login
40 uses: docker/login-action@371161bbe7024a29a25c5e19bfcbc0804fe9ad2c # v4.5.2
41 with:
42 username: ${{ github.repository_owner }}
43 password: ${{ secrets.DOCKER_HUB_TOKEN }}
44 - name: Install dependencies
45 run: make build-deps-ubuntu
46 - name: Build and publish
47 run: make release
48 env:
49 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
50 - name: Print build results and checksums
51 run: make cli-build-results