diff --git a/.github/workflows/release-layer-collector.yml b/.github/workflows/release-layer-collector.yml index ede4761fa6..32e64b6761 100644 --- a/.github/workflows/release-layer-collector.yml +++ b/.github/workflows/release-layer-collector.yml @@ -8,11 +8,20 @@ on: permissions: id-token: write - contents: read + contents: write jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create Release + run: gh release create ${{ github.ref_name }} --draft --title ${{ github.ref_name }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} build-layer: runs-on: ubuntu-latest + needs: create-release strategy: matrix: architecture: @@ -31,6 +40,11 @@ jobs: with: name: opentelemetry-collector-layer-${{ matrix.architecture }}.zip path: ${{ github.workspace }}/collector/build/opentelemetry-collector-layer-${{ matrix.architecture }}.zip + - name: Add Binary to Release + run: | + gh release upload ${{github.ref_name}} ${{ github.workspace }}/collector/build/opentelemetry-collector-layer-${{ matrix.architecture }}.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Save Collector Version if: ${{ matrix.architecture == 'amd64' }} id: save-collector-version diff --git a/.github/workflows/release-layer-java.yml b/.github/workflows/release-layer-java.yml index 65498c0aea..857824f470 100644 --- a/.github/workflows/release-layer-java.yml +++ b/.github/workflows/release-layer-java.yml @@ -8,11 +8,20 @@ on: permissions: id-token: write - contents: read + contents: write jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create Release + run: gh release create ${{ github.ref_name }} --draft --title ${{ github.ref_name }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} build-layer: runs-on: ubuntu-latest + needs: create-release outputs: JAVAAGENT_VERSION: ${{ steps.save-javaagent-version.outputs.JAVAAGENT_VERSION }} JAVAWRAPPER_VERSION: ${{ steps.save-javawrapper-version.outputs.JAVAWRAPPER_VERSION }} @@ -44,6 +53,12 @@ jobs: name: opentelemetry-javawrapper-layer.zip path: java/layer-wrapper/build/distributions/opentelemetry-javawrapper-layer.zip + - name: Add Binary to Release + run: | + gh release upload ${{github.ref_name}} java/layer-wrapper/build/distributions/opentelemetry-javawrapper-layer.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Save Javaagent Version id: save-javaagent-version shell: bash diff --git a/.github/workflows/release-layer-nodejs.yml b/.github/workflows/release-layer-nodejs.yml index 46d40146e8..cc16da3da0 100644 --- a/.github/workflows/release-layer-nodejs.yml +++ b/.github/workflows/release-layer-nodejs.yml @@ -8,11 +8,20 @@ on: permissions: id-token: write - contents: read + contents: write jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create Release + run: gh release create ${{ github.ref_name }} --draft --title ${{ github.ref_name }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} build-layer: runs-on: ubuntu-latest + needs: create-release outputs: NODEJS_VERSION: ${{ steps.save-node-sdk-version.outputs.SDK_VERSION}} steps: @@ -44,6 +53,12 @@ jobs: with: name: opentelemetry-nodejs-layer.zip path: nodejs/packages/layer/build/opentelemetry-nodejs-layer.zip + + - name: Add Binary to Release + run: | + gh release upload ${{github.ref_name}} nodejs/packages/layer/build/opentelemetry-nodejs-layer.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} publish-layer: uses: ./.github/workflows/layer-publish.yml diff --git a/.github/workflows/release-layer-python.yml b/.github/workflows/release-layer-python.yml index 41f9a8e6ed..00d939adc3 100644 --- a/.github/workflows/release-layer-python.yml +++ b/.github/workflows/release-layer-python.yml @@ -8,11 +8,20 @@ on: permissions: id-token: write - contents: read + contents: write jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create Release + run: gh release create ${{ github.ref_name }} --draft --title ${{ github.ref_name }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} build-layer: runs-on: ubuntu-latest + needs: create-release outputs: PYTHON_OPENTELEMETRY_SDK_VERSION: ${{ steps.save-python-opentelemetry-sdk-version.outputs.PYTHON_OPENTELEMETRY_SDK_VERSION}} steps: @@ -52,6 +61,12 @@ jobs: name: opentelemetry-python-layer.zip path: python/src/build/opentelemetry-python-layer.zip + - name: Add Binary to Release + run: | + gh release upload ${{github.ref_name}} python/src/build/opentelemetry-python-layer.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + publish-layer: uses: ./.github/workflows/layer-publish.yml needs: build-layer diff --git a/.github/workflows/release-layer-ruby.yml b/.github/workflows/release-layer-ruby.yml index d7f50f8e02..d09523cd1b 100644 --- a/.github/workflows/release-layer-ruby.yml +++ b/.github/workflows/release-layer-ruby.yml @@ -8,11 +8,20 @@ on: permissions: id-token: write - contents: read + contents: write jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create Release + run: gh release create ${{ github.ref_name }} --draft --title ${{ github.ref_name }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} build-layer: runs-on: ubuntu-latest + needs: create-release outputs: RUBY_SDK_VERSION: ${{ steps.save-ruby-sdk-version.outputs.RUBY_SDK_VERSION}} steps: @@ -43,6 +52,12 @@ jobs: with: name: opentelemetry-ruby-layer.zip path: ruby/src/build/opentelemetry-ruby-layer.zip + + - name: Add Binary to Release + run: | + gh release upload ${{github.ref_name}} ruby/src/build/opentelemetry-ruby-layer.zip + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} publish-layer: uses: ./.github/workflows/layer-publish.yml