Skip to content

Update Teams service to support new webhook URL format with required extraId #460

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 180 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
180 commits
Select commit Hold shift + click to select a range
2213915
Add renovate.json
renovate[bot] Feb 24, 2025
90bdc61
Merge pull request #1 from nicholas-fedor/renovate/configure
nicholas-fedor Feb 24, 2025
8e6f4c6
fix(deps): update module github.com/mattn/go-colorable to v0.1.14
renovate[bot] Feb 24, 2025
d4e7b7c
Merge pull request #3 from nicholas-fedor/renovate/github.com-mattn-g…
nicholas-fedor Feb 24, 2025
8fd493f
fix(deps): update module github.com/jarcoal/httpmock to v1.3.1
renovate[bot] Feb 24, 2025
36d980e
Merge pull request #2 from nicholas-fedor/renovate/github.com-jarcoal…
nicholas-fedor Feb 24, 2025
956c72a
chore(deps): update alpine docker tag to v3.21.3
renovate[bot] Feb 24, 2025
1ca271d
fix(deps): update module github.com/fatih/color to v1.18.0
renovate[bot] Feb 24, 2025
27b60fa
fix(deps): update module golang.org/x/oauth2 to v0.26.0
renovate[bot] Feb 24, 2025
f293ebb
chore(deps): update azure/docker-login action to v2
renovate[bot] Feb 24, 2025
9d3bbcb
chore(deps): update codecov/codecov-action action to v5
renovate[bot] Feb 24, 2025
044ce88
chore(deps): update goreleaser/goreleaser-action action to v6
renovate[bot] Feb 24, 2025
3fb8f9c
Merge pull request #12 from nicholas-fedor/renovate/golang.org-x-oaut…
nicholas-fedor Feb 24, 2025
d429642
Merge pull request #15 from nicholas-fedor/renovate/goreleaser-gorele…
nicholas-fedor Feb 24, 2025
2b0b311
fix(deps): update module github.com/onsi/gomega to v1.36.2
renovate[bot] Feb 24, 2025
88dd2a7
Merge pull request #14 from nicholas-fedor/renovate/codecov-codecov-a…
nicholas-fedor Feb 24, 2025
d8995f2
Merge pull request #13 from nicholas-fedor/renovate/azure-docker-logi…
nicholas-fedor Feb 24, 2025
d62abb5
Merge pull request #5 from nicholas-fedor/renovate/alpine-3.x
nicholas-fedor Feb 24, 2025
0a36be9
Merge pull request #8 from nicholas-fedor/renovate/github.com-onsi-go…
nicholas-fedor Feb 24, 2025
e10a972
fix(deps): update module github.com/onsi/ginkgo/v2 to v2.22.2
renovate[bot] Feb 24, 2025
e1c568e
fix(deps): update module github.com/spf13/viper to v1.19.0
renovate[bot] Feb 24, 2025
93488c9
Merge pull request #10 from nicholas-fedor/renovate/github.com-spf13-…
nicholas-fedor Feb 24, 2025
126a54d
Merge pull request #6 from nicholas-fedor/renovate/github.com-fatih-c…
nicholas-fedor Feb 24, 2025
0a003cc
fix(deps): update module github.com/spf13/cobra to v1.9.1
renovate[bot] Feb 24, 2025
181ade6
Merge pull request #7 from nicholas-fedor/renovate/github.com-onsi-gi…
nicholas-fedor Feb 24, 2025
9b040cc
fix(deps): update module golang.org/x/net to v0.35.0
renovate[bot] Feb 24, 2025
a2d355c
Merge pull request #11 from nicholas-fedor/renovate/golang.org-x-net-0.x
nicholas-fedor Feb 24, 2025
0f91ac0
Merge pull request #9 from nicholas-fedor/renovate/github.com-spf13-c…
nicholas-fedor Feb 24, 2025
259c5fe
fix(deps): update module golang.org/x/oauth2 to v0.27.0
renovate[bot] Feb 24, 2025
8d49063
Update fork
nicholas-fedor Feb 25, 2025
b55899c
Merge pull request #16 from nicholas-fedor/renovate/golang.org-x-oaut…
nicholas-fedor Feb 25, 2025
42f72d7
Refactor GetServiceConfig to remove unsafe package usage
nicholas-fedor Feb 25, 2025
4808f85
Merge branch 'fork-update'
nicholas-fedor Feb 25, 2025
1c0a4fe
chore(deps): update codecov/codecov-action digest to 2488e99
renovate[bot] Feb 25, 2025
9960fd4
chore(deps): update golangci/golangci-lint-action digest to 7b561e5
renovate[bot] Feb 25, 2025
af05ba8
Update lint workflow to use golangci-lint default settings
nicholas-fedor Feb 25, 2025
36c82c4
Make lint workflow non-blocking for other jobs
nicholas-fedor Feb 25, 2025
8df6353
Update .goreleaser.yml to version 2 and confirm main path
nicholas-fedor Feb 25, 2025
900d597
Update LICENSE to markdown
nicholas-fedor Feb 25, 2025
8fdadac
Move Dockerfile to dockerfiles directory
nicholas-fedor Feb 25, 2025
cf4f34e
Update goreleaser.yml
nicholas-fedor Feb 25, 2025
d78b299
Update Build workflow: add QEMU and refine attestation subject-path t…
nicholas-fedor Feb 25, 2025
f3a9b2f
Revert path
nicholas-fedor Feb 25, 2025
2659b83
Merge pull request #19 from nicholas-fedor/renovate/golangci-golangci…
nicholas-fedor Feb 25, 2025
4b39e18
Merge pull request #18 from nicholas-fedor/renovate/codecov-codecov-a…
nicholas-fedor Feb 25, 2025
19ce7b8
Update docs.yaml to run after successful Release (Production) workflow
nicholas-fedor Feb 25, 2025
98eb5d5
Update docs.yaml to run after successful build job in Release (Produc…
nicholas-fedor Feb 25, 2025
61b148e
Add Docker pulls badge
nicholas-fedor Feb 25, 2025
a772a3f
Remove automatic deployment
nicholas-fedor Feb 25, 2025
cd2459a
Correct formatting
nicholas-fedor Feb 25, 2025
24c9269
Add Docker pulls
nicholas-fedor Feb 25, 2025
90b64e5
Add cache keys
nicholas-fedor Feb 25, 2025
53d47da
Revert to original formatting
nicholas-fedor Feb 25, 2025
a01ee70
Add missing script to build docs
nicholas-fedor Feb 25, 2025
216149a
Capitalize Config field in bark service to fix docs generation
nicholas-fedor Feb 25, 2025
226375c
Force clean Go build in Publish Docs workflow
nicholas-fedor Feb 25, 2025
8539637
Initialize services in docs.go with proper logger to fix Config panic
nicholas-fedor Feb 25, 2025
c80be03
Capitalize Config field in discord service to fix docs generation panic
nicholas-fedor Feb 25, 2025
cb5f054
Export configs to enable docs build
nicholas-fedor Feb 25, 2025
b486ead
Add dummy@dummy.com in the setURL method to bypass validation checks …
nicholas-fedor Feb 25, 2025
17302ca
Fix join SetURL to fully bypass validation for join://dummy@dummy.com…
nicholas-fedor Feb 25, 2025
c4bf492
Fix matrix Initialize to skip login for matrix://dummy@dummy.com in d…
nicholas-fedor Feb 25, 2025
c05cb7a
Fix opsgenie SetURL to handle empty path for opsgenie://dummy@dummy.c…
nicholas-fedor Feb 25, 2025
e8a17b9
Prevent Matrix client init and server calls for matrix://dummy@dummy.…
nicholas-fedor Feb 25, 2025
52146b3
Fix pushover SetURL and GetURL to use pointer receiver for ConfigQuer…
nicholas-fedor Feb 25, 2025
b35b641
Reapply zulip SetURL exemption for zulip://dummy@dummy.com in docs wo…
nicholas-fedor Feb 25, 2025
cb49103
Update codecov/codecov-action digest to 0565863
renovate[bot] Feb 27, 2025
9a742d4
Merge pull request #20 from nicholas-fedor/renovate/codecov-codecov-a…
nicholas-fedor Feb 27, 2025
64aa756
Update .golangci.yaml
nicholas-fedor Feb 27, 2025
301867b
Replace numbers with defined constants
nicholas-fedor Feb 27, 2025
4dcd5a6
Update imports
nicholas-fedor Feb 27, 2025
4a5b06c
Fix - Replace package path reflection logic with service.GetID() method
nicholas-fedor Feb 27, 2025
cb7751d
Replace magic numbers with named constants
nicholas-fedor Feb 27, 2025
4acd63a
Replace magic numbers with constants
nicholas-fedor Feb 27, 2025
646f9c2
Replace repeated JSON string with constant
nicholas-fedor Feb 27, 2025
b86392f
Enhance generic service config and tests with fixes and constants
nicholas-fedor Feb 27, 2025
8fa18e5
feat(gotify): address linter warnings by introducing constants
nicholas-fedor Feb 27, 2025
8f6cb9d
Replace magic number 2 with DefaultMessageValue constant in Initialize
nicholas-fedor Feb 27, 2025
5adc48e
(lint) Add newline between assignments
nicholas-fedor Feb 27, 2025
d6f5f14
Replace magic numbers in createJSONToSend with named constants
nicholas-fedor Feb 27, 2025
2317c42
(lint) add newline between assignments
nicholas-fedor Feb 27, 2025
b8f778e
Use net.JoinHostPort for host:port construction in opsgenie tests
nicholas-fedor Feb 27, 2025
5cff84f
(lint) remove duplicate test
nicholas-fedor Feb 27, 2025
ea69c2d
fix: Replace magic number 34 with constant in Pushbullet token valida…
nicholas-fedor Feb 27, 2025
7d9879c
Replace magic numbers with named constants
nicholas-fedor Feb 27, 2025
6c41586
refactor: Remove dot imports and add TestWebhookURL constant
nicholas-fedor Feb 27, 2025
852461d
fix: Replace magic numbers with named constants in SMTP auth and encr…
nicholas-fedor Feb 27, 2025
3a7671e
fix: Replace magic numbers in telegram package with named constants
nicholas-fedor Feb 27, 2025
366d57b
Migrate use of ...interface{} to ...any
nicholas-fedor Feb 27, 2025
eceebeb
(lint) rename function
nicholas-fedor Feb 27, 2025
1ce0fe6
Add gochecknoinits to excluded linters
nicholas-fedor Feb 27, 2025
f66c69f
(fix) Add const MaximumNArgs to remain constant with maximum flags
nicholas-fedor Feb 27, 2025
bc0c9d9
(fix) Replace magic number with const MaxMessageLength
nicholas-fedor Feb 27, 2025
0078359
fix: Replace magic number 9 with MaxEmbeds constant in discord payloa…
nicholas-fedor Feb 27, 2025
7918f14
(lint) Add newline between cuddled assignments
nicholas-fedor Feb 27, 2025
488bca9
Use net.JoinHostPort for host:port construction in rocketchat service
nicholas-fedor Feb 27, 2025
c9e8cf9
feat: Add failures package with tests and idiomatic refinements
nicholas-fedor Feb 27, 2025
1cc6d8d
(fix) Improve testing structure
nicholas-fedor Feb 27, 2025
ed80354
(fix) add additional test coverage
nicholas-fedor Feb 28, 2025
3811824
Add full test coverage to rocketchat package
nicholas-fedor Feb 28, 2025
6555c2d
Add test coverage for GetID method
nicholas-fedor Feb 28, 2025
ba9cf03
Add test coverage for GetID method
nicholas-fedor Feb 28, 2025
8b4af1c
Add minimum TLS version
nicholas-fedor Feb 28, 2025
89cd2bf
Merge pull request #21 from nicholas-fedor/fix-linter-issues
nicholas-fedor Feb 28, 2025
4f17a74
chore(deps): update golangci/golangci-lint-action digest to 37d62ae
renovate[bot] Mar 3, 2025
3475ebf
Merge pull request #22 from nicholas-fedor/renovate/golangci-golangci…
nicholas-fedor Mar 4, 2025
585e299
fix(deps): update module golang.org/x/net to v0.36.0
renovate[bot] Mar 4, 2025
2201263
chore(deps): update actions/setup-python digest to 9e62be8
renovate[bot] Mar 5, 2025
6689bf0
Merge pull request #24 from nicholas-fedor/renovate/actions-setup-pyt…
nicholas-fedor Mar 5, 2025
c7b8dc4
Merge pull request #23 from nicholas-fedor/renovate/golang.org-x-net-0.x
nicholas-fedor Mar 5, 2025
3d107a6
fix(deps): update module golang.org/x/oauth2 to v0.28.0
renovate[bot] Mar 5, 2025
dc0209f
fix(deps): update module github.com/onsi/ginkgo/v2 to v2.23.0
renovate[bot] Mar 6, 2025
6cafd8e
Merge pull request #27 from nicholas-fedor/renovate/github.com-onsi-g…
nicholas-fedor Mar 6, 2025
4d9ca5a
Merge pull request #25 from nicholas-fedor/renovate/golang.org-x-oaut…
nicholas-fedor Mar 6, 2025
45f7fdb
fix(deps): update module golang.org/x/net to v0.37.0
renovate[bot] Mar 6, 2025
fdb05f1
Merge pull request #26 from nicholas-fedor/renovate/golang.org-x-net-0.x
nicholas-fedor Mar 6, 2025
8dd86a6
chore(deps): update golangci/golangci-lint-action digest to d8648ac
renovate[bot] Mar 6, 2025
9f43028
chore(deps): update cimg/go docker tag to v1.24.1
renovate[bot] Mar 6, 2025
4209ffa
Merge pull request #29 from nicholas-fedor/renovate/cimg-go-1.x
nicholas-fedor Mar 7, 2025
fff7fc2
Merge pull request #28 from nicholas-fedor/renovate/golangci-golangci…
nicholas-fedor Mar 7, 2025
69997f1
chore(deps): update golangci/golangci-lint-action digest to b871b4f
renovate[bot] Mar 10, 2025
19a39ac
Merge pull request #30 from nicholas-fedor/renovate/golangci-golangci…
nicholas-fedor Mar 10, 2025
7459476
chore(deps): update codecov/codecov-action digest to cd4e7cf
renovate[bot] Mar 10, 2025
649b593
Merge pull request #31 from nicholas-fedor/renovate/codecov-codecov-a…
nicholas-fedor Mar 11, 2025
31aaa5d
chore(deps): update actions/setup-go digest to c4c1141
renovate[bot] Mar 11, 2025
7d116b5
chore(deps): update codecov/codecov-action digest to 3440e5e
renovate[bot] Mar 11, 2025
fba3e1f
Merge pull request #33 from nicholas-fedor/renovate/codecov-codecov-a…
nicholas-fedor Mar 11, 2025
c8a37b2
Merge pull request #32 from nicholas-fedor/renovate/actions-setup-go-…
nicholas-fedor Mar 11, 2025
e0f35b5
chore(deps): update dependency go to v1.24.1
renovate[bot] Mar 11, 2025
75e8604
Merge pull request #34 from nicholas-fedor/renovate/go-1.x
nicholas-fedor Mar 11, 2025
cb92e9b
feat(renovate): add support for github actions digests
nicholas-fedor Mar 12, 2025
f417bc7
fix(renovate): correct helper name
nicholas-fedor Mar 12, 2025
ef1085b
chore(deps): pin dependencies
renovate[bot] Mar 12, 2025
6541b52
Merge pull request #36 from nicholas-fedor/renovate/pin-dependencies
nicholas-fedor Mar 12, 2025
14d4766
chore(renovate): update to use config:best-practices
nicholas-fedor Mar 12, 2025
74ddc1d
chore(deps): pin dependencies
renovate[bot] Mar 12, 2025
84ce2f8
Merge pull request #37 from nicholas-fedor/renovate/pin-dependencies
nicholas-fedor Mar 12, 2025
48d6513
chore(deps): update golangci/golangci-lint-action digest to 4696ba8
renovate[bot] Mar 12, 2025
19cd3a8
chore(deps): update actions/setup-python digest to 6fd11e1
renovate[bot] Mar 12, 2025
6d68c02
Merge pull request #39 from nicholas-fedor/renovate/actions-setup-pyt…
nicholas-fedor Mar 13, 2025
08915b1
Merge pull request #38 from nicholas-fedor/renovate/golangci-golangci…
nicholas-fedor Mar 13, 2025
0fbfc0a
chore(deps): update actions/setup-python digest to 19e4675
renovate[bot] Mar 13, 2025
a414c41
Merge pull request #40 from nicholas-fedor/renovate/actions-setup-pyt…
nicholas-fedor Mar 13, 2025
205dfc5
chore(deps): update nicholas-fedor/go-proxy-pull-action digest to 96d…
renovate[bot] Mar 14, 2025
ad54a24
Merge pull request #41 from nicholas-fedor/renovate/nicholas-fedor-go…
nicholas-fedor Mar 14, 2025
4ef6574
chore(deps): update docker/login-action digest to 74a5d14
renovate[bot] Mar 14, 2025
324f2f9
Merge pull request #42 from nicholas-fedor/renovate/docker-login-acti…
nicholas-fedor Mar 14, 2025
c7775f7
fix(deps): update module github.com/spf13/viper to v1.20.0
renovate[bot] Mar 15, 2025
38bd2c2
Merge pull request #43 from nicholas-fedor/renovate/github.com-spf13-…
nicholas-fedor Mar 15, 2025
25c92e4
feat(generate): add sensitive data masking with --show-sensitive flag…
nicholas-fedor Mar 18, 2025
d4f519a
ci: add read-only permissions to Lint and Test workflows (#48)
nicholas-fedor Mar 18, 2025
88d9fc8
chore(deps): update golangci/golangci-lint-action digest to 55c2c14 (…
renovate[bot] Mar 18, 2025
b77a4c1
fix(verify): sanitize error output to prevent sensitive data exposure…
nicholas-fedor Mar 18, 2025
4b33394
chore(deps): update actions/setup-go digest to 0aaccfd (#51)
renovate[bot] Mar 18, 2025
bdf7fde
feat(mattermost): add DisableTLS and port preservation with fixes and…
nicholas-fedor Mar 19, 2025
72cff3c
chore(deps): update golangci/golangci-lint-action digest to b91d580 (…
renovate[bot] Mar 19, 2025
7bfe0ab
chore(deps): update golangci/golangci-lint-action digest to 9938e10 (…
renovate[bot] Mar 19, 2025
13e9664
chore(deps): update actions/cache digest to 5a3ec84 (#55)
renovate[bot] Mar 19, 2025
00f9d06
fix(deps): update module github.com/onsi/ginkgo/v2 to v2.23.1 (#56)
renovate[bot] Mar 19, 2025
1c57bb0
fix(teams): update webhook URL format and configuration details
Mar 20, 2025
a0e6b4d
docs(teams): clarify webhook URL format and required components
Mar 20, 2025
4def9f6
fix(deps): update module github.com/onsi/ginkgo/v2 to v2.23.2 (#57)
renovate[bot] Mar 20, 2025
a1228a3
fix(deps): update module github.com/onsi/ginkgo/v2 to v2.23.3 (#58)
renovate[bot] Mar 22, 2025
95e5524
fix(deps): update module github.com/onsi/gomega to v1.36.3 (#59)
renovate[bot] Mar 22, 2025
bd09a7b
Add renovate.json
renovate[bot] Mar 24, 2025
658b7c6
Merge pull request #1 from beatkind/renovate/configure
beatkind Mar 24, 2025
9a62fba
fix(golangci-lint): remove version tag (#64)
nicholas-fedor Mar 25, 2025
2010966
chore(deps): update actions/setup-python digest to 8d9ed9a (#60)
renovate[bot] Mar 25, 2025
27aeadb
chore(deps): update codecov/codecov-action digest to ea99328 (#63)
renovate[bot] Mar 25, 2025
0ac6d5f
chore(ci): update golangci-lint config to v2 (#65)
nicholas-fedor Mar 25, 2025
9fd8ef1
chore(deps): update golangci/golangci-lint-action digest to dec74fa (…
renovate[bot] Mar 25, 2025
c79965d
Merge remote-tracking branch 'nicholas-fedor/main'
Mar 25, 2025
61e9680
feat(teams): update Teams service for new webhook format and refactor
nicholas-fedor Mar 26, 2025
ac152d2
Merge pull request #1 from nicholas-fedor/feat/teams-service-update
serverleader Mar 26, 2025
e9a2f1b
fix(deps): update module github.com/spf13/viper to v1.20.1 (#67)
renovate[bot] Mar 26, 2025
99c8b1a
refactor: reduce cyclomatic complexity in teams package
nicholas-fedor Mar 26, 2025
6d1a074
Merge pull request #2 from nicholas-fedor/feat/teams-service-update
serverleader Mar 27, 2025
a110de4
ci(lint): temp disable linting on pr (#68)
nicholas-fedor Mar 27, 2025
37bec2e
Merge branch 'main' into main
nicholas-fedor Mar 27, 2025
271918f
Merge branch 'main' into main
beatkind Mar 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@
"imageSize": 100,
"commit": false,
"contributors": [
{
"login": "nicholas-fedor",
"name": "Nicholas Fedor",
"avatar_url": "https://avatars2.githubusercontent.com/u/71477161?v=4",
"profile": "https://github.com/nicholas-fedor",
"contributions": [
"code",
"doc",
"maintenance",
"review"
]
},
{
"login": "amirschnell",
"name": "Amir Schnell",
Expand Down Expand Up @@ -142,7 +154,7 @@
],
"contributorsPerLine": 7,
"projectName": "shoutrrr",
"projectOwner": "containrrr",
"projectOwner": "nicholas-fedor",
"repoType": "github",
"repoHost": "https://github.com",
"skipCi": true
Expand Down
48 changes: 48 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/configuration-reference

# For a detailed guide to building and testing with Go, read the docs:
# https://circleci.com/docs/language-go/ for more details
version: 2.1

# Define a job to be invoked later in a workflow.
# See: https://circleci.com/docs/jobs-steps/#jobs-overview & https://circleci.com/docs/configuration-reference/#jobs
jobs:
build:
# Specify the execution environment. You can specify an image from Docker Hub or use one of our convenience images from CircleCI's Developer Hub.
# See: https://circleci.com/docs/executor-intro/ & https://circleci.com/docs/configuration-reference/#executor-job
docker:
# Specify the version you desire here
# See: https://circleci.com/developer/images/image/cimg/go
- image: cimg/go:1.24.1@sha256:b5861b5d22f1b2077f978196de5222ed6651dec36cac67c0e6bbf117b3067954

# Add steps to the job
# See: https://circleci.com/docs/jobs-steps/#steps-overview & https://circleci.com/docs/configuration-reference/#steps
steps:
# Checkout the code as the first step.
- checkout
- restore_cache:
keys:
- go-mod-v4-{{ checksum "go.sum" }}
- run:
name: Install Dependencies
command: go mod download
- save_cache:
key: go-mod-v4-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"
- run:
name: Run tests
command: |
mkdir -p /tmp/test-reports
gotestsum --junitfile /tmp/test-reports/unit-tests.xml
- store_test_results:
path: /tmp/test-reports

# Orchestrate jobs using workflows
# See: https://circleci.com/docs/workflows/ & https://circleci.com/docs/configuration-reference/#workflows
workflows:
build-test: # This is the name of the workflow, feel free to change it to better match your workflow.
# Inside the workflow, you define the jobs you want to run.
jobs:
- build
6 changes: 6 additions & 0 deletions .codacy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
engines:
coverage:
exclude_paths:
- "*.md"
- "**/*.md"
14 changes: 0 additions & 14 deletions .github/dependabot.yml

This file was deleted.

66 changes: 66 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Build

on:
workflow_call:
inputs:
snapshot:
description: "Whether to run in snapshot mode"
required: false
type: boolean
default: false

jobs:
build:
name: Build
runs-on: ubuntu-latest
permissions:
packages: write
contents: write
attestations: write
id-token: write
env:
CGO_ENABLED: 0
TAG: ${{ github.ref_name }}
steps:
- name: Checkout
uses: actions/checkout@85e6279cec87321a52edac9c87bce653a07cf6c2
with:
fetch-depth: 0

- name: Set up QEMU
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392 # v3
with:
platforms: linux/amd64,linux/arm64,linux/386,linux/arm/v6

- name: Set up Go
uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b
with:
go-version: 1.24.1

- name: Login to Docker Hub
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Login to GHCR
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@90a3faa9d0182683851fbfa97ca1a2cb983bfca3
with:
distribution: goreleaser
version: v2.7.0
args: release --clean ${{ inputs.snapshot && '--snapshot' || '' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Generate artifact attestation
uses: actions/attest-build-provenance@c074443f1aee8d4aeeae555aebba3282517141b2 # v2
if: success()
with:
subject-path: "dist/**/*"
32 changes: 32 additions & 0 deletions .github/workflows/clean-cache.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Cache cleanup
on:
workflow_dispatch: {}
pull_request:
types:
- closed

permissions:
actions: write
contents: read

jobs:
cleanup:
runs-on: ubuntu-latest
steps:
- name: Cleanup
run: |
echo "Fetching list of cache key"
cacheKeysForPR=$(gh cache list --ref $BRANCH --limit 100 --json id --jq '.[].id')

## Setting this to not fail the workflow while deleting cache keys.
set +e
echo "Deleting caches..."
for cacheKey in $cacheKeysForPR
do
gh cache delete $cacheKey
done
echo "Done"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
BRANCH: refs/pull/${{ github.event.pull_request.number }}/merge
56 changes: 56 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Publish Docs

on:
workflow_dispatch: {}

permissions:
contents: write
actions: read

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@85e6279cec87321a52edac9c87bce653a07cf6c2

- name: Configure Git Credentials
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com

- name: Setup Go
uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b
with:
go-version: "1.24"

- name: Generate Service Config Docs
run: |
go mod download
go clean -cache # Clear build cache
./generate-service-config-docs.sh

- name: Setup Python
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55
with:
python-version: "3.13.2"
cache: "pip"
cache-dependency-path: |
docs-requirements.txt

- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV

- uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache

restore-keys: |
mkdocs-material-

- name: Install mkdocs
run: |
pip install -r docs-requirements.txt

- name: Build and Deploy
run: mkdocs gh-deploy --force --verbose
66 changes: 0 additions & 66 deletions .github/workflows/docs.yml

This file was deleted.

36 changes: 36 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Lint

on:
workflow_call:

permissions:
contents: read

jobs:
lint:
name: Run Linter
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@85e6279cec87321a52edac9c87bce653a07cf6c2

- name: Set up Go
uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b
with:
go-version: "1.24.1"

- name: Install dependencies
run: go mod download

- name: Run golangci-lint
uses: golangci/golangci-lint-action@dec74fa03096ff515422f71d18d41307cacde373
with:
args: --timeout=5m --config= # Use default linter settings

- name: Format Go code
run: |
go fmt ./...

- name: Check for uncommitted changes after formatting
run: |
git diff --exit-code || (echo "Detected unformatted files. Run 'go fmt' to format your code."; exit 1)
Loading