-
-
Notifications
You must be signed in to change notification settings - Fork 0
Restructure backup 20250528 #3
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
base: safe-improvements
Are you sure you want to change the base?
Conversation
name: Deploy app | ||
runs-on: ubuntu-latest | ||
concurrency: deploy-group # optional: ensure only one action runs at a time | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: superfly/flyctl-actions/setup-flyctl@master | ||
- run: flyctl deploy --remote-only | ||
env: | ||
FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }} |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI 5 months ago
To fix the issue, we will add a permissions
block to the workflow. Since the workflow involves deploying an application using flyctl
, it likely requires contents: read
to access the repository's code and deployments: write
to create deployments. These permissions will be explicitly defined at the job level to limit the scope of the GITHUB_TOKEN
to only what is necessary.
-
Copy modified lines R12-R14
@@ -11,2 +11,5 @@ | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
deployments: write | ||
concurrency: deploy-group # optional: ensure only one action runs at a time |
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Install Playwright | ||
run: npx playwright install --with-deps | ||
|
||
- name: Run tests | ||
run: npm run test | ||
|
||
build: |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium test
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI 5 months ago
To fix the issue, add a permissions
block to the workflow file. Since the workflow does not appear to require write permissions, the minimal permissions of contents: read
should be applied. This can be done at the root level of the workflow to apply to all jobs, or at the job level if different permissions are needed for each job. In this case, applying contents: read
at the root level is sufficient and simplifies the configuration.
-
Copy modified lines R9-R11
@@ -8,2 +8,5 @@ | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: |
468cefd
to
013f29d
Compare
No description provided.