$87 GRAYBYTE WORDPRESS FILE MANAGER $71

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/imunify360/venv/lib/python3.11/site-packages/clcommon/cpapi/

HOME
Current File : /opt/imunify360/venv/lib/python3.11/site-packages/clcommon/cpapi//utils.py
import sys
from functools import wraps
from clcommon.const import Feature
from clcommon.cpapi import is_panel_feature_supported

from clcommon.lib.cledition import (
    CLEditionDetectionError,
)

__all__ = (
    "skip_without_lve",
    "lve_supported_or_exit",
)


_SKIP_MESSAGE = (
    "Command is skipped as LVE feature is not supported in current environment\n"
    "Refer to https://docs.cloudlinux.com/solo/introduction/#cloudlinux-os-editions-comparison for more info"
)


def skip_without_lve():
    try:
        # we still have some utils that could be run
        # under user (e.g cloudlinux-selector)
        if not is_panel_feature_supported(Feature.LVE):
            print(_SKIP_MESSAGE)
            sys.exit(0)
    except CLEditionDetectionError as e:
        print(f"Error: {e}")
        sys.exit(1)


def lve_supported_or_exit(f):
    @wraps(f)
    def inner(*args, **kwargs):
        if not is_panel_feature_supported(Feature.LVE):
            print(_SKIP_MESSAGE)
        else:
            return f(*args, **kwargs)

    return inner

Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
5 Aug 2025 4.30 AM
root / root
0755
GeneralPanel
--
5 Aug 2025 4.30 AM
root / root
0755
__pycache__
--
5 Aug 2025 4.30 AM
root / root
0755
cache
--
5 Aug 2025 4.30 AM
root / root
0755
plugins
--
5 Aug 2025 4.30 AM
root / root
0755
__init__.py
14.542 KB
4 Jul 2025 8.31 PM
root / root
0644
apilink.py
0.261 KB
4 Jul 2025 8.31 PM
root / root
0644
clcpapi.py
3.643 KB
4 Jul 2025 8.31 PM
root / root
0644
const.py
0.499 KB
4 Jul 2025 8.31 PM
root / root
0644
cpapicustombin.py
2.123 KB
4 Jul 2025 8.31 PM
root / root
0644
cpapiexceptions.py
1.748 KB
4 Jul 2025 8.31 PM
root / root
0644
panel_hooks_lib.py
1.225 KB
4 Jul 2025 8.31 PM
root / root
0644
pluginlib.py
7.57 KB
4 Jul 2025 8.31 PM
root / root
0644
utils.py
1.029 KB
4 Jul 2025 8.31 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF