Skip to content

Commit

Permalink
NH-82783: add signing path for stage jar.
Browse files Browse the repository at this point in the history
  • Loading branch information
cleverchuk committed Jul 22, 2024
1 parent 7f7e9a3 commit 73cb65c
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,28 @@ jobs:
run: |
echo "AGENT_VERSION=$(cd agent/build/libs && unzip -p solarwinds-apm-agent.jar META-INF/MANIFEST.MF | grep Implementation-Version | awk '{ print $2 }' | sed 's/[^a-z0-9.-]//g')" >> $GITHUB_ENV
- name: Sign and download signed jar
run: |
response=$(curl -fs \
-H "Authorization: Bearer $SIGN_PATH_API_TOKEN" \
-F "ProjectSlug=$SIGN_PATH_PROJECT_SLUG" \
-F "SigningPolicySlug=$SIGN_PATH_SIGNING_POLICY" \
-F "Artifact=@agent/build/libs/solarwinds-apm-agent.jar" \
https://app.signpath.io/API/v1/$SIGN_PATH_ORG_ID/SigningRequests)
echo "res -> $response"
SIGNING_REQUEST_ID==$(echo "$response" | jq -r '.signingRequestId')
echo "request-id -> $SIGNING_REQUEST_ID"
curl -fs \
-o agent/build/libs/solarwinds-apm-agent.jar \
-H "Authorization: Bearer $SIGN_PATH_API_TOKEN" \
https://app.signpath.io/API/v1/$SIGN_PATH_ORG_ID/SigningRequests/$SIGNING_REQUEST_ID/SignedArtifact
env:
SIGN_PATH_API_TOKEN: ${{ secrets.SIGN_PATH_API_TOKEN }}
SIGN_PATH_PROJECT_SLUG: ${{ secrets.SIGN_PATH_PROJECT_SLUG }}
SIGN_PATH_SIGNING_POLICY: ${{ secrets.SIGN_PATH_SIGNING_POLICY }}
SIGN_PATH_ORG_ID: ${{ secrets.SIGN_PATH_ORG_ID }}

- name: Copy to S3
run: |
ls -al
Expand Down

0 comments on commit 73cb65c

Please sign in to comment.