The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
grafana/.github/workflows/pr-go-workspace-check.yml

47 lines
1.2 KiB

name: "Go Workspace Check"
on:
workflow_dispatch:
pull_request:
branches: [main]
paths:
- .github/workflows/pr-go-workspace-check.yml
- go.mod
- go.sum
- go.work
- go.work.sum
- '**/go.mod'
- '**/go.sum'
- '**.go'
jobs:
check:
name: Go Workspace Check
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Set go version
uses: actions/setup-go@19bb51245e9c80abacb2e91cc42b33fa478b8639
with:
cache: false
go-version-file: go.mod
- name: Update workspace
run: make update-workspace
- name: Check for go mod & workspace changes
run: |
if ! git diff --exit-code --quiet; then
echo "Changes detected:"
git diff
echo "Please run 'make update-workspace' and commit the changes."
echo "If there is a change in enterprise dependencies, please update pkg/extensions/main.go."
exit 1
fi
- name: Ensure Dockerfile contains submodule COPY commands
run: ./scripts/go-workspace/validate-dockerfile.sh