Deutlich später. Noch einmal den kühlen Boden unter den Füßen spüren. Eine Armlänge nur von Haustür und erleuchtetem Treppenhaus entfernt wirkt die Nacht weniger düster, auch wenn die Augen kaum weiter als bis zum Zaun blicken und der Ort dahinter vollständig mit der mondmatten Finsternis verschmilzt. (Imaginäre Musik. Ein Hund bellt. Die Müdigkeit drückt schwer auf das Bewusstsein.)
This is pretty amazing! People are taking my WordPress plugin that lets you warn site visitors if they don't have an ad-blocking browser plugin installed, and making versions of the project for non-WordPress sites.
It's made for WordPress but the idea is so dead simple that it can be integrated in almost anything with some work (if nobody else did that work already :D)
Just thinking of ditching nextcloud and its just too much for my family use. All i needis carddav, caldav and file sync. Have a Debian VM running on Scale and was thinking of using Cloudron docker install. Is this the way others are installing on VMs?
That’s not entirely correct. PhotoPrism offers WebDAV and SAMBA protocols, and their docs state that clearly: docs.photoprism.app/user-guide/…/mobile-devices/#… Furthermore, you can always sync files to the server via other means (e.g. SyncThing).
Though the plugin still has some rough edges and missing features, overall I think it is working pretty well for what I wanted. When I post on joelencioni.com, I can see my post in my Mastodon feed pretty quickly—though sometimes the formatting isn’t the best but I suppose that’s just the way it is. And, commenting is bi-directional: replies from Mastodon show up as comments on my blog, and replies to those comments from my blog show up as replies on Mastodon. Great!
The ActivityPub plugin watches for when the client sends a request HTTP header that is asking for content with the mime type of “application/activity+json”. If that type of content is requested, then instead of responding with the web page, it will respond with some JSON data meant for machine consumption instead of human consumption. This is how the syndication works, and that all seems fine.
However, I have been bumping into an issue due to the way this all works together with the CDN I chose for page caching, CloudFlare.
This is what one of my blog posts looks like when the ActivityPub JSON is served instead of the web page.
The problem is that CloudFlare will cache the first version of the page that is requested and serve that up to everyone going forward, regardless of the type of content being requested.
Thankfully, I found a new approach to try. Using CloudFlare workers, I can program the CDN to vary the content based on this header with this bit of code:
export default { async fetch(req) { const acceptHeader = req.headers.get('accept'); const url = new URL(req.url); if (acceptHeader?.indexOf("application/activity+json") > -1) { url.searchParams.append("activitypub", "true"); } return fetch(url.toString(), { cf: { // Always cache this fetch regardless of content type // for a max of 5 minutes before revalidating the resource cacheTtl: 300, cacheEverything: true, }, }); }}
This tells CloudFlare to look at the accept header, and if it has “application/activity+json”, it will add “activitypub=true” to the request query string (the part of the URL after the question mark) behind the scenes, which effectively makes it a different URL. This allows the different content to be cached and served up differently, which I think should solve the issue for me for good. If you still see this problem, please let me know!
I've written an ActivityPub server which . That's all it does. It won't record favourites or reposts. There's no support for following other accounts or receiving replies. It cannot delete or update posts nor can it verify signatures. It doesn't have a database or any storage beyond flat files.
But it will happily send messages and allow itself to be followed.
This shows that it is totally possible to broadcast fully-featured ActivityPub messages to the Fediverse with minimal coding skills and modest resources.
I wanted to create a service a bit like FourSquare. For this, I needed an ActivityPub server which allows posting geotagged locations to the Fediverse.
I didn't want to install a fully-featured server with lots of complex parts. So I (foolishly) decided to write my own. I had a lot of trouble with HTTP Signatures. Because they are cursed and I cannot read documentation. But mostly the cursed thing.
Creating a minimum viable Mastodon instance can be done with half a dozen static files. That gets you an account that people can see. They can't follow it or receive any posts though.
I wanted to use PHP to build an interactive server. PHP is supported everywhere and is simple to deploy. Luckily, Robb Knight has written an excellent tutorial, so I ripped off his code and rewrote it for Symfony.
The structure is relatively straightforward.
/.well-known/webfinger is a static file which gives information about where to find details of the account.
/[username] is a static file which has the user's metadata, public key, and links to avatar images.
/following and /followers are also static files which say how many users are being followed / are following.
/posts/[GUID] a directory with JSON files saved to disk - each ones contains the published ActivityPub note.
/photos/ is a directory with any uploaded media in it.
/outbox is a list of all the posts which have been published.
/inbox is an external API endpoint. An ActivityPub server sends it a follow request, the endpoint then POSTs a cryptographically signed Accept message to the follower's inbox. The follower's inbox address is saved to disk.
/logs is a listing of all the messages received by the inbox.
/new is a password protected page which lets you write a message. This is then sent to...
/send is an internal API endpoint. It constructs an ActivityPub note, with attached location metadata, and POSTs it to each follower's inbox with a cryptographic signature.
That's it.
The front-end grabs my phone's geolocation and shows the 25 nearest places within 100 metres. One click and the page posts to the /send endpoint which then publishes a message saying I'm checked in. It is also possible to attach to the post a short message and a single photo with alt text.
There's no database. Posts are saved as JSON documents. Images are uploaded to a directory. It is single-user, so there is no account management.
I've raised an issue on Mastodon to see if they can support showing locations in posts. Hopefully, one day, they'll allow adding locations and then I can shut this down.
The code needs tidying up - it is very much a scratch-my-own-itch development. Probably riddled with bugs and security holes.
I've been posting on Mastodon for 10 days already and I like it a lot, more and more people are participating and responding to me.
Very surprised in a good way by the application and the community !
9pm and on. Bach, Vivaldi, Händel: Echoes from another age, or: There's always something to be found in music. Also, watching the flickering of lights in a different city. Unfamiliar street patterns. Traffic of a late day. Fireworks of the impatient ones. Business as usual.
Always surround these binary operators with a single space on either side, assignment (=)...
Don’t use spaces around the = sign when used to indicate a keyword argument, or when used to indicate a default value for an unannotated function parameter...
When combining an argument annotation with a default value, however, do use spaces around the = sign...
just unfollowed someone because they #wont#stop#hashtagging#every#other#word, lmao. PLEASE STOP, OH MY GOD IS THAT ANNOYING. It's more obnoxious than old American comics that BOLD three words a sentence (which bothers me so much I struggle to even read the comment). Treat hashtags like you're shouting them into a crowded audience... do you really need TO shout random WORDS that ARE extremely COMMON and don't MAKE any kind of POINT?
Oh! It's not every day you get a shoutout from the #OED!
"Some contributors have been of particular value, either because of the volume of their contributions or because they have consistently supplied quotations of particular significance; in this capacity we would like to thank: Chris Collier, Paul Cullen, Bill Mullins, Bryn Parry, Sir Edward Playfair, Barry Popik, Michael Quinion, David Shulman, Stuart Silverstein, Hugo van Kemenade, Peter Wexler, and Ben Zimmer."
Is Radicale the way forward? (www.cloudron.io)
Just thinking of ditching nextcloud and its just too much for my family use. All i needis carddav, caldav and file sync. Have a Debian VM running on Scale and was thinking of using Cloudron docker install. Is this the way others are installing on VMs?