Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added required permissions in the action example #79

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions _templates/README.md.erb
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ name: Example workflow for <%= @name %> using Snyk
on: push
jobs:
security:
permissions:
danacr marked this conversation as resolved.
Show resolved Hide resolved
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions cocoapods/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for CocoaPods using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions dotnet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for dotNET using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions golang/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Golang using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions gradle-jdk11/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Gradle using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions gradle-jdk12/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Gradle using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions gradle-jdk14/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Gradle using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions gradle-jdk16/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Gradle using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions gradle/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Gradle using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions maven-3-jdk-11/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Maven using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions maven/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Maven using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions node/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Node using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions php/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for PHP using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions python-3.6/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ name: Example workflow for Python using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions python-3.7/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ name: Example workflow for Python using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions python-3.8/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ name: Example workflow for Python using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions python/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,12 @@ name: Example workflow for Python using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions ruby/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Ruby using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down
6 changes: 6 additions & 0 deletions scala/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ name: Example workflow for Scala using Snyk
on: push
jobs:
security:
permissions:
# required for all workflows
security-events: write
# only required for workflows in private repositories
actions: read
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
Expand Down