docs_search_sync.yml
1 name: Docs Search Sync 2 3 on: 4 workflow_dispatch: # Activate this workflow manually 5 schedule: 6 - cron: "0 1 * * *" 7 8 # Running this workflow multiple times in parallel can cause issues with files uploads and deletions. 9 concurrency: 10 group: docs-search-sync 11 cancel-in-progress: false 12 13 jobs: 14 docs-search-sync: 15 runs-on: ubuntu-latest 16 17 steps: 18 19 - name: Checkout Haystack repo 20 uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 21 22 - name: Install Node.js 23 uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 24 with: 25 node-version: "22" 26 27 - name: Install Python 28 uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 29 with: 30 python-version: "3.12" 31 32 - name: Install Docusaurus and build docs-website 33 working-directory: docs-website 34 run: | 35 npm install 36 npm run build 37 38 - name: Install script dependencies 39 # sniffio is needed because of https://github.com/deepset-ai/deepset-cloud-sdk/issues/286 40 # we pin pyrate-limiter due to https://github.com/deepset-ai/deepset-cloud-sdk/issues/295 41 run: pip install deepset-cloud-sdk sniffio requests "pyrate-limiter<4" 42 43 - name: Update new docs to Search pipeline and remove outdated docs 44 env: 45 DEEPSET_WORKSPACE_DOCS_SEARCH: ${{ secrets.DEEPSET_WORKSPACE_DOCS_SEARCH }} 46 DEEPSET_API_KEY_DOCS_SEARCH: ${{ secrets.DEEPSET_API_KEY_DOCS_SEARCH }} 47 run: python ./.github/utils/docs_search_sync.py 48 49 - name: Notify Slack on nightly failure 50 if: failure() && github.event_name == 'schedule' 51 uses: deepset-ai/notify-slack-action@3cda73b77a148f16f703274198e7771340cf862b # v1 52 with: 53 slack-webhook-url: ${{ secrets.SLACK_WEBHOOK_URL_NOTIFICATIONS }}