Skip to content

Astro Site: Please ensure the content does not contain any hard links, symlinks and total size is less than 10GB #345

@TheDevelolper

Description

@TheDevelolper

Like many others I'm getting the dreaded error:

Artifact could not be deployed. Please ensure the content does not contain any hard links or symlinks and total size is less than 10GB.

here's my yaml file:

name: Build & Test
on:
  push:
    branches:
      - main
      - master
  pull_request:
    branches:
      - main
      - master

permissions:
  contents: read
  pages: write
  id-token: write

jobs:
  build:
    timeout-minutes: 60
    name: Build & Test
    runs-on: ubuntu-latest

    steps:
      - name: Checkout Repository
        uses: actions/checkout@v4

      - name: Setup Node.js
        uses: actions/setup-node@v4
        with:
          node-version: lts/*

      - name: Install Dependencies
        run: npm install && npm run install:site
      - uses: actions/upload-artifact@v4
      
        if: failure()
        with:
          name: /home/runner/.npm/_logs/
          path: /home/runner/.npm/_logs/
          retention-days: 30

      - name: Build Project
        run: npm run build
      
      - name: Install Playwright Browsers
        run: npx playwright install --with-deps

      - name: Run Playwright tests
        run: npm test
      - uses: actions/upload-artifact@v4
        if: always()
        with:
          name: playwright-report
          path: playwright-report/
          retention-days: 30
      

      - name: Set Astro Dist Permisisons
        run: chmod -R 777 apps/notedrop-site/dist

      - name: Publish Project Site Artifact
        uses: actions/upload-artifact@v4
        if: ${{ github.event_name != 'pull_request' }}
        with:
          name: github-pages
          path: apps/notedrop-site/dist
          retention-days: 1

  deploy:
    needs: build
    if: ${{ github.event_name != 'pull_request' }}
    runs-on: ubuntu-latest
    permissions:
      contents: read
      pages: write
      id-token: write
    environment:
      name: github-pages
      url: ${{ steps.deployment.outputs.page_url }}
    steps:
      - name: Deploy to GitHub Pages
        id: deployment
        uses: actions/deploy-pages@v4

The artifact file is produced and is under 1GB (about 1.6MB) it doesn't seem to contain any hard links or symlinks.

I've added a copy of it here, it's a very simple Astro site:
github-pages.zip

Out of desperation I tried to chmod all the files to 777 before publishing (as you can see in the pipeline.yaml). Unfortunately that didn't appear to work.

Any help you can offer would be sincerely appreciated as I've spent quite a bit of time trying researching, trying to find a fix, to no avail 😔.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions