Ticket: R2 Bucket Upload Issue: Credentials Updated, Still No Media
@HeinzSchrot Just created a ticket
Question: Hi, I'm experiencing the same issue, that media does not get uploade to r2 bucket. this is my env. the bucket ist empty :/ Thanks! # https://docs.postiz.com/configuration/r2 CLOUDFLARE_ACCOUNT_ID: "sdfsdfsdfdsfsd" CLOUDFLARE_ACCESS_KEY: "sdfsfsdfsdf" CLOUDFLARE_SECRET_ACCESS_KEY: "sdfdsfsdfdsfsdf" CLOUDFLARE_BUCKETNAME: "postiz" CLOUDFLARE_BUCKET_URL: "https://sdfsdfsdfdsfsd.eu.r2.cloudflarestorage.com/" CLOUDFLARE_REGION: "EEUR"
Attempted: issued new credentials.
Working On: getting the bucket to work
Take it from here @Mod π₯
Question: Hi, I'm experiencing the same issue, that media does not get uploade to r2 bucket. this is my env. the bucket ist empty :/ Thanks! # https://docs.postiz.com/configuration/r2 CLOUDFLARE_ACCOUNT_ID: "sdfsdfsdfdsfsd" CLOUDFLARE_ACCESS_KEY: "sdfsfsdfsdf" CLOUDFLARE_SECRET_ACCESS_KEY: "sdfdsfsdfdsfsdf" CLOUDFLARE_BUCKETNAME: "postiz" CLOUDFLARE_BUCKET_URL: "https://sdfsdfsdfdsfsd.eu.r2.cloudflarestorage.com/" CLOUDFLARE_REGION: "EEUR"
Attempted: issued new credentials.
Working On: getting the bucket to work
Take it from here @Mod π₯
21 Replies
@HeinzSchrot do you want to use local uploading instead?
or minio, whatever is working π
So just out the new docs
We have changed how this things work
so this:
Your upload directory path if you host your files locally, otherwise Cloudflare will be used.
#UPLOAD_DIRECTORY=""
Your upload directory path if you host your files locally, otherwise Cloudflare will be used.
#NEXT_PUBLIC_UPLOAD_STATIC_DIRECTORY=""
UPLOAD_DIRECTORY="you local path like /users/documents/uploads"
NEXT_PUBLIC_UPLOAD_STATIC_DIRECTORY="/uploads"
outside of the container
And STORAGE_PROVIDER="local"
Are you going to use it for production usage?
jes, but were just a small company
after composing up again, die postiz container is still looking for cloudflare
| β¨― upstream image response failed for https://dsasd.eu.r2.cloudflarestorage.com/LIKRfgsZUi.jpeg 400
ok, I tried cloudflare again. the images are getting uploaded now. But requesting the images throw a error 400
Did you set CORs policies on your Cloudflare bucket?
yes - went back to local, forgot to add the volume. now it works π
thanks!
Awesome π
Yeah I was gonna say in a container, its just /uploads
Cool, I recommend volumes instead of Cloudflare
Less to go wrong!
Do you need help with anything else?
I still do get those errors:
}
postiz | β¨― The requested resource isn't a valid image for /icons/platforms/undefined.png received text/html; charset=utf-8
postiz | β¨― The requested resource isn't a valid image for /icons/platforms/undefined.png received text/html; charset=utf-8
postiz | Email sender information not found in environment variables
postiz | β¨― TypeError: fetch failed
postiz | at node:internal/deps/undici/undici:13178:13
postiz | at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
postiz | at async fetchExternalImage (/app/node_modules/next/dist/server/image-optimizer.js:565:17)
postiz | at async NextNodeServer.imageOptimizer (/app/node_modules/next/dist/server/next-server.js:650:48)
postiz | at async cacheEntry.imageResponseCache.get.incrementalCache (/app/node_modules/next/dist/server/next-server.js:182:65)
postiz | at async /app/node_modules/next/dist/server/response-cache/index.js:90:36
postiz | at async /app/node_modules/next/dist/lib/batcher.js:45:32 {
postiz | [cause]: ConnectTimeoutError: Connect Timeout Error
postiz | at onConnectTimeout (node:internal/deps/undici/undici:2331:28)
postiz | at node:internal/deps/undici/undici:2283:50
postiz | at Immediate._onImmediate (node:internal/deps/undici/undici:2315:13)
postiz | at process.processImmediate (node:internal/timers:483:21)
postiz | at process.callbackTrampoline (node:internal/async_hooks:130:17) {
postiz | code: 'UND_ERR_CONNECT_TIMEOUT'
postiz | }
but posting to instagram works like intended. This is postiz frontend only i guess
What is the path saved in the db for the file?
Hey @HeinzSchrot , let us know when you're around, we're happy to help
Next time, would you mind posting code blocks with 3x ` marks, that way Discord formats as code
@HeinzSchrot did you solve your problem?
Hi @Nevo David I was not able to look into it. Gonna do tomorrow.
Thanks
Hi ,
this is the db:
this is the log
if you open the link, you can access it?
Yes
and are you still using cloudflare for images, not local storage?