From e71297c57eb01a06288e6cc8586d8e3867504818 Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Sun, 9 Aug 2026 12:43:30 +0530 Subject: [PATCH 1/8] ci: add landing page SEO audit workflow --- .github/workflows/seo-audit.yml | 76 +++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 .github/workflows/seo-audit.yml diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml new file mode 100644 index 0000000..fb04c65 --- /dev/null +++ b/.github/workflows/seo-audit.yml @@ -0,0 +1,76 @@ +name: Landing Page Audit Pipeline + +on: + push: + branches: [ main, develop ] + pull_request: + branches: [ main ] + workflow_dispatch: + +jobs: + seo-and-crawl-audit: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v4 + + # 1. SCAN FOR BROKEN LINKS & ASSETS + - name: Audit Broken Links and Images + uses: GayanPradeep/broken-links-crawler@v1 + with: + website-url: 'https://social-share-button.aossie.org/' + + # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) + - name: Run Lighthouse Audit + uses: treosh/lighthouse-ci-action@v11 + with: + urls: | + https://social-share-button.aossie.org/ + uploadArtifacts: true + temporaryPublicStorage: true + + # 3. ADVANCED VERIFICATIONS (Canonical, Schema, Robots.txt) + - name: Set up Python for Advanced Custom Scans + uses: actions/setup-python@v5 + with: + python-version: '3.10' + + - name: Install Advanced Audit Dependencies + run: | + pip install requests beautifulsoup4 extruct + + - name: Run Advanced Structural Validation + run: | + python - < tag." + + # Test 4: Schema Markup Verification + data = extruct.extract(response.text, base_url=url, syntaxes=['json-ld']) + json_ld = data.get('json-ld', []) + print(f"Structured Data: Found {len(json_ld)} JSON-LD blocks.") + assert len(json_ld) > 0, "Warning: No Structured Schema found on page." + + print("✅ All advanced landing page validations passed successfully!") + EOF \ No newline at end of file From 94696bdab7b8c201aef8ee5ee1865893442f0506 Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Sun, 9 Aug 2026 16:23:52 +0530 Subject: [PATCH 2/8] ci: fix pipeline action shas, timeouts, config, and python tests --- .github/requirements-audit.txt | 3 +++ .github/workflows/seo-audit.yml | 43 +++++++++++++++++++++++++-------- .lighthouserc.json | 16 ++++++++++++ 3 files changed, 52 insertions(+), 10 deletions(-) create mode 100644 .github/requirements-audit.txt create mode 100644 .lighthouserc.json diff --git a/.github/requirements-audit.txt b/.github/requirements-audit.txt new file mode 100644 index 0000000..236a10a --- /dev/null +++ b/.github/requirements-audit.txt @@ -0,0 +1,3 @@ +requests>=2.31.0 +beautifulsoup4>=4.12.0 +extruct>=0.16.0 diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index fb04c65..fbcda69 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -7,37 +7,48 @@ on: branches: [ main ] workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +permissions: + contents: read + jobs: seo-and-crawl-audit: runs-on: ubuntu-latest steps: - name: Checkout Code - uses: actions/checkout@v4 + uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 + with: + persist-credentials: false # 1. SCAN FOR BROKEN LINKS & ASSETS - name: Audit Broken Links and Images - uses: GayanPradeep/broken-links-crawler@v1 + uses: ScholliYT/Broken-Links-Crawler-Action@eae8503903cf448c01ada8a6b0dcc471e66ca87a # GayanPradeep/broken-links-crawler@v1 is 404, using ScholliYT with: website-url: 'https://social-share-button.aossie.org/' # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) - name: Run Lighthouse Audit - uses: treosh/lighthouse-ci-action@v11 + uses: treosh/lighthouse-ci-action@0d716cfc9995b090bb89fe8f531fc3c133ec89ef # v11 with: urls: | https://social-share-button.aossie.org/ + configPath: ./.lighthouserc.json uploadArtifacts: true temporaryPublicStorage: true # 3. ADVANCED VERIFICATIONS (Canonical, Schema, Robots.txt) - name: Set up Python for Advanced Custom Scans - uses: actions/setup-python@v5 + uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 with: python-version: '3.10' - name: Install Advanced Audit Dependencies run: | - pip install requests beautifulsoup4 extruct + python -m pip install --upgrade pip + python -m pip install -r .github/requirements-audit.txt - name: Run Advanced Structural Validation run: | @@ -47,19 +58,31 @@ jobs: import extruct url = "https://social-share-button.aossie.org/" - response = requests.get(url, headers={"User-Agent": "Googlebot"}) + response = requests.get(url, headers={"User-Agent": "Googlebot"}, timeout=(10, 30)) # Test 1: Server Status and Speed print(f"HTTP Status: {response.status_code}") assert response.status_code == 200, "Landing page is down!" - print(f"Time to First Byte (TTFB): {response.elapsed.total_seconds()}s") + ttfb = response.elapsed.total_seconds() + ttfb_budget = 2.5 # TTFB must be under 2.5 seconds + print(f"Time to First Byte (TTFB): {ttfb}s (Budget: {ttfb_budget}s)") + assert ttfb <= ttfb_budget, f"Performance Error: TTFB of {ttfb}s exceeds budget of {ttfb_budget}s" soup = BeautifulSoup(response.text, 'html.parser') # Test 2: Canonical Tag Check - canonical = soup.find('link', rel='canonical') - print(f"Canonical URL found: {canonical['href'] if canonical else 'Missing'}") - assert canonical is not None, "CRITICAL: Missing rel='canonical' tag!" + canonicals = soup.find_all('link', rel='canonical') + assert len(canonicals) > 0, "CRITICAL: Missing rel='canonical' tag!" + assert len(canonicals) == 1, f"CRITICAL: Duplicate canonical tags found ({len(canonicals)}). Expected exactly 1!" + + canonical_href = canonicals[0].get('href', '').strip() + print(f"Canonical URL found: {canonical_href if canonical_href else 'Empty'}") + + assert canonical_href, "CRITICAL: The rel='canonical' tag has an empty or missing 'href' attribute!" + + normalized_href = canonical_href.rstrip('/') + normalized_url = url.rstrip('/') + assert normalized_href == normalized_url, f"CRITICAL: Canonical URL '{canonical_href}' does not match the expected base URL '{url}'!" # Test 3: Heading Hierarchy Check h1s = soup.find_all('h1') diff --git a/.lighthouserc.json b/.lighthouserc.json new file mode 100644 index 0000000..4fcd16d --- /dev/null +++ b/.lighthouserc.json @@ -0,0 +1,16 @@ +{ + "ci": { + "assert": { + "preset": "lighthouse:recommended", + "assertions": { + "categories:accessibility": ["error", { "minScore": 0.9 }], + "categories:best-practices": ["error", { "minScore": 0.9 }], + "categories:seo": ["error", { "minScore": 0.9 }], + "categories:performance": ["error", { "minScore": 0.7 }] + } + }, + "upload": { + "target": "temporary-public-storage" + } + } +} From 5ba0b1d827c95cee0eb53408f294131e8ab7890c Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Sun, 9 Aug 2026 16:43:57 +0530 Subject: [PATCH 3/8] ci: remove extruct dependency and parse JSON-LD directly --- .github/requirements-audit.txt | 1 - .github/workflows/seo-audit.yml | 14 +++++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/.github/requirements-audit.txt b/.github/requirements-audit.txt index 236a10a..f5e5eea 100644 --- a/.github/requirements-audit.txt +++ b/.github/requirements-audit.txt @@ -1,3 +1,2 @@ requests>=2.31.0 beautifulsoup4>=4.12.0 -extruct>=0.16.0 diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index fbcda69..496a5b3 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -55,7 +55,7 @@ jobs: python - < tag." # Test 4: Schema Markup Verification - data = extruct.extract(response.text, base_url=url, syntaxes=['json-ld']) - json_ld = data.get('json-ld', []) + script_tags = soup.find_all('script', type='application/ld+json') + json_ld = [] + for tag in script_tags: + try: + if tag.string: + data = json.loads(tag.string) + json_ld.append(data) + except Exception as e: + assert False, f"CRITICAL: Invalid JSON-LD schema found! Error: {e}" + print(f"Structured Data: Found {len(json_ld)} JSON-LD blocks.") assert len(json_ld) > 0, "Warning: No Structured Schema found on page." From 6de97834b5e200702de52a01b6afdf76ab71df5b Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Sun, 9 Aug 2026 16:53:09 +0530 Subject: [PATCH 4/8] ci: fix trailing whitespace and strict JSON-LD validation --- .github/workflows/seo-audit.yml | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index 496a5b3..2ed60ba 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -74,12 +74,12 @@ jobs: canonicals = soup.find_all('link', rel='canonical') assert len(canonicals) > 0, "CRITICAL: Missing rel='canonical' tag!" assert len(canonicals) == 1, f"CRITICAL: Duplicate canonical tags found ({len(canonicals)}). Expected exactly 1!" - + canonical_href = canonicals[0].get('href', '').strip() print(f"Canonical URL found: {canonical_href if canonical_href else 'Empty'}") - + assert canonical_href, "CRITICAL: The rel='canonical' tag has an empty or missing 'href' attribute!" - + normalized_href = canonical_href.rstrip('/') normalized_url = url.rstrip('/') assert normalized_href == normalized_url, f"CRITICAL: Canonical URL '{canonical_href}' does not match the expected base URL '{url}'!" @@ -92,14 +92,18 @@ jobs: # Test 4: Schema Markup Verification script_tags = soup.find_all('script', type='application/ld+json') json_ld = [] - for tag in script_tags: + for index, tag in enumerate(script_tags, start=1): + raw_json_ld = tag.get_text(strip=True) + assert raw_json_ld, f"CRITICAL: JSON-LD block {index} is empty." + try: - if tag.string: - data = json.loads(tag.string) - json_ld.append(data) - except Exception as e: - assert False, f"CRITICAL: Invalid JSON-LD schema found! Error: {e}" - + data = json.loads(raw_json_ld) + json_ld.append(data) + except json.JSONDecodeError as error: + raise AssertionError( + f"CRITICAL: JSON-LD block {index} is invalid: {error}" + ) from error + print(f"Structured Data: Found {len(json_ld)} JSON-LD blocks.") assert len(json_ld) > 0, "Warning: No Structured Schema found on page." From 72ed64e5b615ea80cde9093ac1c780d5c9f249fe Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Sun, 9 Aug 2026 17:01:33 +0530 Subject: [PATCH 5/8] ci: fix crawler website_url parameter name --- .github/workflows/seo-audit.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index 2ed60ba..b107b97 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -27,7 +27,7 @@ jobs: - name: Audit Broken Links and Images uses: ScholliYT/Broken-Links-Crawler-Action@eae8503903cf448c01ada8a6b0dcc471e66ca87a # GayanPradeep/broken-links-crawler@v1 is 404, using ScholliYT with: - website-url: 'https://social-share-button.aossie.org/' + website_url: 'https://social-share-button.aossie.org/' # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) - name: Run Lighthouse Audit From da3182f3ecdc3b382be783fe28c39acf18eaa837 Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Mon, 10 Aug 2026 10:31:28 +0530 Subject: [PATCH 6/8] ci: use local server for PR audits and revert pipeline to basic --- .github/workflows/seo-audit.yml | 93 +++++++++++++++------------------ .lighthouserc.json | 8 +-- 2 files changed, 48 insertions(+), 53 deletions(-) diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index b107b97..9920f3d 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -7,82 +7,87 @@ on: branches: [ main ] workflow_dispatch: -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -permissions: - contents: read - jobs: seo-and-crawl-audit: runs-on: ubuntu-latest steps: - name: Checkout Code - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 + uses: actions/checkout@v4 + + - name: Set up Node.js + uses: actions/setup-node@v4 with: - persist-credentials: false + node-version: '20' + + # Decide which URL to audit: local build for PRs, production for push/manual + - name: Set audit URL + id: set-url + run: | + if [ "${{ github.event_name }}" == "pull_request" ]; then + echo "AUDIT_URL=http://localhost:3000" >> $GITHUB_ENV + else + echo "AUDIT_URL=https://social-share-button.aossie.org/" >> $GITHUB_ENV + fi + + # Build and serve the landing page locally so PR audits test the PR's own code + - name: Build and serve landing page (PR only) + if: github.event_name == 'pull_request' + run: | + cd landing-page + npm ci + npm run build + npx serve -s out -l 3000 & + sleep 5 # 1. SCAN FOR BROKEN LINKS & ASSETS - name: Audit Broken Links and Images - uses: ScholliYT/Broken-Links-Crawler-Action@eae8503903cf448c01ada8a6b0dcc471e66ca87a # GayanPradeep/broken-links-crawler@v1 is 404, using ScholliYT + uses: ScholliYT/Broken-Links-Crawler-Action@v3 with: - website_url: 'https://social-share-button.aossie.org/' + website_url: ${{ env.AUDIT_URL }} # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) - name: Run Lighthouse Audit - uses: treosh/lighthouse-ci-action@0d716cfc9995b090bb89fe8f531fc3c133ec89ef # v11 + uses: treosh/lighthouse-ci-action@v11 with: urls: | - https://social-share-button.aossie.org/ - configPath: ./.lighthouserc.json + ${{ env.AUDIT_URL }} uploadArtifacts: true temporaryPublicStorage: true # 3. ADVANCED VERIFICATIONS (Canonical, Schema, Robots.txt) - name: Set up Python for Advanced Custom Scans - uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 + uses: actions/setup-python@v5 with: python-version: '3.10' - name: Install Advanced Audit Dependencies run: | - python -m pip install --upgrade pip - python -m pip install -r .github/requirements-audit.txt + pip install requests beautifulsoup4 extruct - name: Run Advanced Structural Validation + env: + TARGET_URL: ${{ env.AUDIT_URL }} run: | python - < 0, "CRITICAL: Missing rel='canonical' tag!" - assert len(canonicals) == 1, f"CRITICAL: Duplicate canonical tags found ({len(canonicals)}). Expected exactly 1!" - - canonical_href = canonicals[0].get('href', '').strip() - print(f"Canonical URL found: {canonical_href if canonical_href else 'Empty'}") - - assert canonical_href, "CRITICAL: The rel='canonical' tag has an empty or missing 'href' attribute!" - - normalized_href = canonical_href.rstrip('/') - normalized_url = url.rstrip('/') - assert normalized_href == normalized_url, f"CRITICAL: Canonical URL '{canonical_href}' does not match the expected base URL '{url}'!" + canonical = soup.find('link', rel='canonical') + print(f"Canonical URL found: {canonical['href'] if canonical else 'Missing'}") + assert canonical is not None, "CRITICAL: Missing rel='canonical' tag!" # Test 3: Heading Hierarchy Check h1s = soup.find_all('h1') @@ -90,20 +95,8 @@ jobs: assert len(h1s) == 1, "SEO Error: Landing page must have exactly ONE

