Git lfs files not actually available on github

Hey there!

I’m using netlify to deploy an 11ty project on github.

This project uses a 318mb Mp3 file that I tried to store on git lfs via github. By following the documentation it seems I succeeded in using git LFS. After all github says so:
image

but When I go to the deployed website the file isn’t even in the assets folder
image
I’ve added all the setup on netlify to use the github lfs not their lfs but the file isnt there.

So then I try downloading the raw file from GitHub and get this:

image
A blank audio with nothing inside of it. Meaning that the file isn’t on the website because the file isn’t on GitHub.

So, then I tried removing the file, committing the removal, then adding it back in, committing that, then using git lfs push --all origin in the terminal and it saying in response Uploading LFS objects: 100% (1/1), 334 MB | 0 B/s, done.

still nothing the website and nothing in github.

Has this ever happened to anyone? Any advice?

Best,
Ben

I don’t think the Netlify solution (or any LFS solution) is meant for streaming audio/video assets. I would suggest using a CDN (like cloudflare or whatever). There are also audio-only hosting sites (like sound cloud) which would give you a player embed and I’m guessing some management tools.

Never used Git LFS or Netlify with LFS so I’m not going to speculate on what is wrong.

@lasjorg
Technically,
Its not supposed to stream the file only to store it.

I’m placing the file in an audio tag to be interacted with JavaScript. This is for an mvp/sketch not a final product LOL

But thanks for weighing in! :slight_smile:

Well, the solution is also not meant for file storage.

Why does it need to be 300MB?
I guess I don’t really understand the usage here.

The MP3 is 5 hours long LOL and git lfs stands for large file storage

I’m trying to just establish posibilites rather than create and actual project

The app is an audio tag that starts calming music for my pets at 8AM and stops at 9PM intended for use when I’m not home or when their with a sitter

Using Javascript as the logic behind the stopping and starting

No it is meant for tracking large files. Why do you need to track it? Will it change? Tracking binary files is more of a special case and it doesn’t sound like you need it.

You do not need to track the audio file. You are just making it more complicated than it needs to be. Use a CDN or an audio hosting site. Or if the site lets you upload assets you can just link to the hosted asset (without the binary file being tracked by Git).

I guess I was confused because netlify large media marketing and the github docs describe storing images, .psd files, and audio files with git LFS but honestly I’ve been debugging this all this morning.

The reason I wanted to go this route is because I wanted something that was plain html, css, and js without any embeds or iframes or whatnot. I’m going to investigate my options because git lfs is just a pain to work with so far.

Thanks for your sugestions though :slight_smile:

Large Media requirements and limitations

  • Netlify Large Media is not suitable for streaming audio or video files. However, storing these assets for download should work well.
  • Netlify Large Media is intended for files up to 100 MB in size.

I realize you might be thinking of the audio file as an image file or other small binary files which you are used to pushing to GitHub. But it isn’t really the same. There is a reason why GitHub has file size limitations. They are not a binary file hosting service. Git is for version tracking/control and GitHub is just a web service to host Git repos.

Don’t get me wrong, I can see the appeal of just having everything stored in one place and it would be nice if it worked that way.

Yup. I think your right :+1:

However netlify does allow drag an drop upload as long as there’s an index.html so what I’m going to try is uploading an index.html and the audio file together and then linking to the hosted asset.

Hopefully it works :slight_smile:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.