Skip to content

Update search index #608

Update search index

Update search index #608

# This is a basic workflow to help you get started with Actions
name: Update search index
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
schedule:
- cron: "55 23 * * *"
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "index"
index:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- name: crawl and index
run: |
docker run --rm -i -v $(pwd)/tmp:/code/data qdrant/page-search python -m site_search.crawl
docker run --rm -i -v $(pwd)/tmp:/code/data -e QDRANT_HOST=${{ secrets.QDRANT_HOST }} -e QDRANT_API_KEY=${{ secrets.QDRANT_API_KEY }} qdrant/page-search python -m site_search.encode