tag." # Test 4: Schema Markup Verification - script_tags = soup.find_all('script', type='application/ld+json') - json_ld = [] - for index, tag in enumerate(script_tags, start=1): - raw_json_ld = tag.get_text(strip=True) - assert raw_json_ld, f"CRITICAL: JSON-LD block {index} is empty." - - try: - data = json.loads(raw_json_ld) - json_ld.append(data) - except json.JSONDecodeError as error: - raise AssertionError( - f"CRITICAL: JSON-LD block {index} is invalid: {error}" - ) from error - + data = extruct.extract(response.text, base_url=url, syntaxes=['json-ld']) + json_ld = data.get('json-ld', []) print(f"Structured Data: Found {len(json_ld)} JSON-LD blocks.") assert len(json_ld) > 0, "Warning: No Structured Schema found on page." diff --git a/.lighthouserc.json b/.lighthouserc.json index 4fcd16d..3a6128a 100644 --- a/.lighthouserc.json +++ b/.lighthouserc.json @@ -1,12 +1,14 @@ { "ci": { + "collect": { + "url": ["http://localhost:3000"] + }, "assert": { - "preset": "lighthouse:recommended", "assertions": { + "categories:performance": ["error", { "minScore": 0.8 }], "categories:accessibility": ["error", { "minScore": 0.9 }], - "categories:best-practices": ["error", { "minScore": 0.9 }], "categories:seo": ["error", { "minScore": 0.9 }], - "categories:performance": ["error", { "minScore": 0.7 }] + "categories:best-practices": ["error", { "minScore": 0.9 }] } }, "upload": { From 17826cbe94c12b9f8e5686a7d7f607316fdafa58 Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Mon, 10 Aug 2026 11:36:47 +0530 Subject: [PATCH 7/8] ci: apply all CodeRabbit fixes - SHA pins, timeouts, TTFB budget, canonical check, remove extruct --- .github/workflows/seo-audit.yml | 57 ++++++++++++++++++++++++--------- .lighthouserc.json | 3 -- 2 files changed, 42 insertions(+), 18 deletions(-) diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index 9920f3d..8303ab5 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -12,10 +12,12 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Code - uses: actions/checkout@v4 + uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 + with: + persist-credentials: false - name: Set up Node.js - uses: actions/setup-node@v4 + uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 with: node-version: '20' @@ -41,28 +43,30 @@ jobs: # 1. SCAN FOR BROKEN LINKS & ASSETS - name: Audit Broken Links and Images - uses: ScholliYT/Broken-Links-Crawler-Action@v3 + uses: ScholliYT/Broken-Links-Crawler-Action@21eab52f98097989d343116dbbd46dc4541b849b # v3 with: website_url: ${{ env.AUDIT_URL }} # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) - name: Run Lighthouse Audit - uses: treosh/lighthouse-ci-action@v11 + uses: treosh/lighthouse-ci-action@0d716cfc9995b090bb89fe8f531fc3c133ec89ef # v11 with: urls: | ${{ env.AUDIT_URL }} + configPath: ./.lighthouserc.json uploadArtifacts: true temporaryPublicStorage: true # 3. ADVANCED VERIFICATIONS (Canonical, Schema, Robots.txt) - name: Set up Python for Advanced Custom Scans - uses: actions/setup-python@v5 + uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 with: python-version: '3.10' - name: Install Advanced Audit Dependencies run: | - pip install requests beautifulsoup4 extruct + python -m pip install --upgrade pip + python -m pip install -r .github/requirements-audit.txt - name: Run Advanced Structural Validation env: @@ -70,33 +74,56 @@ jobs: run: | python - < 0, "CRITICAL: Missing rel='canonical' tag!" + assert len(canonicals) == 1, f"CRITICAL: Duplicate canonical tags found ({len(canonicals)}). Expected exactly 1!" + + canonical_href = canonicals[0].get('href', '').strip() + print(f"Canonical URL found: {canonical_href if canonical_href else 'Empty'}") + + assert canonical_href, "CRITICAL: The rel='canonical' tag has an empty or missing 'href' attribute!" + + normalized_href = canonical_href.rstrip('/') + normalized_url = "https://social-share-button.aossie.org" + assert normalized_href == normalized_url, f"CRITICAL: Canonical URL '{canonical_href}' does not match the expected base URL '{normalized_url}/'!" # Test 3: Heading Hierarchy Check h1s = soup.find_all('h1') print(f"Found {len(h1s)} H1 tags.") assert len(h1s) == 1, "SEO Error: Landing page must have exactly ONE

