%PDF- %PDF-
| Direktori : /proc/self/root/proc/3522530/root/usr/lib/python2.7/site-packages/salt/modules/ |
| Current File : //proc/self/root/proc/3522530/root/usr/lib/python2.7/site-packages/salt/modules/pecl.pyo |
�
���^c @@ s d Z d d l m Z m Z m Z d d l Z d d l Z y d d l m Z Wn! e
k
rq d d l m Z n Xd d l Z
d d l Z
d d l m Z i d d 6Z e j e � Z d Z d � Z e d
� Z e e d d � Z d
� Z d � Z d d � Z d S( u
Manage PHP pecl extensions.
i ( t absolute_importt print_functiont unicode_literalsN( t quote( t sixu listu list_u peclc C@ s# t j j j d � r t St d f S( Nu pecluE The pecl execution module not loaded: pecl binary is not in the path.( t saltt utilst patht whicht __virtualname__t False( ( ( s5 /usr/lib/python2.7/site-packages/salt/modules/pecl.pyt __virtual__! s c C@ st d j | � } t j j j | � r1 d | } n t d | d t �} | d d k r_ | d St j d � d
Sd S(
u.
Execute the command passed with pecl
u pecl {0}u yes ''u | u cmd.run_allt python_shellu retcodei u stdoutu, Problem running pecl. Is php-pear installed?u Nu yes '' | ( t formatR R t datat is_truet __salt__t Truet logt error( t commandt defaultst cmdlinet ret( ( s5 /usr/lib/python2.7/site-packages/salt/modules/pecl.pyt _pecl( s
u stablec C@ sN t | t j � r | g } n d j t | � � } | rd t d j | t d j | � � � d | �St d j | t d j | � � � d | �t | t � s� | g } n x� | D]� } t } d | k r� | j d � \ } } n d } t | � } xB | D]: } d j | | j | � d � } | | k r� t
} q� q� W| s� t Sq� Wt
Sd S(
u
.. versionadded:: 0.17.0
Installs one or several pecl extensions.
pecls
The pecl extensions to install.
defaults
Use default answers for extensions such as pecl_http which ask
questions before installation. Without this option, the pecl.installed
state will hang indefinitely when trying to install these extensions.
force
Whether to force the installed version or not
CLI Example:
.. code-block:: bash
salt '*' pecl.install fuse
u -d preferred_state={0}u {0} install -f {1}u R u {0} install {1}u /u {0}-{1}i N( t
isinstanceR t string_typesR
t
_cmd_quoteR t joint listR
t splitt Nonet list_t getR ( t peclsR t forcet preferred_statet peclt foundt channelt installed_peclst installed_pecl_with_version( ( s5 /usr/lib/python2.7/site-packages/salt/modules/pecl.pyt install9 s2 $$
c C@ s@ t | t j � r | g } n t d j t d j | � � � � S( u�
Uninstall one or several pecl extensions.
pecls
The pecl extensions to uninstall.
CLI Example:
.. code-block:: bash
salt '*' pecl.uninstall fuse
u
uninstall {0}u ( R R R R R
R R ( R"