??????????????
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 173

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 174

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 175

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 176

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 177

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 178
σ ΰUdac@`sΆddlmZmZmZeZdZddlZddlm Z ddl m Z m Z ddl mZmZmZddlmZmZddlmZd efd „ƒYZdS( i(tabsolute_importtdivisiontprint_functions¦ author: Matt Clay connection: lxd short_description: Run tasks in lxc containers via lxc CLI description: - Run commands or put/fetch files to an existing lxc container using lxc CLI version_added: "2.0" options: remote_addr: description: - Container identifier default: inventory_hostname vars: - name: ansible_host - name: ansible_lxd_host executable: description: - shell to use for execution inside container default: /bin/sh vars: - name: ansible_executable - name: ansible_lxd_executable N(tfind_executable(tPopentPIPE(t AnsibleErrortAnsibleConnectionFailuretAnsibleFileNotFound(tto_bytestto_text(tConnectionBaset ConnectioncB`s\eZdZdZeZdZd„Zd„Zd ed„Z d„Z d„Z d„Z RS( s lxd based connections tlxdtrootcO`stt|ƒj||||Ž|jj|_tdƒ|_|jsUtdƒ‚n|jj dk rŒ|jj dkrŒ|j j dƒndS(Ntlxcslxc command not found in PATHRs?lxd does not support remote_user, using container default: root( tsuperR t__init__t _play_contextt remote_addrt_hostRt_lxc_cmdRt remote_usertNonet_displaytwarning(tselft play_contextt new_stdintargstkwargs((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyR0s $cC`sEtt|ƒjƒ|jsA|jjdd|jƒt|_ndS(s$connect to lxd (nothing to do here) u'ESTABLISH LXD CONNECTION FOR USER: rootthostN(RR t_connectt _connectedRtvvvRtTrue(R((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyR <s c C`sGtt|ƒj|d|d|ƒ|jjdj|ƒd|jƒ|jd|jd|jj d|g}g|D]}t |dd ƒ^qr}t |dd d d ƒ}t |d t d t dt ƒ}|j |ƒ\}}t|ƒ}t|ƒ}|dkrtd|jƒ‚n|dkr7td|jƒ‚n|j||fS(s# execute a command on the lxd host tin_datatsudoableuEXEC {0}Rtexecs--s-cterrorstsurrogate_or_strictt nonstringtpassthrutstdintstdouttstderrs!error: Container is not running. scontainer not running: %sserror: not found scontainer not found: %s(RR t exec_commandRR"tformatRRRt executableR RRt communicateR Rt returncode( RtcmdR$R%t local_cmdtitprocessR,R-((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyR.Ds""'%    cC`sγtt|ƒj||ƒ|jjdj||ƒd|jƒtjj t |ddƒƒsot d|ƒ‚n|j dd||jd|g}g|D]}t |ddƒ^q™}t |d td td tƒ}|jƒd S( s put a file from local to lxd uPUT {0} TO {1}RR'R(sinput path is not a file: %stfiletpusht/R+R,R-N(RR tput_fileRR"R/RtostpathtisfileR RRRRR1(Rtin_pathtout_pathR4R5R6((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyR:]s%#%cC`s²tt|ƒj||ƒ|jjdj||ƒd|jƒ|jdd|jd||g}g|D]}t|ddƒ^qh}t |dt d t d t ƒ}|j ƒd S( s fetch a file from lxd to local uFETCH {0} TO {1}RR7tpullR9R'R(R+R,R-N( RR t fetch_fileRR"R/RRR RRR1(RR>R?R4R5R6((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyRAms %#%cC`s tt|ƒjƒt|_dS(s+ close the connection (nothing to do here) N(RR tclosetFalseR!(R((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyRBzsN(t__name__t __module__t__doc__t transportR#thas_pipeliningt default_userRR RR.R:RARB(((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyR )s   (t __future__RRRttypet __metaclass__t DOCUMENTATIONR;tdistutils.spawnRt subprocessRRtansible.errorsRRRtansible.module_utils._textR R tansible.plugins.connectionR R (((sB/usr/lib/python2.7/site-packages/ansible/plugins/connection/lxd.pyts