Giter VIP home page Giter VIP logo

Comments (13)

cdubz avatar cdubz commented on June 15, 2024

Assuming you’re using the default (local disk) for media — do you see any files in the public/media directory (from the app root)? I wonder if there is some permissions configuration that is not addressed there for the manual install.

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

I do. The uploaded image is in a subfolder of that folder as well. I'll try to chmod 777 the whole directory to exclude permission issues.

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

Nope. chmodded the directory (recursively, obviously) to 777 and still nothing. I'm not even getting an error now.. Although when uploading the image, it gives me a 404 for the preview:
GET https://[domain]/media/7/conversions/[etc] 404

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

Tried uploading a profile picture to see if it's a general issue - that 404ed as well.
GET https://[domain]/media/8/conversions/ryderfornow-icon.jpg 404

from kcal.

cdubz avatar cdubz commented on June 15, 2024

Curious — and you said the originals are being uploaded? But the conversions are missing?

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

Yes, it seems like it.

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

I can access the unconverted upload without any issues. But the conversion does not exist (neither on the filesystem nor on the site)

from kcal.

cdubz avatar cdubz commented on June 15, 2024

Hm ok. I wonder if there is a dependency missing from the manual install instructions for the media handling. What base system (Debian, Ubuntu, etc.) and version are you using?

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

Ubuntu (server) 20.04

from kcal.

cdubz avatar cdubz commented on June 15, 2024

Ok I’ll try to find some time today to test from that base and see if something is missing.

In the mean time you may be able to troubleshoot by poking around the docs for the library that handles these conversions — https://spatie.be/docs/laravel-medialibrary/v9/requirements

I’m guessing a PHP module or image library is missed somewhere in the install steps.

from kcal.

cdubz avatar cdubz commented on June 15, 2024

@RyderForReal a couple of things are probably happening here --

  1. By default, the media conversions are queued. This seems unnecessary for an app like this so I have changed the example .env file to handle conversions immediately instead of in queue. Add the following to your .env to do the same:

    QUEUE_CONVERSIONS_BY_DEFAULT=false
    
  2. The temp directory used by the media conversion library may not have correct permissions. To check them try:

    ls -lah {APP_ROOT}storage/media-library/
    

    There should be a temp directory in there with permissions drwxrwxr-x and uid:gid $USER:www-data. If the directory has some other permissions, see below and use those commands.

I also added a step to the manual install process to try to address this directly, but it may need more testing. As a final step the documentation now has:

1. Allow web server to access required directories.

       sudo chown -R $USER:www-data {storage,public}
       sudo chmod g+s {storage,public}

Let me know if any of that gets you going!

from kcal.

RyderForReal avatar RyderForReal commented on June 15, 2024

Works! Thanks a lot.

from kcal.

cdubz avatar cdubz commented on June 15, 2024

Nice! Eventually I need to come up with a way to simplify the permissions stuff for that manual install process…

from kcal.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.