Skip to content

Commit a2f0308

Browse files
committed
dummy
1 parent 10be9e3 commit a2f0308

File tree

1 file changed

+3
-49
lines changed

1 file changed

+3
-49
lines changed

.github/workflows/coveo.yml

Lines changed: 3 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
name: Refresh coveo searchToken for docs dev/staging/production
22
on:
3+
pull_request:
34
workflow_dispatch:
45
schedule:
56
- cron: "0 */23 * * *"
@@ -28,7 +29,7 @@ jobs:
2829
id: generate-token
2930
continue-on-error: true
3031
env:
31-
COVEO_API_KEY: ${{secrets[matrix.env_api_key]}}
32+
COVEO_API_KEY: "<NOTHING_BURGER>"
3233
COVEO_SEARCH_HUB: "HUB_ES_Nginx_Docs_And_Org"
3334
run: |
3435
RESPONSE=$(curl -w "\nHTTP_CODE: %{http_code}" -s -X POST "https://platform.cloud.coveo.com/rest/search/v2/token?organizationId=${{matrix.env_coveo_org_id}}" \
@@ -89,51 +90,4 @@ jobs:
8990
}]
9091
}
9192
env:
92-
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_DOCS_INCIDENT }}
93-
94-
95-
push-tokens-to-azure:
96-
name: Batch push coveo search tokens to Azure
97-
runs-on: ubuntu-latest
98-
needs: generate-coveo-search-token
99-
steps:
100-
- name: Download Coveo search token
101-
uses: actions/download-artifact@v5
102-
103-
- name: View files
104-
run: ls -R
105-
106-
- name: Login to Azure
107-
uses: azure/login@v2
108-
with:
109-
creds: ${{secrets.AZURE_CREDENTIALS_DOCS}}
110-
111-
- name: Retrieve secrets from Keyvault
112-
id: keyvault
113-
uses: azure/cli@9f7ce6f37c31b777ec6c6b6d1dfe7db79f497956
114-
with:
115-
inlineScript: |
116-
secrets_get=(productionHostname previewHostname resourceGroupName cdnProfileName cdnName accountName)
117-
for secret_get in ${secrets_get[@]}
118-
do
119-
value=$(az keyvault secret show --name $secret_get --vault-name ${{ secrets.AZURE_KEY_VAULT_DOCS }} --query value --output tsv)
120-
echo "::add-mask::$value"
121-
echo "$secret_get=$value" >> $GITHUB_OUTPUT
122-
done
123-
124-
- name: Push to Azure container storage
125-
run: |
126-
az storage blob upload-batch \
127-
-s ./ \
128-
-d '$web' \
129-
--account-name ${{steps.keyvault.outputs.accountName}} \
130-
--overwrite \
131-
--content-cache-control "no-store" \
132-
--auth-mode login
133-
134-
az afd endpoint purge \
135-
--resource-group ${{steps.keyvault.outputs.resourceGroupName}} \
136-
--profile-name ${{steps.keyvault.outputs.cdnProfileName}} \
137-
--endpoint-name ${{steps.keyvault.outputs.cdnName}} \
138-
--domains docs.nginx.com docs-dev.nginx.com docs-staging.nginx.com \
139-
--content-paths '/.netlify/functions/*'
93+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL_DOCS_INCIDENT }}

0 commit comments

Comments
 (0)