Add fixFilePermissions function: Implement a new command to fix file permissions for a specified domain in the CyberPanel CLI. Update documentation to include CLI command reference.

https://github.com/usmannasir/cyberpanel/pull/1321
This commit is contained in:
Master3395
2025-09-20 19:25:16 +02:00
parent 14bf478024
commit e8164cf13c
4 changed files with 791 additions and 141 deletions

View File

@@ -1049,6 +1049,19 @@ def main():
cyberpanel.deleteDNSRecord(args.recordID)
## Fix File Permission function
elif args.function == "fixFilePermissions":
completeCommandExample = 'cyberpanel fixFilePermissions --domainName cyberpanel.net'
if not args.domainName:
print("\n\nPlease enter the domain. For example:\n\n" + completeCommandExample + "\n\n")
return
from filemanager.filemanager import FileManager
fm = FileManager(None, None)
fm.fixPermissions(args.domainName)
## Backup Functions.
elif args.function == "createBackup":