Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"There is already a directory: /var/www/mastodon" when restoring #462

Open
kuba-orlik opened this issue Aug 2, 2024 · 0 comments
Open

Comments

@kuba-orlik
Copy link

Describe the bug

I have a volume mounted at /var/www/mastodon so I can easily scale it and keep up with the absurd amount of disk space that Mastodon uses. Thus, the directory /var/www/mastodon always exists. This makes the restore script fail:

https://paste.yunohost.org/raw/ibeyujacem

WARNING - There is already a directory: /var/www/mastodon

Context

  • Hardware: VPS bought online
  • YunoHost version: 11.2.26
  • I have access to my server: Through SSH
  • Are you in a special context or did you perform some particular tweaking on your YunoHost instance?: explained above

Steps to reproduce

  • mount a volume at /var/www/mastodon
  • install mastodon
  • backup mastodon
  • remove mastodon
  • restore mastodon

Expected behavior

Restore works

Current workaround

I'm trying to see if

sed -i 's/test ! -d $final_path/test   -d $final_path/' mastodon-pre-upgrade1.tar

will do the trick for me and bring my instance up.

I think a good fix would be throwing an error not if the directory just exists, but if it exists and is not empty

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant