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

Thumbnails do not appear in media library #7

Open
henriquezolini opened this issue Sep 5, 2023 · 4 comments
Open

Thumbnails do not appear in media library #7

henriquezolini opened this issue Sep 5, 2023 · 4 comments

Comments

@henriquezolini
Copy link

henriquezolini commented Sep 5, 2023

I'm using your plugin and even with the settings but the thumbnails do not appear in media library. can you help me?

image

image

plugins.js

module.exports = ({ env }) => ({
  upload: {
    config: {
      provider: "strapi4-ftp-provider",
      providerOptions: {
        host: env("FTP_HOST"),
        port: env("FTP_PORT"),
        user: env("FTP_USER"),
        password: env("FTP_PASSWORD"),
        secure: env.bool("FTP_SECURE", false),
        path: env("FTP_BASE_PATH"),
        baseUrl: env("FTP_BASE_URL"),
      },
    },
  },
});

middlewares.js

module.exports = ({ env }) => [
  "strapi::errors",
  {
    name: "strapi::security",
    config: {
      contentSecurityPolicy: {
        useDefaults: true,
        directives: {
          "connect-src": ["'self'", "https:"],
          "img-src": ["'self'", "data:", "blob:", env("FTP_BASE_URL")],
          "media-src": ["'self'", "data:", "blob:", env("FTP_BASE_URL")],
          upgradeInsecureRequests: null,
        },
      },
    },
  },
  "strapi::cors",
  "strapi::poweredBy",
  "strapi::logger",
  "strapi::query",
  "strapi::body",
  "strapi::session",
  "strapi::favicon",
  "strapi::public",
];

.env

FTP_HOST=myserver
FTP_PORT=21
FTP_USER=myuser
FTP_PASSWORD=mypassword
FTP_SECURE=true
FTP_BASE_PATH=/
FTP_BASE_URL=https://mydomain.com.br/strapi_uploads
@henriquezolini
Copy link
Author

I just found the problem, you forgot to update the npm version with your latest changes. Could you update?
My interim solution was to add github url in package.json

"strapi4-ftp-provider": "https://github.com/BaptisteAg/strapi4-ftp-provider"

@fretif
Copy link

fretif commented Sep 22, 2023

@BaptisteAg Can you release a new npm version with your latest changes ?

@henriquezolini
Copy link
Author

The project seems abandoned, I'm upset, my clients can no longer bear paying Cloudnary's absurd prices. This would be an excellent option.

@yanickdi
Copy link

yanickdi commented May 9, 2024

i can confirm, had the same problem
@henriquezolini you may use npm i https://github.com/BaptisteAg/strapi4-ftp-provider

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

3 participants