Skip to content

Commit 12a92d6

Browse files
pass correct kosli api tokens to test workflow (#491)
1 parent 8d505ab commit 12a92d6

File tree

4 files changed

+14
-9
lines changed

4 files changed

+14
-9
lines changed

.github/workflows/daily-cli-tests.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,6 @@ jobs:
4545
slack_webhook: ${{ secrets.MERKELY_SLACK_CI_FAILURES_WEBHOOK }}
4646
slack_channel: ci-failures
4747
snyk_token: ${{ secrets.SNYK_TOKEN }}
48-
kosli_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
48+
kosli_reporting_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
49+
kosli_querying_api_token: ${{ secrets.KOSLI_API_TOKEN_PROD }}
4950
sonarqube_token: ${{ secrets.KOSLI_SONARQUBE_TOKEN }}

.github/workflows/main.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,8 @@ jobs:
7070
slack_webhook: ${{ secrets.MERKELY_SLACK_CI_FAILURES_WEBHOOK }}
7171
slack_channel: ci-failures
7272
snyk_token: ${{ secrets.SNYK_TOKEN }}
73-
kosli_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
73+
kosli_reporting_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
74+
kosli_querying_api_token: ${{ secrets.KOSLI_API_TOKEN_PROD }}
7475
sonarqube_token: ${{ secrets.KOSLI_SONARQUBE_TOKEN }}
7576

7677
docker:

.github/workflows/release.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ jobs:
8181
slack_channel: ci-failures
8282
jira_api_token: ${{ secrets.KOSLI_JIRA_API_TOKEN }}
8383
snyk_token: ${{ secrets.SNYK_TOKEN }}
84-
kosli_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
84+
kosli_reporting_api_token: ${{ secrets.KOSLI_PUBLIC_API_TOKEN }}
85+
kosli_querying_api_token: ${{ secrets.KOSLI_API_TOKEN_PROD }}
8586
sonarqube_token: ${{ secrets.KOSLI_SONARQUBE_TOKEN }}
8687

8788
docker:

.github/workflows/test.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ on:
5151
required: true
5252
snyk_token:
5353
required: true
54-
kosli_api_token:
54+
kosli_reporting_api_token:
55+
required: true
56+
kosli_querying_api_token:
5557
required: true
5658
sonarqube_token:
5759
required: true
@@ -89,7 +91,7 @@ jobs:
8991
- name: Report lint to Kosli
9092
if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) && (success() || failure()) && inputs.report_results }}
9193
env:
92-
KOSLI_API_TOKEN: ${{ secrets.kosli_api_token }}
94+
KOSLI_API_TOKEN: ${{ secrets.kosli_reporting_api_token }}
9395
run: kosli attest generic
9496
--name lint
9597
--flow ${{ inputs.FLOW_NAME }}
@@ -152,7 +154,7 @@ jobs:
152154
INTEGRATION_TEST_AZURE_CLIENT_ID: ${{ secrets.azure_client_id }}
153155
KOSLI_SONAR_API_TOKEN: ${{ secrets.sonarqube_token }}
154156
DOCKER_API_VERSION: "1.45"
155-
KOSLI_API_TOKEN_PROD: ${{ secrets.kosli_api_token }}
157+
KOSLI_API_TOKEN_PROD: ${{ secrets.kosli_querying_api_token }}
156158
run: |
157159
# some tests use git operations, therefore the git author on the CI VM needs to be set
158160
git config --global user.name "John Doe"
@@ -162,7 +164,7 @@ jobs:
162164
- name: Report test to Kosli
163165
if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) && (success() || failure()) && inputs.report_results }}
164166
env:
165-
KOSLI_API_TOKEN: ${{ secrets.kosli_api_token }}
167+
KOSLI_API_TOKEN: ${{ secrets.kosli_reporting_api_token }}
166168
run: kosli attest junit
167169
--name test
168170
--flow ${{ inputs.FLOW_NAME }}
@@ -212,7 +214,7 @@ jobs:
212214
- name: Report Snyk Code to Kosli
213215
if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) && (success() || failure()) && inputs.report_results }}
214216
env:
215-
KOSLI_API_TOKEN: ${{ secrets.kosli_api_token }}
217+
KOSLI_API_TOKEN: ${{ secrets.kosli_reporting_api_token }}
216218
run: kosli attest snyk
217219
--name snyk-code-test
218220
--flow ${{ inputs.FLOW_NAME }}
@@ -259,7 +261,7 @@ jobs:
259261
- name: Report Snyk Test to Kosli
260262
if: ${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) && (success() || failure()) && inputs.report_results }}
261263
env:
262-
KOSLI_API_TOKEN: ${{ secrets.kosli_api_token }}
264+
KOSLI_API_TOKEN: ${{ secrets.kosli_reporting_api_token }}
263265
run: kosli attest snyk
264266
--name snyk-dependency-test
265267
--flow ${{ inputs.FLOW_NAME }}

0 commit comments

Comments
 (0)