From f1e18ba45e9e15870a2add0bb2ec8be42e28b22f Mon Sep 17 00:00:00 2001 From: "yongen.loong" Date: Thu, 20 Jun 2024 18:37:32 +0800 Subject: [PATCH] ci: use github action --- .github/workflows/typesense.yml | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/.github/workflows/typesense.yml b/.github/workflows/typesense.yml index 88b951e..02912c4 100644 --- a/.github/workflows/typesense.yml +++ b/.github/workflows/typesense.yml @@ -15,9 +15,20 @@ jobs: - name: Check out the repo uses: actions/checkout@v4 - - run: | - docker run -e TYPESENSE_API_KEY=${{ secrets.TYPESENSE_API_KEY }} \ - -e TYPESENSE_HOST=${{ secrets.TYPESENSE_HOST }} \ - -e TYPESENSE_PORT=443 \ - -e TYPESENSE_PROTOCOL=https \ - -e "CONFIG=$(cat config/typesense.json | jq -r tostring)" typesense/docsearch-scraper:latest \ No newline at end of file + - name: Run DocSearch Scraper + uses: celsiusnarhwal/typesense-scraper@v2 + with: + # The secret containing your Typesense API key. Required. + api-key: ${{ secrets.TYPESENSE_API_KEY }} + + # The hostname or IP address of your Typesense server. Required. + host: ${{ secrets.TYPESENSE_HOST }} + + # The port on which your Typesense server is listening. Optional. Default: 8108. + port: 443 + + # The protocol to use when connecting to your Typesense server. Optional. Default: http. + protocol: https + + # The path to your DocSearch config file. Optional. Default: docsearch.config.json. + config: config/typesense.json \ No newline at end of file