Skip to content

Commit 696ed8a

Browse files
committed
Revert "feat: prevent versioned 3P GitHub actions in PR builds (aws-observability#475)"
This reverts commit 2de80d4.
1 parent 2de80d4 commit 696ed8a

File tree

2 files changed

+1
-56
lines changed

2 files changed

+1
-56
lines changed

.github/actions/image_scan/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ runs:
3232
run: docker logout public.ecr.aws
3333

3434
- name: Run Trivy vulnerability scanner on image
35-
uses: aquasecurity/trivy-action@b6643a29fecd7f34b3597bc6acb0a98b03d33ff8 # v0.33.1
35+
uses: aquasecurity/trivy-action@master
3636
with:
3737
image-ref: ${{ inputs.image-ref }}
3838
severity: ${{ inputs.severity }}

.github/workflows/pr-build.yml

Lines changed: 0 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -10,61 +10,6 @@ permissions:
1010
contents: read
1111

1212
jobs:
13-
static-code-checks:
14-
runs-on: ubuntu-latest
15-
steps:
16-
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #5.0.0
17-
with:
18-
fetch-depth: 0
19-
20-
- name: Check CHANGELOG
21-
if: always()
22-
run: |
23-
# Check if PR is from workflows bot or dependabot
24-
if [[ "${{ github.event.pull_request.user.login }}" == "aws-application-signals-bot" ]]; then
25-
echo "Skipping check: PR from aws-application-signals-bot"
26-
exit 0
27-
fi
28-
29-
if [[ "${{ github.event.pull_request.user.login }}" == "dependabot[bot]" ]]; then
30-
echo "Skipping check: PR from dependabot"
31-
exit 0
32-
fi
33-
34-
# Check for skip changelog label
35-
if echo '${{ toJSON(github.event.pull_request.labels.*.name) }}' | jq -r '.[]' | grep -q "skip changelog"; then
36-
echo "Skipping check: skip changelog label found"
37-
exit 0
38-
fi
39-
40-
# Fetch base branch and check for CHANGELOG modifications
41-
git fetch origin ${{ github.base_ref }}
42-
if git diff --name-only origin/${{ github.base_ref }}..HEAD | grep -q "CHANGELOG.md"; then
43-
echo "CHANGELOG.md entry found - check passed"
44-
exit 0
45-
fi
46-
47-
echo "It looks like you didn't add an entry to CHANGELOG.md. If this change affects the SDK behavior, please update CHANGELOG.md and link this PR in your entry. If this PR does not need a CHANGELOG entry, you can add the 'Skip Changelog' label to this PR."
48-
exit 1
49-
50-
- name: Check for versioned GitHub actions
51-
if: always()
52-
run: |
53-
# Get changed GitHub workflow/action files
54-
CHANGED_FILES=$(git diff --name-only origin/${{ github.base_ref }}..HEAD | grep -E "^\.github/(workflows|actions)/.*\.ya?ml$" || true)
55-
56-
if [ -n "$CHANGED_FILES" ]; then
57-
# Check for any versioned actions, excluding comments and this validation script
58-
VIOLATIONS=$(grep -Hn "uses:.*@v" $CHANGED_FILES | grep -v "grep.*uses:.*@v" | grep -v "#.*@v" || true)
59-
if [ -n "$VIOLATIONS" ]; then
60-
echo "Found versioned GitHub actions. Use commit SHAs instead:"
61-
echo "$VIOLATIONS"
62-
exit 1
63-
fi
64-
fi
65-
66-
echo "No versioned actions found in changed files"
67-
6813
build:
6914
runs-on: ubuntu-latest
7015
strategy:

0 commit comments

Comments
 (0)