Git LFS failing on Gatsby Build with Netlify

Site: marshalmurphy.com

I have tried to use Git LFS, however my Gatsby front end is causing build errors.

Per the answer provided in this thread, if we could come to a solution as suggestion, that would be ideal.

Otherwise I will need to remove LFS.

Thanks,

Hi, @marshallmurphy. Often Gatsby does processing of images during the site build. Modifying images at build time is not supported by Large Media as documented here. Quoting:

Files tracked with Large Media are uploaded directly to the Netlify Large Media storage service on push, completely bypassing the site build. This saves build time, but also means that the files are not available to tools that process asset files during the build, such as Hugo’s image processing or the gatsby-image plugin. Depending on your needs, you may be able to replace this functionality with Netlify’s image transformation service.

If you do decide to uninstall the Large Media add-on for this site, would you please confirm you have read the following Support Guide?

If you have read that, please confirm you have backups of all files and let us know when you are ready for us to uninstall the add-on.

​Please let us know if there are any questions and/or if the Large Media add-on should be uninstalled for this site.

Hi Luke,

Thanks for the documentation.

I have local backups of all files in LFS.

Please proceed with uninstalling the Large Media add-on for my site [marshalmurphy.com](http://marshalmurphy.com).

Thx,

Hi, @marshallmurphy. We have removed the Large Media add-on from this site.

Would you please push the commit removing .lfsconfig to the upstream repository? This will trigger a new build.

Please let us know if there are any issues with the new build or deployed site.

Hi Luke,

Thanks for removing LFS.

After updating the files to remove pointers and LFS from the repo following https://github.com/git-lfs/git-lfs/issues/3026,
and clearing the cache and building, everything working as expected.

Best,

1 Like