HEX
Server: Apache
System: Linux dinesh8189 5.15.98-grsec-sharedvalley-2.lc.el8.x86_64 #1 SMP Thu Mar 9 09:07:30 -03 2023 x86_64
User: cgmgerenciamento1 (814285)
PHP: 8.1.26
Disabled: apache_child_terminate,dl,escapeshellarg,escapeshellcmd,exec,link,mail,openlog,passthru,pcntl_alarm,pcntl_exec,pcntl_fork,pcntl_get_last_error,pcntl_getpriority,pcntl_setpriority,pcntl_signal,pcntl_signal_dispatch,pcntl_sigprocmask,pcntl_sigtimedwait,pcntl_sigwaitinfo,pcntl_strerror,pcntl_wait,pcntl_waitpid,pcntl_wexitstatus,pcntl_wifexited,pcntl_wifsignaled,pcntl_wifstopped,pcntl_wstopsig,pcntl_wtermsig,php_check_syntax,php_strip_whitespace,popen,proc_close,proc_open,shell_exec,symlink,system
Upload Files
File: //usr/lib/python3.6/site-packages/sos/report/plugins/__pycache__/pulp.cpython-36.pyc
3

:�/e��@sBddlmZmZmZddlmZddlmZGdd�dee�ZdS)�)�Plugin�RedHatPlugin�	PluginOpt)�quote)�matchc@sDeZdZdZdZdZdZeddd	d
�gZdd�Z	d
d�Z
dd�ZdS)�Pulpz
Pulp platformZpulp�pulp-server�pulp-katello�python3-pulpcore�/etc/pulp/settings.py�tasks��z*number of tasks to collect from DB queries)�defaultZdesccCs�d|_d|_d|_d|_d|_d}y�x�td�j�j�D]�}td|�rt|j	�dj	d�d	j	d
�}|d	|_|d|_td|�r�d|j	�d|_td
|�r�d|j	�d|_|j
d�r�d}|r6|j
d�r6|j	�d|_d}q6WWntk
r�YnX|jddi�|j
ddddddddddg
�|jd�}|jd|�}|jd |�}|jd!|�}|jd"�}|jd#�}	|j|d$d%�|j|d&d%�|j|d'd%�|j|d(d%�|j|	d)d%�x2d*D]*}
|jd+|
�d,|j�d-�d.|
��d/��q�W|jd0d1d%�dS)2NZ	localhostZ27017�Fz/etc/pulp/server.confz^\s*seeds:\s+\S+:\S+��,r�:z\s*username:\s+\S+z-u %sz\s*password:\s+\S+z-p %sz[messaging]Tz	certfile:z/etc/default/pulp_workersZpulp_worker_defaultsz/etc/pulp/*.confz/etc/pulp/settings.pyz /etc/pulp/server/plugins.conf.d/z/etc/default/pulp*z/var/log/httpd/pulp-http.log*z/var/log/httpd/pulp-https.log*z(/var/log/httpd/pulp-http_access_ssl.log*z)/var/log/httpd/pulp-https_access_ssl.log*z'/var/log/httpd/pulp-http_error_ssl.log*z(/var/log/httpd/pulp-https_error_ssl.log*rza"DBQuery.shellBatchSize=%s;; db.task_status.find().sort({finish_time: -1}).pretty().shellPrint()"zP"DBQuery.shellBatchSize=%s;; db.reserved_resources.find().pretty().shellPrint()"ze"DBQuery.shellBatchSize=%s;; db.task_status.find({state:{\$ne: \"finished\"}}).pretty().shellPrint()"a�"function humanReadable(bytes) {  var i = -1;  var byteUnits = ['kB', 'MB', 'GB', 'TB', 'PB',                    'EB', 'ZB', 'YB'];  do {      bytes = bytes / 1024;      i++;  } while (bytes > 1024);  return Math.max(bytes, 0.1).toFixed(1) + ' ' + byteUnits[i];};var collectionNames = db.getCollectionNames(), stats = [];collectionNames.forEach(function (n) {                          stats.push(db[n].stats());                        });stats = stats.sort(function(a, b) {                     return b['size'] - a['size']; });for (var c in stats) {  print(stats[c]['ns'] + ': ' +        humanReadable(stats[c]['size']) + ' (' +        humanReadable(stats[c]['storageSize']) + ')'); }"z"db.stats()"zmongo-task_status)Zsuggest_filenamezmongo-reserved_resourceszpulp-running_taskszmongo-collection_sizeszmongo-db_statsZquczqpid-stat -z --ssl-certificate=z -b amqps://localhost:5671Z
qpid_stat_)Ztagszosudo -u pulp PULP_SETTINGS='/etc/pulp/settings.py' DJANGO_SETTINGS_MODULE='pulpcore.app.settings' dynaconf listZ
dynaconf_list)�dbhost�dbport�dbuser�
dbpasswordZmessaging_cert_file�open�read�
splitlinesr�split�
startswith�IOErrorZ
add_file_tagsZ
add_copy_specZ
get_option�build_mongo_cmdZadd_cmd_output)�selfZin_messaging_section�lineZuriZ	num_tasksZmtasksZmresZprunZcsizesZdbstats�opt�r!�/usr/lib/python3.6/pulp.py�setupsz










z
Pulp.setupcCs4d}d|j|j|j|jf}d}|t|||f�S)Nz
bash -c %sz--host %s --port %s %s %sz mongo pulp_database %s --eval %s)rrrrr)rZqueryZ_cmdZ_mondbZ_moncmdr!r!r"r�s

zPulp.build_mongo_cmdcCsTd}d}|jd||�d}d}|jd||�d}d}|jd||�|jd	||�dS)
Nz0(([a-z].*(passw|token|cred|secret).*)\:(\s))(.*)z\1 ********z/etc/pulp/(.*)\.conf$z7(\s*\".*(passw|cred|token|secret).*\"\s*:(\s))(.*)(\w+)z
\1********z/etc/pulp(.*)(.json$)z_((?:SECRET_KEY|AUTH_LDAP_BIND_PASSWORD)(?:\<.+\>)?(\s*=)?|(password|PASSWORD)(\"|'|:)+)\s*(\S*)z/etc/pulp/settings.pyz
dynaconf list)Zdo_path_regex_subZdo_cmd_output_sub)rZetcreg�replZjregZkey_pass_rer!r!r"�postproc�sz
Pulp.postprocN)rr	r
)r)�__name__�
__module__�__qualname__Z
short_descZplugin_nameZpackages�filesrZoption_listr#rr%r!r!r!r"rs
wrN)	Zsos.report.pluginsrrrZpipesr�rerrr!r!r!r"�<module>s