Replying to unknown

nostr:npub1ye5ptcxfyyxl5vjvdjar2ua3f0hynkjzpx552mu5snj3qmx5pzjscpknpr

Hello, can you help me with blossom-server and s3?

It uploads fine but errors out

May 30 17:48:54 nas npm[285989]: TypeError: Invalid URL

May 30 17:48:54 nas npm[285989]: at new URL (node:internal/url:797:36)

May 30 17:48:54 nas npm[285989]: at getBlobURL (file:///opt/blossom-server/build/helpers/blob.js:11:9)

May 30 17:48:54 nas npm[285989]: at getBlobDescriptor (file:///opt/blossom-server/build/api.js:28:14)

May 30 17:48:54 nas npm[285989]: at file:///opt/blossom-server/build/api.js:122:16

May 30 17:48:54 nas npm[285989]: at async file:///opt/blossom-server/build/api.js:69:5

May 30 17:48:54 nas npm[285989]: at async file:///opt/blossom-server/build/index.js:28:9

May 30 17:48:54 nas npm[285989]: at async cors (/opt/blossom-server/node_modules/@koa/cors/index.js:109:16) {

May 30 17:48:54 nas npm[285989]: code: 'ERR_INVALID_URL',

May 30 17:48:54 nas npm[285989]: input: 'd31bdfd72f28d8043ee45bac2b06543b851c8fefd195b4b50dd3efd0ade6ae8d.jpeg',

May 30 17:48:54 nas npm[285989]: base: 's3.poster.place'

May 30 17:48:54 nas npm[285989]: }

storage:

# local or s3

backend: s3

s3:

endpoint: s3.poster.place

port: 443

bucket: blossom

accessKey: xxx

secretKey: xxx

publicURL: https://s3.poster.place/

useSSL: true

I think the config might be missing the "publicDomain" field. its used to create the "url" on the blobs

There are a few fields in the config that are required, and I should probably add some checks in the app to make sure they are set correctly

There is an example config here https://github.com/hzrd149/blossom-server/blob/master/config.example.yml

Reply to this note

Please Login to reply.

Discussion

Ty. The example is wrong because if you put endpoint with https, blossom will fail to start and error out, you have to do it without https or http

I am using public URL and it still shows

May 30 18:40:22 nas npm[302150]: TypeError: Invalid URL

got it working with this config

publicDomain: ""

s3:

endpoint: s3.poster.place

bucket: blossom

accessKey: xxx

secretKey: xxx

useSSL: true

pathStyle: true

publicURL: s3.poster.place