HEX
Server: LiteSpeed
System: Linux kapuas.iixcp.rumahweb.net 5.14.0-427.42.1.el9_4.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Nov 1 14:58:02 EDT 2024 x86_64
User: mirz4654 (1666)
PHP: 8.1.33
Disabled: system,exec,escapeshellarg,escapeshellcmd,passthru,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,shell_exec,popen,pclose,dl,pfsockopen,leak,apache_child_terminate,posix_kill,posix_mkfifo,posix_setsid,posix_setuid,posix_setpgid,ini_alter,show_source,define_syslog_variables,symlink,syslog,openlog,openlog,closelog,ocinumcols,listen,chgrp,apache_note,apache_setenv,debugger_on,debugger_off,ftp_exec,dll,ftp,myshellexec,socket_bind,mail,posix_getwpuid
Upload Files
File: //lib/python3.9/site-packages/ansible/plugins/lookup/__pycache__/unvault.cpython-39.pyc
a

�)g��@snddlmZmZmZeZdZdZdZddl	m
Z
ddlmZddl
mZddlmZe�ZGd	d
�d
e�ZdS)�)�absolute_import�division�print_functiona�
    name: unvault
    author: Ansible Core Team
    version_added: "2.10"
    short_description: read vaulted file(s) contents
    description:
        - This lookup returns the contents from vaulted (or not) file(s) on the Ansible controller's file system.
    options:
      _terms:
        description: path(s) of files to read
        required: True
    notes:
      - This lookup does not understand 'globbing' nor shell environment variables.
z�
- ansible.builtin.debug: msg="the value of foo.txt is {{ lookup('ansible.builtin.unvault', '/etc/foo.txt') | string | trim }}"
z_
  _raw:
    description:
      - content of file(s) as bytes
    type: list
    elements: raw
)�AnsibleParserError)�
LookupBase)�to_text)�Displayc@seZdZddd�ZdS)�LookupModuleNc
	Ks�g}|j||d�|D]�}t�d|�|�|d|�}t�d|�|r�|jj|dd�}t|d��}|��}	Wd�n1s�0Y|�	t
|	��qtd|��q|S)	N)Zvar_optionsZdirectzUnvault lookup term: %s�fileszUnvault lookup found %sT)Zdecrypt�rbz"Unable to find file matching "%s" )Zset_options�display�debugZfind_file_in_search_pathZvvvvZ_loaderZ
get_real_file�open�read�appendrr)
�selfZtermsZ	variables�kwargs�retZtermZ
lookupfileZactual_file�fZ
b_contents�r�B/usr/lib/python3.9/site-packages/ansible/plugins/lookup/unvault.py�run+s&zLookupModule.run)N)�__name__�
__module__�__qualname__rrrrrr	)sr	N)Z
__future__rrr�typeZ
__metaclass__Z
DOCUMENTATIONZEXAMPLESZRETURNZansible.errorsrZansible.plugins.lookuprZansible.module_utils._textrZansible.utils.displayrrr	rrrr�<module>s