any instance admins care to help me? i honestly cannot find the public/system folder where user media is supposed to be uploaded and thus all uploads appear broken/404'd and idk what's wrong

boosts welcome and encouraged :boost_ok:

@numen It's supposed to be directly in the mastodon directory where the code sits.

On my system, I have Mastodon in ~/mastodon/
This folder contains files such as and and app.json

and user media is in four folders inside

the four folders are

Is this setup different from what you have on your server?

@zatnosk I was looking for it in the public folder within live, but i don't think i have a ~/mastodon/ folder. what installation guide did you use?

@numen my ~/mastodon/ folder is where I downloaded the git repository to.

I think I used a docker-based guide that was in the official docs years ago, and bombarded gargron with questions when I didn't understand something - unfortunately that's not an approach that's easily reproducible today.

@zatnosk I'm using the guide and the git repo downloads to live, i believe but there doesn't seem to be a system folder within public, not even in the github repo! but everything is set to route image uploads to system, so idk what's going on

cc @Gargron

@numen I think the folders should be generated during

RAILS_ENV=production bundle exec rake mastodon:setup

but I'm not certain, since I haven't looked at the code. I know it's possible to configure it to use Amazon S3 as a media backend, so that's why I assume it generates the local folder structure on setup (or on first start).

Are everything running under the correct user, and does that user have sufficient permissions to write to the live folder?

@zatnosk hm! maybe the fact that the folder is named live instead of mastodon is... somehow making it not generate?

@numen nah, that shouldn't be a problem; Mastodon should be using relative paths, so the location of the base folder is unimportant.

@zatnosk but the rake task is oriented to 'mastodon'; i know nothing about rails tho so it might be irrelevamt

@numen I'm pretty sure that name is only a namespace for the rake tasks, so they don't clash with other rake tasks from other software.

@zatnosk yup, actually trying to set up wasabi as an S3, and the user is a sudoer

@numen just being a sudoer might not be sufficient to let Mastodon create folders in the right places. The software will probably not even try sudo, so the user would need to either own the folder or be in a group that owns the folder.

But if you're configuring an external media host, that would probably explain why there's no media folders in the live directory; it should all be in the external storage.
I don't have any experience with Wasabi or Amazon though, so I can't help debug that :/

@zatnosk I'm thinking this might be the problem, but I thought sudo would be enough; what's the command for making the owner of the folder the mastodon user?

@numen chown is the command you need, probably using sudo. I'm not 100% sure about the arguments, because I'm on my phone, but chown --help might lead you in the right direction.

@numen huh? I think you're right that the folder should be read+write, but I don't think chown has anything to do with that?

chown changes which user and group owns the file.

If you want to change read/write/execute permission you need chmod.

@zatnosk you were right, both a lack of ownership and the s3 set up from the beginning were at fault. thank you so much! 💛

@zatnosk now federation's broken and i've run out of cert requests so i can't test and i'm aaaaa

@zatnosk from what i've seen, you sync local and remote folders, not directly store in the CDN, though i might be presuming too mucj

@numen Did you figure out your issue? If not, I can try to assist :)

@mhamzahkhan I did! But as soon as I fixed it:

1) federatiom broke
2) i ran out of letsencrypt certificate requests from previous failed reinstalls

so if you can assist with:
1) testing federation from the CLI
2) testing everything without a cert

i'd be super grateful

@numen Hmmm I'm not too sure how to test it without a cert. For federation, as far as I know, we can test it just by sending a message, and then replying.

@mhamzahkhan there appears to be a CLI client, perhaps I can toot test messages from there and try to follow and stuff? would i need a cert if i'm not on browser?

Sign in to participate in the conversation

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!