0.0.6 • Published 4 years ago
@algolia/crawler-netlify-plugin v0.0.6
crawler-netlify-plugin
This plugin links your Netlify site with Algolia's Crawler.
It will trigger a crawl on each successful build.
Environment variables
ALGOLIA_API_KEY
Optional in dev API Key to authenticate the call to the crawler.ALGOLIA_BASE_URL
Optional Defaults tohttps://crawler.algolia.com/
.
For a local run, those need to be set in .env
using cp .env.example .env
and modifying the values to fit your needs.
Scripts
yarn dev
: run dev environmentyarn release
: build & publish the library
Development
Pre-requisites
Only accessible to Algolia employees.
- Access to the Algolia team on Netlify (only granted to Algolia employees).
- Access to the test website in this org: https://app.netlify.com/sites/crawler-netlify-plugin/
- Clone the repo and link it to the test website on Netlify:
git clone git@github.com:algolia/algoliasearch-netlify.git cd algoliasearch-netlify yarn yarn netlify link # Accept linking it with the current git remote, it'll detect the correct site automatically
- Setup
.env
by copying the example file:
Make sure the values in this file are good.cp .env.example .env
Running the dev env
yarn dev
It builds the site locally, running the local version of the plugin.
To change the crawler target from the prod one to a local instance, simply change in your .env
ALGOLIA_BASE_URL
.