Skip to content

Commit

Permalink
chore: fixed broken URLs (#1518)
Browse files Browse the repository at this point in the history
* chore: fixed broken URLs

* ci: added codeowners file
  • Loading branch information
karl-cardenas-coding committed Sep 11, 2023
1 parent a4f97b1 commit 46d9e70
Show file tree
Hide file tree
Showing 6 changed files with 1,434 additions and 4 deletions.
39 changes: 39 additions & 0 deletions .github/url-checks.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
on:
schedule:
# Every Monday at 6 am
- cron: '0 6 * * 1'


concurrency:
group: url-${{ github.ref }}
cancel-in-progress: true

name: Broken URL check
jobs:
markdown-link-check:
runs-on: ubuntu-latest
steps:
- id: checkout
name: Checkout Repository
uses: actions/checkout@v3
with:
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}

- name: Setup Nodejs
uses: actions/setup-node@v3
with:
node-version: 18

- name: URL Checker
run: make verify-url-links-ci

- name: Post Comment
run: |
cd scripts
./url-checker.sh
env:
ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
OWNER: ${{ github.repository_owner }}
REPO: ${{ github.event.repository.name }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
20 changes: 20 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,23 @@ fix-server: ## Fix server issues by removing the cache folder and reinstalling n
pdf: ## Generate PDF from docs
@echo "generating pdf"
npx docs-to-pdf docusaurus --initialDocURLs="https://docs.spectrocloud.com" --contentSelector="article" --paginationSelector="a.pagination-nav__link.pagination-nav__link--next" --excludeSelectors=".margin-vert--xl a,[class^='tocCollapsible'],.breadcrumbs,.theme-edit-this-page" --protocolTimeout=e00 --outputPDFFilename=palette-docs.pdf --coverTitle="Palette Documentation" --coverImage=https://docs.spectrocloud.com/assets/images/docs_introduction_product-overview-80d5488097f9e227a325e252dda42f85.png

###@ URL Checks

verify-url-links: ## Check for broken URLs in production
rm link_report.csv || echo "No report exists. Proceeding to scan step"
npx linkinator https://docs.spectrocloud.com/ --recurse --timeout 60000 --retry --retry-errors-count 3 --skip "^http(?!.*spectrocloud\\.com).*$"" --format csv > temp_report.csv && sleep 2
grep -E '^[^,]*,[[:space:]]*([4-9][0-9]{2}|[0-9]{4,}),' temp_report.csv > link_report.csv && rm temp_report.csv


verify-url-links-ci: ## Check for broken URLs in production
rm link_report.json || echo "No report exists. Proceeding to scan step"
npx linkinator https://docs.spectrocloud.com/ --recurse --timeout 60000 --retry --retry-errors-count 3 --skip "^http(?!.*spectrocloud\\.com).*$"" --format json > temp_report.json
jq 'del(.links[] | select(.status <= 200))' temp_report.json > link_report.json
rm temp_report.json
mv link_report.json scripts/


verify-url-links-local: build ## Check for broken URLs locally
rm link_report.csv || echo "No report exists. Proceeding to scan step"
npm run test-links
12 changes: 12 additions & 0 deletions docs/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Docs & Tutorials
content/ @spectrocloud/docs-education
# Images
assets/docs/images/ @spectrocloud/docs-education
# Writing Checks
vale/ @spectrocloud/docs-education
# CI/CD Related
.github/ @spectrocloud/docs-education


# Catch All Rule
* @spectrocloud/docs-education
8 changes: 4 additions & 4 deletions docs/docs-content/enterprise-version/enterprise-version.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@ tags: ["self-hosted", "enterprise"]
Palette is available as a self-hosted platform offering. You can install the self-hosted version of Palette in your data centers or public cloud providers to manage Kubernetes clusters. You can install Palette by using the following four methods:


- [VMware Quick Start](/enterprise-version#vmwarequickstart)
- [VMware Quick Start](/enterprise-version/deploying-the-platform-installer)


- [VMware Enterprise](/enterprise-version#vmwareenterprise)
- [VMware Enterprise](/enterprise-version/deploying-an-enterprise-cluster)


- [Kubernetes Install Helm Chart](/enterprise-version#kubernetesinstallhelmchart)
- [Kubernetes Install Helm Chart](/enterprise-version/deploying-palette-with-helm)


- [AirGap Install](/enterprise-version#airgapinstall)
- [AirGap Install](/enterprise-version/air-gap-repo)

## VMware Quick Start

Expand Down
Loading

0 comments on commit 46d9e70

Please sign in to comment.