Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Heed help with http+fs storage type #195

Open
Nasfy opened this issue May 2, 2024 · 1 comment
Open

Heed help with http+fs storage type #195

Nasfy opened this issue May 2, 2024 · 1 comment

Comments

@Nasfy
Copy link

Nasfy commented May 2, 2024

Hello,

We are facing an issue when using picfit to process images. We have configured picfit according to the documentation, specifying the base URL of our Nginx proxy server and the location of the images. However, despite our configurations being in place, requests to our service are not reaching the server, and we are consistently receiving a 404 error when attempting to process the images.

We'd also like to mention that we are using Nginx as a proxy server for image processing.

Our current picfit configuration file looks like this:

{
  "debug": true,
  "port": 80,
  "kvstore": {
    "type": "cache"
  },
  "storage": {
    "src": {
      "type": "http+fs",
      "base_url":  "http://nginx-media-service.stage-namespace:80",
      "location": "/media"
    }
  }
}

picfit log

{"time":"2024-05-02T16:43:48.427545821Z","level":"INFO","msg":"Key not found in store","key":"3f9a22c50c62f49acd8f8a88b7d40bef","request-id":"7c84d2d5-515b-4453-98cb-6694c50a79c8"}
{"time":"2024-05-02T16:43:48.427648068Z","level":"INFO","msg":"/display","status":404,"method":"GET","params":{"h":["0"],"op":["resize"],"path":["/media:a5784db13a88c445f7bb12cd519f7fbcfd8e2fe702"],"w":["500"]},"path":"/display","ip":"127.0.0.1","duration":200068,"user-agent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36","request-id":"7c84d2d5-515b-4453-98cb-6694c50a79c8"}
{"time":"2024-05-02T16:43:48.427703477Z","level":"INFO","msg":"Memory stats","alloc":"3 MiB","heap-alloc":"3 MiB","total-alloc":"21 MiB","sys":"14 MiB","numgc":268,"total-goroutine":9,"request-id":"7c84d2d5-515b-4453-98cb-6694c50a79c8"}


We would greatly appreciate any assistance or recommendations for resolving this issue.

Thank you!

@j2gg0s
Copy link

j2gg0s commented May 8, 2024

display?path=/media:a5784db13a88c445f7bb12cd519f7fbcfd8e2fe702 will go to the directory to find file /media: a5784db13a88c445f7bb12cd519f7fbcfd8e2fe702 . I guess this file not exist.

base_url only affect url of generated image, such as http://nginx-media-service.stage-namespace:80/3f9a22c50c62f49acd8f8a88b7d40bef

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants