unity-builder icon indicating copy to clipboard operation
unity-builder copied to clipboard

WebGL build failing with no errors

Open celojevic opened this issue 5 months ago • 0 comments

Hello there! I just got into adding CI/CD for my game. I was able to get a mac build successfully going. However, I'm having issues with it on the webgl platform. It keeps failing after ~45 minutes during the build step. Any help or advice would be appreciated!

Ive also attached the logs from the failed build. logs_28072298948.zip

And here are some screenshots from my build summary: Screenshot 2024-09-06 125732 Screenshot 2024-09-06 125744

Here is my yml:

name: Build and Upload WebGL on Main Push 😎

on: [push]

env:
  itchio_project: goonby/tombstone
  itchio_channel: webgl

jobs:
  build:
    name: Build my project ✨
    # ubuntu-latest tends to throw error: The hosted runner: GitHub Actions lost communication with the server. Anything in your workflow that terminates the runner process, starves it for CPU/Memory, or blocks its network access can cause this error.
    runs-on: ubuntu-20.04
    steps:
      # Free up disk space
      - name: Free Disk Space (Ubuntu)
        uses: jlumbroso/free-disk-space@main
        with:
          # this might remove tools that are actually needed,
          # if set to "true" but frees about 6 GB
          tool-cache: false          
          # all of these default to true, but feel free to set to
          # "false" if necessary for your workflow
          android: true
          dotnet: true
          haskell: true
          large-packages: true
          docker-images: true
          swap-storage: true
    
      # Checkout
      - name: Checkout repository
        uses: actions/checkout@v4
        with:
          lfs: true
          submodules: recursive
      
      # Checkout sprites repo
      - name: Check out Sprites private repo
        uses: actions/checkout@v4
        with:
          repository: celojevic/Sprites_Tombstone
          token: ${{ secrets.PRIVATE_REPO_PAT }}
          path: 'Assets/Sprites_Tombstone'
          
      # Checkout FMOD repo
      - name: Check out FMOD private repo
        uses: actions/checkout@v4
        with:
          repository: celojevic/FMOD_Tombstone
          token: ${{ secrets.PRIVATE_REPO_PAT }}
          path: 'Assets/FMOD_Tombstone'

      # Cache
      - uses: actions/cache@v4
        with:
          path: Library
          key: Library-${{ hashFiles('Assets/**', 'Packages/**', 'ProjectSettings/**') }}
          restore-keys: |
            Library-

      # Build
      - name: Build project
        uses: game-ci/unity-builder@v4
        env:
          UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
          UNITY_EMAIL: ${{ secrets.UNITY_EMAIL }}
          UNITY_PASSWORD: ${{ secrets.UNITY_PASSWORD }}
        with:
          targetPlatform: WebGL

      # Output
      - uses: actions/upload-artifact@v3
        with:
          name: Build
          path: build
          
      # Upload the build using Butler
      - name: Install Butler CLI
        run: |
          curl -L -o butler.zip https://broth.itch.zone/butler/linux-amd64/LATEST/archive/default
          unzip butler.zip -d butler
          sudo mv butler/butler /usr/local/bin/
          butler -V

      # Deploy
      - name: Upload build to itch.io
        run: |
          butler push build ${{ env.itchio_project }}:${{ env.itchio_channel }}
        env:
          BUTLER_API_KEY: ${{ secrets.BUTLER_API_KEY }}

celojevic avatar Sep 06 '24 16:09 celojevic