Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
41 changes: 41 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,3 +119,44 @@ jobs:
Write-Output "::error::$invalidPackages NuGet package(s) failed validation."
exit 1
}

publish-nuget:
needs: [ build-test, validate-packages ]
runs-on: ubuntu-latest
if: |
github.event.repository.fork == false &&
startsWith(github.ref, 'refs/tags/')

environment:
name: NuGet.org
url: https://www.nuget.org/profiles/Grafana

permissions:
contents: read
id-token: write

steps:

- name: Download packages
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
with:
name: packages-windows

- name: Setup .NET SDK
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4.3.1
with:
dotnet-version: ${{ needs.build-test.outputs.dotnet-sdk-version }}

- uses: grafana/shared-workflows/actions/get-vault-secrets@9f37f656e063f0ad0b0bfc38d49894b57d363936 # get-vault-secrets/v1.2.1
id: get-token
with:
export_env: false
repo_secrets: |
token=nuget:token

- name: Push NuGet packages to NuGet.org
shell: bash
env:
API_KEY: ${{ fromJSON(steps.get-token.outputs.secrets).token }}
SOURCE: 'https://api.nuget.org/v3/index.json'
run: dotnet nuget push "*.nupkg" --api-key "${API_KEY}" --skip-duplicate --source "${SOURCE}"
1 change: 1 addition & 0 deletions .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ jobs:
- name: Review dependencies
uses: actions/dependency-review-action@da24556b548a50705dd671f47852072ea4c105d9 # v4.7.1
with:
allow-dependencies-licenses: 'pkg:githubactions/grafana/shared-workflows/actions/get-vault-secrets'
allow-licenses: 'Apache-2.0,BSD-3-Clause,MIT'
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ To engage with the Grafana Application Observability community:
[oats-badge]: https://github.com/grafana/grafana-opentelemetry-dotnet/actions/workflows/oats.yml/badge.svg?branch=main
[oats-status]: https://github.com/grafana/grafana-opentelemetry-dotnet/actions/workflows/oats.yml
[otel]: https://github.com/open-telemetry/opentelemetry-dotnet
[otel-badge]: https://img.shields.io/badge/OTel--SDK-1.9.0-blue?style=flat&logo=opentelemetry
[otel-badge]: https://img.shields.io/badge/OTel--SDK-1.12.0-blue?style=flat&logo=opentelemetry
[otel-contrib]: http://github.com/open-telemetry/opentelemetry-dotnet-contrib
[package]: https://www.nuget.org/packages/Grafana.OpenTelemetry
[package-badge-version]: https://img.shields.io/nuget/v/Grafana.OpenTelemetry?logo=nuget&label=NuGet&color=blue
Expand Down
2 changes: 1 addition & 1 deletion package-readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ For detailed documentation and setup instructions, refer to [our documentation][
[app-o11y]: https://grafana.com/docs/grafana-cloud/monitor-applications/application-observability/
[docs]: https://github.com/grafana/grafana-opentelemetry-dotnet/tree/main/docs
[otel]: https://github.com/open-telemetry/opentelemetry-dotnet
[otel-badge]: https://img.shields.io/badge/OTel--SDK-1.9.0-blue?style=flat&logo=opentelemetry
[otel-badge]: https://img.shields.io/badge/OTel--SDK-1.12.0-blue?style=flat&logo=opentelemetry
[otel-contrib]: http://github.com/open-telemetry/opentelemetry-dotnet-contrib
[package]: https://www.nuget.org/packages/Grafana.OpenTelemetry
[package-badge-version]: https://img.shields.io/nuget/v/Grafana.OpenTelemetry?logo=nuget&label=NuGet&color=blue
Expand Down
Loading