tag." - # Test 4: Schema Markup Verification - data = extruct.extract(response.text, base_url=url, syntaxes=['json-ld']) - json_ld = data.get('json-ld', []) + # Test 4: Schema Markup Verification (no extruct – uses built-in json) + script_tags = soup.find_all('script', type='application/ld+json') + json_ld = [] + for index, tag in enumerate(script_tags, start=1): + raw = tag.get_text(strip=True) + assert raw, f"CRITICAL: JSON-LD block {index} is empty." + try: + data = json.loads(raw) + json_ld.append(data) + except json.JSONDecodeError as error: + raise AssertionError( + f"CRITICAL: JSON-LD block {index} is invalid: {error}" + ) from error + print(f"Structured Data: Found {len(json_ld)} JSON-LD blocks.") assert len(json_ld) > 0, "Warning: No Structured Schema found on page." diff --git a/.lighthouserc.json b/.lighthouserc.json index 3a6128a..b98917d 100644 --- a/.lighthouserc.json +++ b/.lighthouserc.json @@ -1,8 +1,5 @@ { "ci": { - "collect": { - "url": ["http://localhost:3000"] - }, "assert": { "assertions": { "categories:performance": ["error", { "minScore": 0.8 }], From 5cf7c69687ee635a93a3baa2cde4f8acb255fcd5 Mon Sep 17 00:00:00 2001 From: Aman kumar vishwakrma <186990161+amankv1234@users.noreply.github.com> Date: Mon, 10 Aug 2026 11:41:59 +0530 Subject: [PATCH 8/8] ci: replace Docker crawler action with runner-hosted linkchecker for localhost support --- .github/workflows/seo-audit.yml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/seo-audit.yml b/.github/workflows/seo-audit.yml index 8303ab5..3e41718 100644 --- a/.github/workflows/seo-audit.yml +++ b/.github/workflows/seo-audit.yml @@ -42,10 +42,14 @@ jobs: sleep 5 # 1. SCAN FOR BROKEN LINKS & ASSETS + # Docker-based actions cannot reach localhost on the runner. + # linkchecker runs directly on the runner, so it works for both + # localhost (PR builds) and the production URL (push/manual). + - name: Install Link Checker + run: pip install linkchecker + - name: Audit Broken Links and Images - uses: ScholliYT/Broken-Links-Crawler-Action@21eab52f98097989d343116dbbd46dc4541b849b # v3 - with: - website_url: ${{ env.AUDIT_URL }} + run: linkchecker "${{ env.AUDIT_URL }}" --check-extern --no-warnings # 2. RUN LIGHTHOUSE SEO + PERFORMANCE + ACCESSIBILITY AUDIT (no API key needed) - name: Run Lighthouse Audit