Skip to content

Commit

Permalink
[StepSecurity] ci: Harden GitHub Actions in issue-mark-duplicate.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
step-security-bot authored and oliviertassinari committed Oct 15, 2022
1 parent 53612fa commit 9a32a3b
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 14 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/check-if-pr-has-label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ on:
types: [opened, reopened, labeled, unlabeled]

jobs:
test-label-applied:
# Tests that label is added on the PR
test-label-applied: # Tests that label is added on the PR
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: mnajdova/[email protected]
with:
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,14 @@ jobs:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: ['javascript', 'typescript']
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
Expand All @@ -34,7 +31,6 @@ jobs:

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/l10n.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ jobs:
# Tests dev-only scripts across all supported dev environments
update-l10n:
runs-on: ubuntu-latest
permissions:
contents: read
issues: write
steps:
- run: echo "${{ github.actor }}"
- uses: actions/checkout@v3
Expand All @@ -22,7 +25,6 @@ jobs:
env:
# Don't need playwright in this job
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: yarn l10n --report
env:
# Don't need playwright in this job
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/maintenance.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
name: 'Maintenance'
name: Maintenance

on:
# So that PRs touching the same files as the push are updated
push:
Expand All @@ -17,6 +18,9 @@ on:
jobs:
main:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: check if prs are dirty
uses: eps1lon/actions-label-merge-conflict@releases/2.x
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Issue Mark Duplicate
name: Mark duplicate

on:
issue_comment:
Expand All @@ -7,6 +7,10 @@ on:
jobs:
mark-duplicate:
runs-on: ubuntu-latest
permissions:
contents: read
issues: write
pull-requests: write
steps:
- name: mark-duplicate
uses: actions-cool/issues-helper@v3
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/no-response.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ on:
jobs:
noResponse:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: lee-dohm/[email protected]
with:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/support-stackoverflow.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# Configuration for support-requests - https://github.com/dessant/support-requests
name: 'Support Stack Overflow'
name: Support Stack Overflow

on:
issues:
types: [labeled, unlabeled, reopened]

permissions:
issues: write

jobs:
mark-support:
runs-on: ubuntu-latest
permissions:
contents: read
issues: write
steps:
- uses: dessant/support-requests@v2
with:
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/vale-action.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
name: reviewdog
name: Vale action

on: [pull_request]

jobs:
vale:
name: runner / vale
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v3
- uses: errata-ai/vale-action@reviewdog
Expand Down

0 comments on commit 9a32a3b

Please sign in to comment.