File manager - Edit - /opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/__pycache__/azurearm_resource.cpython-310.pyc
Back
o ;jF� � @ s� d Z ddlZddlmZ ddlZddlZdZzddlZ ddl mZ ddlm Z dZW n ey3 Y nw dZe�e�Zd d � Zdd� Zed d� �Zedd� �Zedd� �Zedd� �Zedd� �Zedd� �ZedHdd��Zedd� �Zedd� �Ze ! dId"d#��Zed$d%� �Zed&d'� �Z e dJd(d)��Z!ed*d+� �Z"ed,d-� �Z#edKd.d/��Z$edKd0d1��Z%ed2d3� �Z&ed4d5� �Z'ed6d7� �Z(ed8d9� �Z)ed:d;� �Z*ed<d=� �Z+ed>d?� �Z,ed@dA� �Z-edBdC� �Z.edDdE� �Z/edLdFdG��Z0dS )Ma1 Azure (ARM) Resource Execution Module .. versionadded:: 2019.2.0 .. warning:: This cloud provider will be removed from Salt in version 3007 in favor of the `saltext.azurerm Salt Extension <https://github.com/salt-extensions/saltext-azurerm>`_ :maintainer: <devops@eitr.tech> :maturity: new :depends: * `azure <https://pypi.python.org/pypi/azure>`_ >= 2.0.0 * `azure-common <https://pypi.python.org/pypi/azure-common>`_ >= 1.1.8 * `azure-mgmt <https://pypi.python.org/pypi/azure-mgmt>`_ >= 1.0.0 * `azure-mgmt-compute <https://pypi.python.org/pypi/azure-mgmt-compute>`_ >= 1.0.0 * `azure-mgmt-network <https://pypi.python.org/pypi/azure-mgmt-network>`_ >= 1.7.1 * `azure-mgmt-resource <https://pypi.python.org/pypi/azure-mgmt-resource>`_ >= 1.1.0 * `azure-mgmt-storage <https://pypi.python.org/pypi/azure-mgmt-storage>`_ >= 1.0.0 * `azure-mgmt-web <https://pypi.python.org/pypi/azure-mgmt-web>`_ >= 0.32.0 * `azure-storage <https://pypi.python.org/pypi/azure-storage>`_ >= 0.34.3 * `msrestazure <https://pypi.python.org/pypi/msrestazure>`_ >= 0.4.21 :platform: linux :configuration: This module requires Azure Resource Manager credentials to be passed as keyword arguments to every function in order to work properly. Required provider parameters: if using username and password: * ``subscription_id`` * ``username`` * ``password`` if using a service principal: * ``subscription_id`` * ``tenant`` * ``client_id`` * ``secret`` Optional provider parameters: **cloud_environment**: Used to point the cloud driver to different API endpoints, such as Azure GovCloud. Possible values: * ``AZURE_PUBLIC_CLOUD`` (default) * ``AZURE_CHINA_CLOUD`` * ``AZURE_US_GOV_CLOUD`` * ``AZURE_GERMAN_CLOUD`` � N��wrapsF)�SerializationError)� CloudErrorTZazurearm_resourcec C s t sdS tS )N)Fz�The following dependencies are required to use the AzureARM modules: Microsoft Azure SDK for Python >= 2.0rc6, MS REST Azure (msrestazure) >= 0.4)�HAS_LIBS�__virtualname__� r r �R/opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/azurearm_resource.py�__virtual__O s r c s t � �� fdd��}|S )z> Decorator wrapper to warn about azurearm deprecation c s6 t jjjddtd� � | i t jjjdi |����}|S )NZChlorinez�The 'azurearm' functionality in Salt has been deprecated and its functionality will be removed in version 3007 in favor of the saltext.azurerm Salt Extension. (https://github.com/salt-extensions/saltext-azurerm))�categoryr )�salt�utilsZversionsZ warn_until� FutureWarning�argsZclean_kwargs)r �kwargs�ret��functionr r �wrapped` s �z%_deprecation_message.<locals>.wrappedr )r r r r r �_deprecation_message[ s r c K s� i }t d di | ��}zt d |j�� �}|D ]}|||d <