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

/var/lib/marzban/assets/ folder included in backup file making it larger #1636

Open
qirmizialma opened this issue Feb 9, 2025 · 2 comments

Comments

@qirmizialma
Copy link

با سلام و خسته نباشید

:وقتی ما جئو فایلهای مربط به مسدود کردن سایتهای ایرانی رو با توجه به این داکیومنت
https://gozargah.github.io/marzban/fa/examples/blocking-rules
دانلود میکنیم یک فولدری به نام
/var/lib/marzban/assets/
تشکیل میشه .
مشکلی که هست اینه که روبات تلگرام موقع بکاپ از این فولدر هم بکاپ میگیره در حالی که هیچ نیازی به این کار نیست و این باعث میشه حجم فایل چندین .
برابر بشه
از طرفی هم نمیشه مسیر این فولدر رو جابه جا کرد

Hello and thank you for your efforts

When we download the Geo files related to blocking Iranian websites according to this document:
https://gozargah.github.io/marzban/fa/examples/blocking-rules
A folder named /var/lib/marzban/assets/ is created.

The issue is that the Telegram bot also includes this folder in the backup process, even though there is no need for it. This causes the backup file size to increase significantly.

On the other hand, it is not possible to change the location of this folder.

@mdjvd
Copy link

mdjvd commented Feb 20, 2025

در واقع به این فولدر و فایل‌هاش نیاز هست اگر بخواین بکاپ رو روی سرور جدید بالا بیارین اگه این فایل‌ها نباشن موقع اجرای مرزبان ارور میگیرین، البته که میشه روی سرور جدید دوباره فایل‌ها رو دانلود کرد.
ولی برای exclude کردن این فولدر، اگر از اسکریپت ac-lover برای بکاپ استفاده می‌کنید، میتونید فایل اسکریپت رو ادیت کنید:

nano ~/ac-backup-m.sh

خط زیر رو به انتهای خط سوم که دستور zip -r هست اضافه کنید:

-x /var/lib/marzban/assets/\*

که به همچین شکلی در بیاد:

zip -r /root/ac-backup-m.zip /opt/marzban/* /var/lib/marzban/* /opt/marzban/.env -x /var/lib/marzban/mysql/\* -x /var/lib/marzban/assets/\*

@qirmizialma
Copy link
Author

از روبات خود گذرگاه که تو این داکیومنت قرار داده شده استفاده میکن. ای سی لاور نیست
https://gozargah.github.io/marzban/fa/examples/backup

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

2 participants