Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add broken link check workflow #37

Merged
merged 6 commits into from
Jun 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/link-check-workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Link Checker
on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
linkchecker:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: lychee Link Checker
id: lychee
uses: lycheeverse/lychee-action@master
with:
args: --accept=200,403,429 --exclude=localhost "**/*.html" "**/*.md" "**/*.txt" "**/*.json"
ohltyler marked this conversation as resolved.
Show resolved Hide resolved
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Fail if there were link errors
run: exit ${{ steps.lychee.outputs.exit_code }}
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[![Unit tests](https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/workflows/Unit%20tests%20workflow/badge.svg)](https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/actions?query=workflow%3A%22Unit+tests+workflow%22)
[![Integration tests](https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/workflows/E2E%20tests%20workflow/badge.svg)](https://github.com/opensearch-project/anomaly-detection-dashboards-plugin/actions?query=workflow%3A%22E2E+tests+workflow%22)
[![codecov](https://codecov.io/gh/opensearch-project/anomaly-detection-dashboards-plugin/branch/main/graph/badge.svg)](https://codecov.io/gh/opensearch-project/anomaly-detection-dashboards-plugin)
[![Documentation](https://img.shields.io/badge/doc-reference-blue)](https://docs-beta.opensearch.org/docs/ad/)
[![Documentation](https://img.shields.io/badge/doc-reference-blue)](https://docs-beta.opensearch.org/monitoring-plugins/ad/index/)
[![Forum](https://img.shields.io/badge/chat-on%20forums-blue)](https://discuss.opendistrocommunity.dev/c/Use-this-category-for-all-questions-around-machine-learning-plugins)
![PRs welcome!](https://img.shields.io/badge/PRs-welcome!-success)

Expand All @@ -22,7 +22,7 @@ You should use the plugin with the same version of the [OpenSearch Alerting Dash

## Documentation

Please see our [documentation](https://docs-beta.opensearch.org/docs/ad).
Please see our [documentation](https://docs-beta.opensearch.org/monitoring-plugins/ad/index/).

## Setup

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with monitor 1`]
Anomaly detector alerts are powered by the
<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//alerting"
rel="noreferrer"
>

Expand All @@ -98,7 +98,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with monitor 1`]
Alerting in your navigation panel,
<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/opensearch/install/plugins/#alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//opensearch/install/plugins/#alerting"
rel="noreferrer"
>

Expand Down Expand Up @@ -217,7 +217,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with monitor 1`]
<a
class="euiButton euiButton--primary"
data-test-subj="setUpAlerts"
href="https://docs-beta.opensearch.org/docs/alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//alerting"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -363,7 +363,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with undefined mo
Anomaly detector alerts are powered by the
<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//alerting"
rel="noreferrer"
>

Expand All @@ -388,7 +388,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with undefined mo
Alerting in your navigation panel,
<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/opensearch/install/plugins/#alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//opensearch/install/plugins/#alerting"
rel="noreferrer"
>

Expand Down Expand Up @@ -507,7 +507,7 @@ exports[`<AlertsFlyout /> spec Alerts Flyout renders component with undefined mo
<a
class="euiButton euiButton--primary"
data-test-subj="setUpAlerts"
href="https://docs-beta.opensearch.org/docs/alerting"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//alerting"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ exports[`<Configuration /> spec renders the component in create mode with existi

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -703,7 +703,7 @@ exports[`<Configuration /> spec renders the component in edit mode without exist

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ exports[`<Features /> spec renders the component with no given features 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -145,7 +145,7 @@ exports[`<Features /> spec renders the component with one feature 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -813,7 +813,7 @@ exports[`<CreateHistoricalDetector /> spec create historical detector renders th

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -2271,7 +2271,7 @@ exports[`<CreateHistoricalDetector /> spec edit historical detector renders the

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ exports[`<EmptyDetector /> spec Empty results renders component with empty messa

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ exports[`<CategoryField /> spec hides callout if component is loading 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -177,7 +177,7 @@ exports[`<CategoryField /> spec renders the component when disabled 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -297,7 +297,7 @@ exports[`<CategoryField /> spec renders the component when enabled 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down Expand Up @@ -517,7 +517,7 @@ exports[`<CategoryField /> spec shows callout when there are no available catego

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ exports[`<SampleDataCallout /> spec Data not loaded renders component 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ exports[`<CreateDetector /> spec create detector renders the component 1`] = `

<a
class="euiLink euiLink--primary"
href="https://docs-beta.opensearch.org/docs/ad"
href="https://docs-beta.opensearch.org/monitoring-plugins/ad/index//ad"
rel="noopener noreferrer"
target="_blank"
>
Expand Down
3 changes: 2 additions & 1 deletion public/utils/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ export const ANOMALY_DETECTORS_INDEX = '.opendistro-anomaly-detectors';

export const ANOMALY_RESULT_INDEX = '.opendistro-anomaly-results';

export const BASE_DOCS_LINK = 'https://docs-beta.opensearch.org/docs';
export const BASE_DOCS_LINK =
'https://docs-beta.opensearch.org/monitoring-plugins/ad/index/';

export const MAX_DETECTORS = 1000;

Expand Down