TC
Twill CMS.ghostbane

Media Library / Glide only loading JPEGs

Hey there, So I had a Laravel/Twill app running successfully on a subdomain with no issue. Today I needed to move it to the main domain to go live. This is a CPanel shared host server btw. So I moved everything over to a root folder named laravel-core and then the public folder, sitting separately as public_html After configuring everything to address the new paths, the site loads, but not the images coming from the Twill CMS. Well, not all of them. On looking at the Media Library in the CMS, What was working previously on the sub-domain, is that it seems that only image files as a JPEG were being successfully loaded via Glide/Twill in the /img/ route. As you can see in the screenshot, the Media Library, with the network requests to the right. Images as jpeg are successfully coming through Glide, successfully being manipulated, but only JPEGs. JPEG Example: https://shiftit.no/img/c8a9d6bf-0a49-4e16-9618-a42a250f02ef/6346c314aa282csswj.jpeg?fm=webp&q=60&auto=compress%2Cformat&fit=min&dpr=1&h=256 JPG Example: 404 error https://shiftit.no/img/60dabc39-b70d-432b-a7ee-43af0aaa966f/shiftit-home-feature-mix21.jpg?fm=webp&q=60&auto=compress%2Cformat&fit=min&dpr=1&h=256 I am absolutely baffled, I double checked I wasn't doing any extension filtering in the Glide/Twill settings, everything is pretty much default, out of the box settings. I've delete the Glide Cache etc, I am at a loss. Any help would be greatly appreciated !
No description
constantvariable.
constantvariable.424d ago
Hello, have you done the symlink to the storage path on the new server ? php artisan storage:link
.ghostbane
.ghostbane424d ago
I had to do it manually because the the command would not work, unsure if it was because of absolutele paths or whatnot
constantvariable.
constantvariable.424d ago
Does it work if you upload a new jpg file ?
.ghostbane
.ghostbane424d ago
No, the image doesn't load in the ML, but it uploads to the server I can access it via the storage url directly, but not through the Glide img
constantvariable.
constantvariable.424d ago
Ok that must be a symlink problem, are you sure the symlink is good ? Alos, be sure to clean all the caches : php artisan optimize && php artisan route:clear && php artisan config:clear
.ghostbane
.ghostbane424d ago
The symlink is working for everything else in the storage Also for JPEG files via /img/ Just not for other extensions, which is super weird Yes, I've done all the cache dumps
constantvariable.
constantvariable.424d ago
Check also the glide config in your .env file
.ghostbane
.ghostbane424d ago
FILE_LIBRARY_ENDPOINT_TYPE=local
MEDIA_LIBRARY_ENDPOINT_TYPE=local
MEDIA_LIBRARY_IMAGE_SERVICE=A17\Twill\Services\MediaLibrary\Glide
FILE_LIBRARY_ENDPOINT_TYPE=local
MEDIA_LIBRARY_ENDPOINT_TYPE=local
MEDIA_LIBRARY_IMAGE_SERVICE=A17\Twill\Services\MediaLibrary\Glide
constantvariable.
constantvariable.424d ago
You can also define this: MEDIA_LIBRARY_LOCAL_PATH=uploads/
constantvariable.
constantvariable.424d ago
GitHub
[Media Library] Filesystem Config not used - Invalid image url · Is...
Hi, i have currently the challenge, that the returned url values for images which has been uploaded locally. I configured the twill app as following: //.env APP_URL=twill.local ADMIN_APP_URL=twill....
.ghostbane
.ghostbane424d ago
The /uploads path is on by default, and working correctly for the system path as far as I can tell. It is so bizarre, I can see in your link there, allowed_extensions, but I don't have that specifically set anywhere. I mean, the Media Library allows me to upload other formats.
ifox
ifox424d ago
there's no coupling between the formats you allow to upload and what glide can render the jpg/jpeg issue is really weird indeed
.ghostbane
.ghostbane424d ago
I am absolutely baffled. Does the Artisan storage link command do anything outside of running a symlink creation loop based on what is in the links array from the filesystems config? Does Twill/Glide run anything additionally here?
ifox
ifox424d ago
nope, and the storage link is actually not needed for glide to work since it goes through a controller on the /img path what I suspect is the version of GD or Imagick in use by your cpanel host depending on how it's been compiled it could have this issue I guess
.ghostbane
.ghostbane424d ago
It worked perfectly well on a subdomain on the same host. Bog standard Cpanel shared server. Had the app on a subdomain for months during reviewed development, moved it 'live' so to speak, and this issue arises.
ifox
ifox424d ago
very strange did you ask your hosting provider?
.ghostbane
.ghostbane424d ago
Not yet, wanted to see if it was something that was seen before through here. I guess I could ask them to trace the process or whatever, but I'm unsure how much help they could shine on this.
ifox
ifox424d ago
is the derived image generated on the filesystem by glide?
.ghostbane
.ghostbane424d ago
As in, is it physically uploaded?
.ghostbane
.ghostbane424d ago
ifox
ifox424d ago
I mean when you request it with /img do you see a new file under the glide_cache folder?
.ghostbane
.ghostbane424d ago
No, it isn't there Just the JPEGs
ifox
ifox424d ago
did you try dd'ing your way into the glide controller?
.ghostbane
.ghostbane424d ago
I have not went as far as that, but may give that a look tomorrow. Would this be the controller A17\Twill\Services\MediaLibrary\Glide ?
ifox
ifox424d ago
yes, but you'll need to drilldown into glide itself from there
ifox
ifox424d ago
GitHub
twill/GlideController.php at 861032e3c94965c59cc5c5d2ef2f1014b6e201...
Twill is an open source CMS toolkit for Laravel that helps developers rapidly create a custom admin console that is intuitive, powerful and flexible. Chat with us on Discord at https://discord.gg/c...
ifox
ifox424d ago
GitHub
twill/Glide.php at 7c030c6d315e679b51ee4de9537816e3a0f9abb1 · area1...
Twill is an open source CMS toolkit for Laravel that helps developers rapidly create a custom admin console that is intuitive, powerful and flexible. Chat with us on Discord at https://discord.gg/c...
ifox
ifox424d ago
GitHub
glide/Server.php at 0305fff66b2c427d41e8558385d235ce10230d85 · barr...
Wonderfully easy on-demand image manipulation library with an HTTP based API. - glide/Server.php at 0305fff66b2c427d41e8558385d235ce10230d85 · barryvdh/glide
.ghostbane
.ghostbane424d ago
For reference, dd'ing the $path in the Glide controller,
No description
.ghostbane
.ghostbane424d ago
Prints out a path for JPEG, anything else still presents a 404
.ghostbane
.ghostbane424d ago
No description
.ghostbane
.ghostbane424d ago
No description
.ghostbane
.ghostbane424d ago
No description
.ghostbane
.ghostbane424d ago
Made a small test with a jpg url to test the route matching,
.ghostbane
.ghostbane424d ago
No description
.ghostbane
.ghostbane424d ago
No description
.ghostbane
.ghostbane424d ago
It is matching the correct route in the test with a jpg But for whatever reason, it won't do this with the actual url
Want results from more Discord servers?
Add your server
More Posts
Adding a vue componentGood afternoon Tell me what could be the problem? On the main page of the admin panel there is an aSave title in translationsI'm trying to save my title as a translatable field, normal fied works fine but when i make it transSet translations to activeWhile trying to set translations to active it isn't saved to database? Only english is selectablecan't use Published, Draft, Trash filters on module indexI see the buttons, they show the correct counts in the parenthesis, but when I click on them, I alwamedias XHR request with wrong schemeGreetings... I'm having trouble with accessing media library in the admin area in production. Mixeremove positioning and nesting from the page indexGood morning. Tell me how to remove positioning and nesting from the page index in the admin panel? Connecting additional fields depending on the value in the record when selected in the browser compoGood morning. Can you tell me if it is possible to implement the doing in twill? I have a browser iCustom function in a Module ControllerI need to trigger a custom function that is run after a user clicks "Update" for a post in a Twill mTiptap WYSIWYGHi everyone, I would like to know if there is a way to use toolbar align options with tiptap type wySorting by a translation field (ie, title)Hi everyone, I feel like I must be missing something simple (as usual) or am making something overlyProblem with displaying headers if the site is in two languagesGood morning. I decided to look at twill 3 version. I use two languages (ru-main, en-I want to add Issuing rights to upload to the media libraryGood afternoon! Tell me how to give the right dip for the defined role to upload files / images to tAttribute [singleton] does not exist.Hello there im working in a twill website,and i got this error , can you help me sloving this error Disable live - draftAny way to disable this feature on forms? Have tried multiple things, but non of it seems to work.output selected blocks on the front in different placesGood afternoon! Tell me how you can draw blocks on the front selectively? Example Block 1 text teDeleting an entry causes 500 error unless entry is destroyedBeen struggling with this for a bit and I'm out of ideas. I've got a browser that contains a list ofBrowser route for sub-menu (primary navigation)How to setup a browser connected to a module outside of the navigation group? See images for clarifGet link to file in media libraryGood afternoon guys. Tell me how you can add the output of links to files when loading in the librarBrowser fields the id of the object doesn't saveBrowser options show list with logo and name, gets attached correctly including logo and name. When InvalidArgumentExceptionUrlBuilder must be passed a string domainGetting this error after switching to Imgix from Glide in MEDIA_LIBRARY_IMAGE_SERVICE.