Skip to content

Commit

Permalink
refactor(github workflows): replace env variables with secrets for ap…
Browse files Browse the repository at this point in the history
…p-id and private-key in code-review.yml and main.yml

This change is done to enhance security by using GitHub secrets instead of environment variables for sensitive data.
  • Loading branch information
MrHinsh committed Jul 16, 2024
1 parent 0e2e6c5 commit bfb4d4c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/code-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ jobs:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ env.APP_ID }}
private-key: ${{ env.PRIVATE_KEY }}
app-id: ${{ secrets.NKDAGILITY_BOT_APP_ID }}
private-key: ${{ secrets.NKDAGILITY_BOT_CLIENTSECRET }}
- uses: fitomad/github-chatgpt-integration@main
with:
openai-api-key: ${{ secrets.OPENAI_API_KEY }}
Expand Down
8 changes: 2 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
APP_ID: "Iv23li9aYvt0VW9x4Jhh"
PRIVATE_KEY: ${{ secrets.NKDAGILITY_BOT_CLIENTSECRET }}

defaults:
run:
shell: pwsh
Expand Down Expand Up @@ -261,8 +257,8 @@ jobs:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ env.APP_ID }}
private-key: ${{ env.PRIVATE_KEY }}
app-id: ${{ secrets.NKDAGILITY_BOT_APP_ID }}
private-key: ${{ secrets.NKDAGILITY_BOT_CLIENTSECRET }}
- name: "Package Files"
shell: pwsh
run: |
Expand Down

0 comments on commit bfb4d4c

Please sign in to comment.