Skip to content

Commit

Permalink
Update Algolia index as part of the website deployment pipeline (#2434)
Browse files Browse the repository at this point in the history
* Remove redundant steps and only run the docsearch-scraper

* Update Algolia index when a new version of the website is published
  • Loading branch information
danielelisi authored Apr 13, 2023
1 parent d892bd3 commit bcc2118
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 75 deletions.
59 changes: 0 additions & 59 deletions .github/workflows/algolia.yml

This file was deleted.

10 changes: 10 additions & 0 deletions .github/workflows/deploy_website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,16 @@ jobs:
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}

- name: Update Algolia Index
if: github.ref == 'refs/heads/master'
run: |
docker run --rm -e "CONFIG=$(cat ./website/config.json | jq -r tostring)" \
-e API_KEY=${{secrets.ALGOLIA_UPDATE_API_KEY}} \
-e APPLICATION_ID=${{secrets.ALGOLIA_APPLICATION_ID}} \
algolia/docsearch-scraper
# Notify the PR of the deploy preview
- uses: marocchino/sticky-pull-request-comment@v2
if: github.event_name == 'pull_request'
with:
Expand Down
16 changes: 0 additions & 16 deletions website/scripts/delete-index.js

This file was deleted.

0 comments on commit bcc2118

Please sign in to comment.