This commit updates the introduction page to focus on Rego and
integrating with OPA (whereas the old introduction content focused on
high-level concepts like policy-decoupling, the data document, etc.)
The new introduction content provides a concise overview of OPA and
then launches into an tour of Rego (by example) that shows the core
concepts in the language. The content ends with an overview of
different ways you can interact with OPA.
The old introduction content has been moved into the Philosophy page
and the How Does OPA Work? page has been removed/replaced by the new
introduction page.
With these changes we can update the frontpage with links to core OPA
introduction and then different use cases (e.g., Kubernetes, Envoy,
etc.)
Signed-off-by: Torin Sandall <torinsandall@gmail.com>
Instead of using url rewriting tricks we will just copy the latest
docs as part of the build process for a "latest" version.
In the version selector code we need to handle this to hide the
version, but overall it simplifies the template code.. so thats nice.
Best part, and main reason for doing this, is that the pretty url
feature will now work on the `/docs/latest/*` urls. It will fix some
weirdness with the relative url links we use in the markdown content
and remove a duplicate search result.
Signed-off-by: Patrick East <east.patrick@gmail.com>
This lets us simplify some of the code and there isn't really a great
reason to keep the older docs up at this point.
Signed-off-by: Patrick East <east.patrick@gmail.com>
If there was a tag and branch that both referenced HEAD it would
return to the tag instead of branch. This change gives priority to
the branch if the current HEAD corresponds to one.
Signed-off-by: Patrick East <east.patrick@gmail.com>
This should fix the critical vulnerability found by scanners in the
eslint-utils package by removing the lint script.
We can re-visit this again in the future when someone can spend more
time to fix it.
Signed-off-by: Patrick East <east.patrick@gmail.com>
This commit adds a postprocessor to the docs build that enables
examples to be edited and have the results show up live. See the
additions to `docs/README.md` for more about what writing these
blocks looks like or the netlify PR preview
(e.g. at `docs/edge/how-do-i-write-policies/`)
to see them in action (you'll need to disable CORS for live output).
Signed-off-by: David Boles <me@davidbol.es>
We were using a file with hard coded versions to display docs for, but
this complicates things if/when we need to do patch releases on
different branches from master.
Signed-off-by: Patrick East <east.patrick@gmail.com>