-
Notifications
You must be signed in to change notification settings - Fork 209
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
14 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ name: release-main | |
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
branches: [ "main", "test/provenance" ] | ||
|
||
permissions: | ||
attestations: write | ||
|
@@ -36,12 +36,14 @@ jobs: | |
|
||
# Github packages requires authentication, this is likely going away in the future so for now we publish to feedz.io | ||
- name: publish canary packages to feedz.io | ||
if: startsWith(github.ref, 'refs/tags') | ||
run: dotnet nuget push 'build/output/_packages/*.nupkg' -k ${{ secrets.FEEDZ_IO_API_KEY }} -s ${{ secrets.FEEDZ_IO_API_URL }} --skip-duplicate --no-symbols | ||
|
||
- name: publish canary packages github package repository | ||
if: startsWith(github.ref, 'refs/tags') | ||
run: dotnet nuget push 'build/output/_packages/*.nupkg' -k ${{secrets.GITHUB_TOKEN}} -s https://nuget.pkg.github.com/elastic/index.json --skip-duplicate --no-symbols | ||
|
||
- if: ${{ failure() }} | ||
- if: ${{ failure() && startsWith(github.ref, 'refs/tags') }} | ||
uses: elastic/oblt-actions/slack/[email protected] | ||
with: | ||
bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,8 @@ name: release | |
on: | ||
release: | ||
types: [published] | ||
push: | ||
branches: [ "test/provenance" ] | ||
|
||
permissions: | ||
contents: write | ||
|
@@ -39,6 +41,7 @@ jobs: | |
run: ./build.sh pack | ||
|
||
- name: Release to Nuget | ||
if: startsWith(github.ref, 'refs/tags') | ||
run: .ci/linux/deploy.sh ${{ secrets.NUGET_API_KEY }} ${{ secrets.NUGET_API_URL }} | ||
|
||
- name: Log in to the Elastic Container registry | ||
|
@@ -56,7 +59,7 @@ jobs: | |
cache-from: type=gha | ||
cache-to: type=gha,mode=max | ||
context: . | ||
push: true | ||
push: false | ||
tags: | | ||
${{ env.DOCKER_IMAGE }}:${{ steps.bootstrap.outputs.agent-version }} | ||
build-args: | | ||
|
@@ -67,7 +70,7 @@ jobs: | |
with: | ||
subject-name: ${{ env.DOCKER_IMAGE }} | ||
subject-digest: ${{ steps.docker-push.outputs.digest }} | ||
push-to-registry: true | ||
push-to-registry: false | ||
|
||
- name: generate build provenance (APM Agent) | ||
uses: actions/attest-build-provenance@49df96e17e918a15956db358890b08e61c704919 # v1.2.0 | ||
|
@@ -80,13 +83,14 @@ jobs: | |
subject-path: "${{ github.workspace }}/${{ env.PREFIX_APM_PROFILER }}${{ steps.bootstrap.outputs.agent-version }}${{ env.SUFFIX_APM_PROFILER }}" | ||
|
||
- name: Attach Profiler And Startup Hooks | ||
if: startsWith(github.ref, 'refs/tags') | ||
continue-on-error: true #continue for now until we see it working in action | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
gh release upload ${{ github.ref_name }} "${{ env.PREFIX_APM_AGENT }}${{ steps.bootstrap.outputs.agent-version }}${{ env.SUFFIX_APM_AGENT }}" "${{ env.PREFIX_APM_PROFILER }}${{ steps.bootstrap.outputs.agent-version }}${{ env.SUFFIX_APM_PROFILER }}" | ||
- if: ${{ success() }} | ||
- if: ${{ success() && startsWith(github.ref, 'refs/tags') }} | ||
uses: elastic/oblt-actions/slack/[email protected] | ||
with: | ||
bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
|
@@ -96,7 +100,7 @@ jobs: | |
Build: (<${{ env.JOB_URL }}|here>) | ||
Release URL: (<https://github.com/elastic/apm-agent-dotnet/releases/tag/${{ github.ref_name }}|${{ github.ref_name }}>) | ||
- if: ${{ failure() }} | ||
- if: ${{ failure() && startsWith(github.ref, 'refs/tags') }} | ||
uses: elastic/oblt-actions/slack/[email protected] | ||
with: | ||
bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
|
@@ -135,6 +139,7 @@ jobs: | |
subject-path: "${{ github.workspace }}/${{ env.PREFIX_ZIP_FILE }}${{ steps.bootstrap.outputs.agent-version }}${{ env.SUFFIX_ZIP_FILE }}" | ||
|
||
- name: Attach Profiler | ||
if: startsWith(github.ref, 'refs/tags') | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
continue-on-error: true #continue for now until we see it working in action | ||
|
@@ -144,6 +149,7 @@ jobs: | |
post-release: | ||
needs: [ 'release-windows'] | ||
runs-on: ubuntu-latest | ||
if: startsWith(github.ref, 'refs/tags') | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GIT_TAG: v${{ needs.release-windows.outputs.agent-version }} | ||
|