C d dl mZ d dlZd dlZd dlmZ d dlmZ d dl m
Z
mZ d dlm
Z
d dlmZmZ ee Z e
j d e
j G d d
e
ZdS ) )absolute_importN)deepcopy)gettext)CloudlinuxWposUserparser)user_cli_version_registry)ALL_OPTIMIZATION_FEATURESFeature1c e Zd ZdZd Ze d ed ede j
v e d ed ed e ed
d Ze ed
d
Z
e d ed edd eD e d ed ed e d ed ed e ed
d Ze d ed d e d ed d e d ed ed e d ed ed e d ed edd eD e dej dd e ed!
d" Ze d#g ed$ ddd fd%g ed& ddd fgd' e d( ed) dde j
vode j
v* e d ed+ edd(e j
v, e d ed- ed(e j
v e ed.
d/ Ze d%g ed0 ddfd#g ed1 ddfgd' e d ed2 ed e ed3
d4 Zd5S )6CloudlinuxWposUserV1a:
We announced those commands in public doc as api-version=1,
it means that we make any changes to CLI cautiously:
- if you are making change which could break backward compatibility (e.g - rename parameter) ->
you should create new class e.g CloudlinuxWposAdminV2 and override needed methods
c 6 t | S N)versioned_parser
parse_args)selfargvs "py/clwpos/cli_versions/user_api.py_parse_argsz CloudlinuxWposUserV1._parse_args$ s **4000 z--domainzUser's wordpress domainz --wp-path)helptyperequiredzPath to user's wordpressFzShows info about all Accelerate optimization features for WordPress sites, use '--domain' option to get info for a single domain and '--wp-path' option to get info for a single website)r c * | S r )_getr s r getzCloudlinuxWposUserV1.get' s yy{{r z1Disables and uninstalls module for ALL user sitesc * | S r )_disable_allr s r disable_allz CloudlinuxWposUserV1.disable_all0 s """r z --featurezOptimization feature to disableTc 6 g | ]}| S to_interface_name.0features r