Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /lib/python3.11/site-packages/ansible/modules/__pycache__/ |
Upload File : |
� ���ch � �\ � d dl mZmZmZ eZdZdZd dlm Z d� Z edk r e � � dS dS )� )�absolute_import�division�print_functiona� --- module: dpkg_selections short_description: Dpkg package selection selections description: - Change dpkg package selection state via --get-selections and --set-selections. version_added: "2.0" author: - Brian Brazil (@brian-brazil) <brian.brazil@boxever.com> options: name: description: - Name of the package. required: true type: str selection: description: - The selection state to set the package to. choices: [ 'install', 'hold', 'deinstall', 'purge' ] required: true type: str extends_documentation_fragment: - action_common_attributes attributes: check_mode: support: full diff_mode: support: full platform: support: full platforms: debian notes: - This module won't cause any packages to be installed/removed/purged, use the C(apt) module for that. z� - name: Prevent python from being upgraded ansible.builtin.dpkg_selections: name: python selection: hold - name: Allow python to be upgraded ansible.builtin.dpkg_selections: name: python selection: install )� AnsibleModulec � � t t t d�� � t g d�d�� � �� � d�� � } | � dd� � }| j d }| j d }| � |d |gd�� � \ }}}|sd}n|� � � d }||k }| j s|s| � |||�� � | � |dg|�d|��d�� � | � |||�� � d S )NT)�required)�install�hold� deinstall�purge)�choicesr )�name� selection)� argument_spec�supports_check_mode�dpkgr r z--get-selections)�check_rcznot present� )�changed�before�afterz--set-selections� )�datar )r �dict�get_bin_path�params�run_command�split� check_mode� exit_json) �moduler r r �rc�out�err�currentr s �D/usr/lib/python3.11/site-packages/ansible/modules/dpkg_selections.py�mainr'