Thanks I relocated this to the wiki. Hedgedocs was gone be too difficult to manage multiple contributors. https://wiki.lemmyadmin.site/home/PostgresMain#connect-to-the-database-in-the-docker-container
definitely, and since we've realized we're running the same images, it may not be a bad idea to team up around similar deployments. For instance I might as well standardize on the easy deploy project. I'm using ansible now but modified it to use ubergeek's arm64 images. might as well just use his whole project.
yep had to do that was initially getting "too many redirects."
I've wondered the same and thought they might be new since my last visit?
I put this site behind cloudflare in response to this post. Other than having to change SSL/TLS encryption mode to Full, it seemed easy. I turned on bot fight mode and I'm using the managed WAF ruleset that comes with the free tier. Any configuration recommendations anywhere in the panel?
you both probably have 'show read posts' (or something similar) disabled under user settings.
I'm replying from the balcony of my cruise ship so I'm unable to give this response the detail it deserves. And, we'd need to decide this as a group. But essentially as my backup, if there's an incident requiring a prompt action and I'm unreachable, you'd have credentials to do the needful.
Maybe we use a shared spreadsheet to track instance statuses including an in/out status for the primary admin. So if there's a new vulnerability, it's unpatched on the instance and the primary is out, the backup or the backup to the backup handles it.
Lemmy Theming - Instructions
cross-posted from: https://tkohhh.social/post/4829
> Unfortunately, the official documentation on theming lemmy is severely lacking. I made some progress on getting it figured out today, so I wanted to share that with you all.
>
> This is by no means meant to be an exhaustive guide, but my hope is that it will at least get you going. I'm sure that I will say things that are incorrect, so please correct me if you know better!
>
> Background
>
> Lemmy uses Bootstrap-compatible theming. As far as I can tell, this means that it uses a pre-defined set of CSS classes. This is important because if you provide a CSS file that doesn't have all of the correct classes defined, it will break the layout of your lemmy.
>
> Your custom CSS needs to be saved in the bind mount for your lemmy-ui container. If you followed the install instructions on join-lemmy.org, the location will be /lemmy/volumes/lemmy-ui/extra_themes/
.
>
> Prerequisites
>
> In order to generate the correct CSS, you need a couple of things:
> - your customized Bootstrap variables, saved in an scss file
> - the Bootstrap scss files
> - the SASS compiler
>
> Let's go through each of these (last to first):
>
> The SASS compiler
>
> The SASS compiler needs to be installed on the machine you will use to generate your CSS files (it doesn't NEED to be the computer that lemmy is installed on, but it can be). Follow the install instructions relevant to you. I used the "Install Anywhere (Standalone)" instructions and installed SASS on the Ubuntu machine that is running my lemmy instance.
>
> The Bootstrap scss files
>
> These files need to be saved on the same machine as the SASS compiler. The Bootstrap download page has a button to download the source files ("Download source"). This will give you a zip folder, so unzip it. Within the unzipped files, the only directory you need to keep is /bootstrap-5.3.0/scss
. Save that folder in a place that makes sense for you. I put it in my home directory, so the path looks like ~/bootstrap-5.3.0/scss
. You'll need to reference this directory when you're creating your custom scss file.
>
> Your customized Bootstrap variables, saved in an scss file
>
> This is the fun part... you define your Bootstrap variables. I'm still a little unclear on which version of Bootstrap lemmy is using (and therefore which variables are valid), so I chose to start with one of lemmy's default themes as a starting point. I grabbed _variables.litely.scss
and litely.scss
from the lemmy-ui github repo as a starting point.
>
> You'll notice that litely.scss
is just importing variables.litely
as well as the Bootstrap scss files. You'll need to change the path of the Bootstrap scss files to the path where you saved your copy of the files. However, leave bootstrap
at the end of the file path, as this is actually referring to the bootstrap.scss
file within the Bootstrap scss directory.
>
> Generating the CSS file
>
> Once you have all of the prerequisites satisfied, you can generate your CSS files using the SASS compiler. Go to the directory where your customized scss file(s) are saved, and run this command (you added the SASS install directory to your PATH, right??):
>
> > sass [inputfile.scss] [outputfile.css] >
>
> This will generate a CSS file. However, pay attention, as there might be errors. If so, fix the errors until you can run SASS without any errors.
>
> Finally, drop the generated CSS file into your "extra_themes" directory. You'll now see your theme show up in the list of themes on your profile (it'll be the filename of your CSS file).
>
> ***************************
> And that's it! I hope somebody finds this helpful. Please let me know if there's anything I can clarify!
Thanks for writing this up. Saving it for when I need it!
A collection of notes that will hopefully be useful to any other admins attempting to scale horizontally
Mod self removal removes person_id 92
This image shows multiple attempts by now mod to leave. They go through the are you sure prompts and say yes but remain as a mod. Modlog image shows an unassociated user from a different instance is removed instead. That same user is removed when a different local mod tries to leave as mod. An admin from another instance reports they see removal of person_id 92 as well when their local tries to leave as mod.
If I check the request it shows person_id 92. {"community_id":3,"person_id":92,"added":false,"auth":"ey..."}
If I lookup person.id 92 in my db it shows the user referenced in the image, not my local user who was trying to leave as mod.
92 | sunspider | Sun-Spider
btw - you can paste that link into search and it will return you a home instance link to click. So that's a decent work around for now. But I'm all for home instance link rewrites.
you know you can easily scale up and down instance sizes on aws, or move your instance to, say oracle. I've done both of these. The Ansible installer makes it very easy to move. you just down your containers and copy over the volumes directory for the move.
With these options you can start small and free. It may take a while to grow to 100 users. A 2 vcpu 2GB ram t4g.small on aws seems more than adequate and there's a free trial through the end of the year. It's arm64 though so small changes to the ansible lemmy.yml. The free tier t2.micro at 1 cpu 1 GB ram seemed too small.
Oracle has an always free arm64 image with 4 cpu and 24 GB ram plus a generous boot disk and 200GB block storage so you might as well start there. It will probably last quite a while. Maybe all the way through 100 users. The only thing is while I know it's very easy to change your instance type on AWS, I haven't looked into it on Oracle. But again moving your instance is very easy.
I agree and would support a feature request for lemmy-ui if not already in place for this one.
you probably need to update config.hjson inside inventory/host_vars/<instance_name> ??
locally, in the lemmy-ansible/inventory... directory.
I really do trust both of these projects and the community mindedness of their owners. Does someone know how you'd go about verifying a 3rd party image hasn't diverged from the official project image?
hmm weird. This bot is announcing an 18.2 release (and I think people are installing it.) https://matrix.to/#/#lemmy-support-releases:discuss.online
But the repo is still showing 18.1 as the latest.
Much appreciated! Looking for this morning's release with the vulnerability fix.
As you're doing it anyway, if whoever is in charge of these things were agreeable to it, would you be willing to do the official Arm images under https://hub.docker.com/r/dessalines/lemmy? One key advantage is the official ansible deployment method would work without modification for Arm deployments.
Arm64 containers
Could we add officially supported Arm containers?
Oracle has a pretty generous always free service with Arm; 4 Arm vcpu, 24Gb RAM: https://www.oracle.com/cloud/free/#always-free
AWS has a pretty good free trial to the end of the year: https://aws.amazon.com/ec2/instance-types/t4/
I think it's generally true that Arm is more efficient and better for the environment.
There are 3rd party Arm images available and I'm running instances with these on AWS and Oracle, but they are not updated as frequently as the official images: https://hub.docker.com/r/masquernya/lemmy/tags
I know if I'm asking I should be ready to help, and I am. But this isn't something I know how to do.
so consider a smaller local instance like I'm setting up. If it's ever anything more than me and my mom it's gonna be a bunch of people I know and their friends. And if my instance is their entry point to the fediverse then yeah I want it to be as private as we can make it for them.
But also, even if someone's IRL identity was masked, I've only been around a week and I'm starting to recognize handles on the fediverse. Ideally we make friends here and it's a community for us.
Now imagine how humiliating it would be if someone malicious gained control over an instance and published everyone's subscriptions/likes etc. Sure more savvy users probably do have separate accounts but honestly most will not.
the point is not to encrypt your user id, check this out if you haven't seen it I think I explain it better here: https://lemmyadmin.site/comment/46. It's a lot more privacy. And thinking as an admin that wants to provide a safe space for my users, I think it's worth the effort. I took a very quick look at the tables related to person and I'd bet you could treat these similarly to community_follower:
TABLE "comment_like" CONSTRAINT "comment_like_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "comment_saved" CONSTRAINT "comment_saved_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "community_block" CONSTRAINT "community_block_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "community_follower" CONSTRAINT "community_follower_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "person_follower" CONSTRAINT "person_follower_follower_id_fkey" FOREIGN KEY (follower_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "post_like" CONSTRAINT "post_like_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "post_read" CONSTRAINT "post_read_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "post_saved" CONSTRAINT "post_saved_person_id_fkey" FOREIGN KEY (person_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "private_message" CONSTRAINT "private_message_creator_id_fkey" FOREIGN KEY (creator_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
TABLE "private_message" CONSTRAINT "private_message_recipient_id_fkey" FOREIGN KEY (recipient_id) REFERENCES person(id) ON UPDATE CASCADE ON DELETE CASCADE
also, you could modify subscription counters so you had a count of subscribers from an instance without knowing who they were.
what is the problem with votes btw? Someone else just mentioned those should be private too in the chat where I first raised this.
There, you've already found a reasonable way around it! 😀
Feature Request: User Privacy
Hi every lemmy. I've just stood up a couple new instances and I've been hanging out in the Admin chat over at https://matrix.to/#/#lemmy-support-general:discuss.online. Someone there asked if they could view subscriptions so I wrote and shared the sql query. (could I have done better on the joins with 2 joins to instance?)
!sql query to all user subscriptions
And that's when I realized what an invasion of privacy that is. Maybe there's an easier way to do it but could we add optional support for user key pairs, so that if I associated a public key with my account, everything related to me in the db gets hashed with that key? Then I provide my private key at login?
I say optional because I know that's hard for a lot of folks. But maybe there's a way to make it easier with something like letsencrypt at sign up so it would be trivial for everyone to do it.. Or maybe there's a way to do it globally with a central key common to all instances, perhaps paired with instance specific keys?
I understand there's other aspects of user activity that would be best made private to so this could also work, say for votes or whatever else.
Sheet1 Lemmy Instance,Instance Admin Profile,Matrix User,Need Backup Admin,Willing to be a Backup Admin,Availability (UTC) <a href="http://boulder.ly/">boulder.ly</a>,<a href="https://boulder.ly/u/jbernardini">https://boulder.ly/u/jbernardini</a>,@0ll0l0l00ll000l0:matrix.org,Y,Y,1PM - 5AM UTC <a...
Register your interest here if you'd like to join a team of smaller instance admins backing each other up. So if it's the middle of the night or we're on vacation, someone we trust from the federation of small instance administrators can secure our sites if we're unavailable.
Lemmy Admin Wiki
free to read and edit: wiki.lemmyadmin.site Please add your tips!