nostr:npub1l5sga6xg72phsz5422ykujprejwud075ggrr3z2hwyrfgr7eylqstegx9z i know you done an all nighter but i fixed that favicon thing in the lerproxy

the code you wrote was trying to serve it from the #orly but it needed to be adjacent to the nostr.json handling in the reverse proxy. i have added a default icon based on the owl pic and if you put favicon.ico in the same directory as the nostr.json from the mapping.txt configuration, it will serve that instead.

as you can see on my #jumble notes i now have an ORLY owl instead of a check badge

Reply to this note

Please Login to reply.

Discussion

btw, to explain why it's called "lerproxy" was i was going to add URL rewriting to it, and it is forked from a reverse proxy called "leproxy" which is for "lets encrypt proxy" as it gets TLS certs for you automatically if they match the address the DNS record points to

i added the ability to serve your own TLS certs, (mleku.dev is from sectigo RSA) and nostr NIP-05 and Go vanity import redirects (these allow me to use orly.dev as the address for the internal imports, it's prettier, and i can switch away from github to my own hosting and not have to change every reference in the code.

oh noes, jumble uses favicons? doh.. or is this a jumble fork that does it?

i had hoped favicon would go bye bye in deference to nip11 image 😭 because they are so hard to make (like 5 diff images n stuff)

ohh for nip05, yep i see em now 😭

nice huh?

i've just bumped the v0.6.2 tag so there will be a binary release for it. the linux binaries are static so you can use them in a bare metal container without installing anything, or run the server on ancient versions of linux for whatever reason, without libc version problems

this explains why ive been seeing my 21 favicon for the nip05s.. doh.

yeah that's what made me realise that it was happening and i was like "i wannan"

i now has

also, yeah, your current nip-05 from rogue.earth has one as well, i guess the domain has one being served.

the reverse proxy i made is nice tho, does go vanity redirects as well as nip-05 serving, and you can also do lots of other neat things, it does letsencrypt certs automatically for you, you can set your own custom certs and they have precedence so you can set a custom cert with a wildcard and all subdomains from a wildcard will use it (i forget exactly how i did that, but it's there anyway)

it does thats why i didnt notice, i use rogue earth and its a sailboat..

fuck favicons damnit.. nip05 should have image in the json 😭

haha well it's HTTP standard so idk why clutter up the spec

because supporting favicon spec means image processing into 5 diff formats and weird urls that every device and browser treats differently. i guess i will just go read which one jumble uses.

idk, it just uses the windows favicon.ico and all web apps support this at least.

it's not compulsory to support any other formats like the apple stupid shit

there is honestly very few apps that even have a reason to support a higher resolution image. there was this kinda aspirational movement at one point to make web apps into first class citizens in launchers and such especially on mobiles but it got overtaken by proper apps

so... no 50mb animated gif favicons? for PWAs? 😂

yeah i think that's mainly what these things are even for, PWAs. like that button on chrome that lets you install a page as an app on your desktop, on mobile and pc

also, they only support png and ico files, i don't think animated gifs are in the spec

Your NIP-05 seems to be messed-up, now. Shows the "!" in Jumble.

Oh, nevermind. Now it renders correctly.

i figured it was cached. i only just switched it over half an hour ago

weird, idk, try refreshing, it works on mine now

This is interesting for Alex, too, nostr:npub1wqfzz2p880wq0tumuae9lfwyhs8uz35xd0kr34zrvrwyh3kvrzuskcqsyn . Then we don't have to define badges. We can pull directly from the domain.

currently it only has favicon.ico, the spec includes a range of other formats... they can be supported for larger displays of the thing... i just did the favicon on a guess that was the thing it was requesting

Could do the one from the relay NIP and fall back to favicon. Increases likelihood to find some relevant icon someplace.

yeah, i figured that was the logic behind why you put the handler in orly, no, the nip-05 is in the reverse proxy, you pretty much are not gonna be running orly without it btw.

but yeah, i guess it would make sense to serve the icon set from the relay as well. the standard in NIP-11 doesn't stipulate format, basically you can put jpg or webp or png in there. but it's just the relay, not the nip-05

in theory, you could bundle it all into one thing, but i'd rather keep them separated, personally. i usually need go vanity redirects and static file hosting as well and that's already in lerproxy

Nip-11 captures the icon for relay subdomains. The 21 icon is from nostr1.com, but theforest.nostr1.com actually has a picture of trees.

yeah, i figured that nostr:npub10npj3gydmv40m70ehemmal6vsdyfl7tewgvz043g54p0x23y0s8qzztl5h had used some common type of reverse proxy that puts them on the domains by default, probably for his web app.

and yeah, probably the web server that has the 21 icon is the one that does the nip-05s

it's tied to the nip-05 in jumble so it is simplest to just add it to the handler for the nip-05

It's because so far, I have been able to avoid storing user uploaded images. Everything in relay tools is image links. The reasoning for that is to avoid cloud lock-in and image synchronization or processing within the cluster. (each frontend would need a copy of these user uploaded images once you go down this path).

favicons kindof breaks this, ... more likely i would just pick a better icon than the 21. like a checkmark, because self hosting is king, and anything making that more complicated is not ideal.

and i pushed hard to get rid of favicons displays in all clients for relays for this reason, and now that i realize what jumble is doing, i'll probably try to push against that as well.. tho with relays i did not have to change nip11 i just had to get clients to use it. with this, it would probably need nip05 to have it. favicon fallback, sure thats fine. anyway, the price we pay for a tiny little image eh? 🕊️

Our implementation was grabbing NIP-11, but many relays don't have it. Same for favicons. Best to try both.

i baked the icon into the reverse proxy, and you can override it by adding the file next to the nostr.json :)

Did an all-nighter and then woke up and refactored the whole thing. 😂

Should be better, now.

yeah, i'm quitting caffeine now, so i'm gonna be going to bed a bit after sunset instead of running on until midnight.

code quality drops dramaatically with fatigue

Have to stop coding, for today, so that I don't give myself a heart attack.

Going grocery shopping. Later, gators.