Search is not available for this dataset
text
stringlengths
75
104k
def __get_size(conn, vm_): ''' Need to override libcloud to find the machine type in the proper zone. ''' size = config.get_cloud_config_value( 'size', vm_, __opts__, default='n1-standard-1', search_global=False) return conn.ex_get_size(size, __get_location(conn, vm_))
def __get_tags(vm_): ''' Get configured tags. ''' t = config.get_cloud_config_value( 'tags', vm_, __opts__, default='[]', search_global=False) # Consider warning the user that the tags in the cloud profile # could not be interpreted, bad formatting? try: tags = litera...
def __get_metadata(vm_): ''' Get configured metadata and add 'salt-cloud-profile'. ''' md = config.get_cloud_config_value( 'metadata', vm_, __opts__, default='{}', search_global=False) # Consider warning the user that the metadata in the cloud profile # could not be interpreted, ...
def __get_host(node, vm_): ''' Return public IP, private IP, or hostname for the libcloud 'node' object ''' if __get_ssh_interface(vm_) == 'private_ips' or vm_['external_ip'] is None: ip_address = node.private_ips[0] log.info('Salt node data. Private_ip: %s', ip_address) else: ...
def __get_network(conn, vm_): ''' Return a GCE libcloud network object with matching name ''' network = config.get_cloud_config_value( 'network', vm_, __opts__, default='default', search_global=False) return conn.ex_get_network(network)
def __get_subnetwork(vm_): ''' Get configured subnetwork. ''' ex_subnetwork = config.get_cloud_config_value( 'subnetwork', vm_, __opts__, search_global=False) return ex_subnetwork
def __get_region(conn, vm_): ''' Return a GCE libcloud region object with matching name. ''' location = __get_location(conn, vm_) region = '-'.join(location.name.split('-')[:2]) return conn.ex_get_region(region)
def __create_orget_address(conn, name, region): ''' Reuse or create a static IP address. Returns a native GCEAddress construct to use with libcloud. ''' try: addy = conn.ex_get_address(name, region) except ResourceNotFoundError: # pylint: disable=W0703 addr_kwargs = { ...
def _parse_allow(allow): ''' Convert firewall rule allowed user-string to specified REST API format. ''' # input=> tcp:53,tcp:80,tcp:443,icmp,tcp:4201,udp:53 # output<= [ # {"IPProtocol": "tcp", "ports": ["53","80","443","4201"]}, # {"IPProtocol": "icmp"}, # {"IPProtocol": "u...
def __get_ssh_credentials(vm_): ''' Get configured SSH credentials. ''' ssh_user = config.get_cloud_config_value( 'ssh_username', vm_, __opts__, default=os.getenv('USER')) ssh_key = config.get_cloud_config_value( 'ssh_keyfile', vm_, __opts__, default=os.path.expanduser('~/.ss...
def create_network(kwargs=None, call=None): ''' ... versionchanged:: 2017.7.0 Create a GCE network. Must specify name and cidr. CLI Example: .. code-block:: bash salt-cloud -f create_network gce name=mynet cidr=10.10.10.0/24 mode=legacy description=optional salt-cloud -f create_ne...
def delete_network(kwargs=None, call=None): ''' Permanently delete a network. CLI Example: .. code-block:: bash salt-cloud -f delete_network gce name=mynet ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_network function must be called with -f or ...
def show_network(kwargs=None, call=None): ''' Show the details of an existing network. CLI Example: .. code-block:: bash salt-cloud -f show_network gce name=mynet ''' if call != 'function': raise SaltCloudSystemExit( 'The show_network function must be called with -...
def create_subnetwork(kwargs=None, call=None): ''' ... versionadded:: 2017.7.0 Create a GCE Subnetwork. Must specify name, cidr, network, and region. CLI Example: .. code-block:: bash salt-cloud -f create_subnetwork gce name=mysubnet network=mynet1 region=us-west1 cidr=10.0.0.0/24 descrip...
def delete_subnetwork(kwargs=None, call=None): ''' ... versionadded:: 2017.7.0 Delete a GCE Subnetwork. Must specify name and region. CLI Example: .. code-block:: bash salt-cloud -f delete_subnetwork gce name=mysubnet network=mynet1 region=us-west1 ''' if call != 'function': ...
def show_subnetwork(kwargs=None, call=None): ''' ... versionadded:: 2017.7.0 Show details of an existing GCE Subnetwork. Must specify name and region. CLI Example: .. code-block:: bash salt-cloud -f show_subnetwork gce name=mysubnet region=us-west1 ''' if call != 'function': ...
def create_fwrule(kwargs=None, call=None): ''' Create a GCE firewall rule. The 'default' network is used if not specified. CLI Example: .. code-block:: bash salt-cloud -f create_fwrule gce name=allow-http allow=tcp:80 ''' if call != 'function': raise SaltCloudSystemExit( ...
def delete_fwrule(kwargs=None, call=None): ''' Permanently delete a firewall rule. CLI Example: .. code-block:: bash salt-cloud -f delete_fwrule gce name=allow-http ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_fwrule function must be called wit...
def show_fwrule(kwargs=None, call=None): ''' Show the details of an existing firewall rule. CLI Example: .. code-block:: bash salt-cloud -f show_fwrule gce name=allow-http ''' if call != 'function': raise SaltCloudSystemExit( 'The show_fwrule function must be calle...
def create_hc(kwargs=None, call=None): ''' Create an HTTP health check configuration. CLI Example: .. code-block:: bash salt-cloud -f create_hc gce name=hc path=/healthy port=80 ''' if call != 'function': raise SaltCloudSystemExit( 'The create_hc function must be c...
def delete_hc(kwargs=None, call=None): ''' Permanently delete a health check. CLI Example: .. code-block:: bash salt-cloud -f delete_hc gce name=hc ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_hc function must be called with -f or --function.' ...
def show_hc(kwargs=None, call=None): ''' Show the details of an existing health check. CLI Example: .. code-block:: bash salt-cloud -f show_hc gce name=hc ''' if call != 'function': raise SaltCloudSystemExit( 'The show_hc function must be called with -f or --functi...
def create_address(kwargs=None, call=None): ''' Create a static address in a region. CLI Example: .. code-block:: bash salt-cloud -f create_address gce name=my-ip region=us-central1 address=IP ''' if call != 'function': raise SaltCloudSystemExit( 'The create_addres...
def delete_address(kwargs=None, call=None): ''' Permanently delete a static address. CLI Example: .. code-block:: bash salt-cloud -f delete_address gce name=my-ip ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_address function must be called with...
def show_address(kwargs=None, call=None): ''' Show the details of an existing static address. CLI Example: .. code-block:: bash salt-cloud -f show_address gce name=mysnapshot region=us-central1 ''' if call != 'function': raise SaltCloudSystemExit( 'The show_snapsho...
def create_lb(kwargs=None, call=None): ''' Create a load-balancer configuration. CLI Example: .. code-block:: bash salt-cloud -f create_lb gce name=lb region=us-central1 ports=80 ''' if call != 'function': raise SaltCloudSystemExit( 'The create_lb function must be ...
def delete_lb(kwargs=None, call=None): ''' Permanently delete a load-balancer. CLI Example: .. code-block:: bash salt-cloud -f delete_lb gce name=lb ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_hc function must be called with -f or --function.'...
def show_lb(kwargs=None, call=None): ''' Show the details of an existing load-balancer. CLI Example: .. code-block:: bash salt-cloud -f show_lb gce name=lb ''' if call != 'function': raise SaltCloudSystemExit( 'The show_lb function must be called with -f or --funct...
def attach_lb(kwargs=None, call=None): ''' Add an existing node/member to an existing load-balancer configuration. CLI Example: .. code-block:: bash salt-cloud -f attach_lb gce name=lb member=myinstance ''' if call != 'function': raise SaltCloudSystemExit( 'The att...
def detach_lb(kwargs=None, call=None): ''' Remove an existing node/member from an existing load-balancer configuration. CLI Example: .. code-block:: bash salt-cloud -f detach_lb gce name=lb member=myinstance ''' if call != 'function': raise SaltCloudSystemExit( 'Th...
def delete_snapshot(kwargs=None, call=None): ''' Permanently delete a disk snapshot. CLI Example: .. code-block:: bash salt-cloud -f delete_snapshot gce name=disk-snap-1 ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_snapshot function must be cal...
def delete_disk(kwargs=None, call=None): ''' Permanently delete a persistent disk. CLI Example: .. code-block:: bash salt-cloud -f delete_disk gce disk_name=pd ''' if call != 'function': raise SaltCloudSystemExit( 'The delete_disk function must be called with -f or...
def create_disk(kwargs=None, call=None): ''' Create a new persistent disk. Must specify `disk_name` and `location`, and optionally can specify 'disk_type' as pd-standard or pd-ssd, which defaults to pd-standard. Can also specify an `image` or `snapshot` but if neither of those are specified, a `siz...
def create_snapshot(kwargs=None, call=None): ''' Create a new disk snapshot. Must specify `name` and `disk_name`. CLI Example: .. code-block:: bash salt-cloud -f create_snapshot gce name=snap1 disk_name=pd ''' if call != 'function': raise SaltCloudSystemExit( 'The...
def show_disk(name=None, kwargs=None, call=None): # pylint: disable=W0613 ''' Show the details of an existing disk. CLI Example: .. code-block:: bash salt-cloud -a show_disk myinstance disk_name=mydisk salt-cloud -f show_disk gce disk_name=mydisk ''' if not kwargs or 'disk_na...
def show_snapshot(kwargs=None, call=None): ''' Show the details of an existing snapshot. CLI Example: .. code-block:: bash salt-cloud -f show_snapshot gce name=mysnapshot ''' if call != 'function': raise SaltCloudSystemExit( 'The show_snapshot function must be call...
def detach_disk(name=None, kwargs=None, call=None): ''' Detach a disk from an instance. CLI Example: .. code-block:: bash salt-cloud -a detach_disk myinstance disk_name=mydisk ''' if call != 'action': raise SaltCloudSystemExit( 'The detach_Disk action must be calle...
def attach_disk(name=None, kwargs=None, call=None): ''' Attach an existing disk to an existing instance. CLI Example: .. code-block:: bash salt-cloud -a attach_disk myinstance disk_name=mydisk mode=READ_WRITE ''' if call != 'action': raise SaltCloudSystemExit( 'The...
def reboot(vm_name, call=None): ''' Call GCE 'reset' on the instance. CLI Example: .. code-block:: bash salt-cloud -a reboot myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The reboot action must be called with -a or --action.' ) conn =...
def start(vm_name, call=None): ''' Call GCE 'start on the instance. .. versionadded:: 2017.7.0 CLI Example: .. code-block:: bash salt-cloud -a start myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The start action must be called with -a or --ac...
def stop(vm_name, call=None): ''' Call GCE 'stop' on the instance. .. versionadded:: 2017.7.0 CLI Example: .. code-block:: bash salt-cloud -a stop myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or --actio...
def destroy(vm_name, call=None): ''' Call 'destroy' on the instance. Can be called with "-a destroy" or -d CLI Example: .. code-block:: bash salt-cloud -a destroy myinstance1 myinstance2 ... salt-cloud -d myinstance1 myinstance2 ... ''' if call and call != 'action': r...
def create_attach_volumes(name, kwargs, call=None): ''' .. versionadded:: 2017.7.0 Create and attach multiple volumes to a node. The 'volumes' and 'node' arguments are required, where 'node' is a libcloud node, and 'volumes' is a list of maps, where each map contains: size The size of ...
def request_instance(vm_): ''' Request a single GCE instance from a data dict. .. versionchanged: 2017.7.0 ''' if not GCE_VM_NAME_REGEX.match(vm_['name']): raise SaltCloudSystemExit( 'VM names must start with a letter, only contain letters, numbers, or dashes ' 'and ...
def create(vm_=None, call=None): ''' Create a single GCE instance from a data dict. ''' if call: raise SaltCloudSystemExit( 'You cannot create an instance with -a or -f.' ) node_info = request_instance(vm_) if isinstance(node_info, bool): raise SaltCloudSyste...
def update_pricing(kwargs=None, call=None): ''' Download most recent pricing information from GCE and save locally CLI Examples: .. code-block:: bash salt-cloud -f update_pricing my-gce-config .. versionadded:: 2015.8.0 ''' url = 'https://cloudpricingcalculator.appspot.com/static...
def show_pricing(kwargs=None, call=None): ''' Show pricing for a particular profile. This is only an estimate, based on unofficial pricing sources. .. versionadded:: 2015.8.0 CLI Examples: .. code-block:: bash salt-cloud -f show_pricing my-gce-config profile=my-profile ''' pr...
def _logstash(url, data): ''' Issues HTTP queries to the logstash server. ''' result = salt.utils.http.query( url, 'POST', header_dict=_HEADERS, data=salt.utils.json.dumps(data), decode=True, status=True, opts=__opts__ ) return result
def start(url, funs=None, tags=None): ''' Listen to salt events and forward them to logstash. url The Logstash endpoint. funs: ``None`` A list of functions to be compared against, looking into the ``fun`` field from the event data. This option helps to select the events ...
def present(name, grant=None, database=None, user=None, host='localhost', grant_option=False, escape=True, revoke_first=False, ssl_option=False, **connection_args): ''' Ensure that the grant is present wi...
def absent(name, grant=None, database=None, user=None, host='localhost', grant_option=False, escape=True, **connection_args): ''' Ensure that the grant is absent name The name (key) of the grant to add grant T...
def _nodetool(cmd): ''' Internal cassandra nodetool wrapper. Some functions are not available via pycassa so we must rely on nodetool. ''' nodetool = __salt__['config.option']('cassandra.nodetool') host = __salt__['config.option']('cassandra.host') return __salt__['cmd.run_stdout']('{0} -h {...
def _sys_mgr(): ''' Return a pycassa system manager connection object ''' thrift_port = six.text_type(__salt__['config.option']('cassandra.THRIFT_PORT')) host = __salt__['config.option']('cassandra.host') return SystemManager('{0}:{1}'.format(host, thrift_port))
def column_families(keyspace=None): ''' Return existing column families for all keyspaces or just the provided one. CLI Example: .. code-block:: bash salt '*' cassandra.column_families salt '*' cassandra.column_families <keyspace> ''' sys = _sys_mgr() ksps = sys.list_k...
def column_family_definition(keyspace, column_family): ''' Return a dictionary of column family definitions for the given keyspace/column_family CLI Example: .. code-block:: bash salt '*' cassandra.column_family_definition <keyspace> <column_family> ''' sys = _sys_mgr() try:...
def update_quota(self, tenant_id, subnet=None, router=None, network=None, floatingip=None, port=None, sec_grp=None, sec_grp_rule=None): ''' Update a tenant's quota ''' body = {} if subnet: body['subnet'] = subnet if ro...
def delete_quota(self, tenant_id): ''' Delete the specified tenant's quota value ''' ret = self.network_conn.delete_quota(tenant_id=tenant_id) return ret if ret else True
def create_port(self, name, network, device_id=None, admin_state_up=True): ''' Creates a new port ''' net_id = self._find_network_id(network) body = {'admin_state_up': admin_state_up, 'name': name, 'network_id': net_id} if device_id: ...
def update_port(self, port, name, admin_state_up=True): ''' Updates a port ''' port_id = self._find_port_id(port) body = {'name': name, 'admin_state_up': admin_state_up} return self.network_conn.update_port(port=port_id, ...
def delete_port(self, port): ''' Deletes the specified port ''' port_id = self._find_port_id(port) ret = self.network_conn.delete_port(port=port_id) return ret if ret else True
def create_network(self, name, admin_state_up=True, router_ext=None, network_type=None, physical_network=None, segmentation_id=None, shared=None, vlan_transparent=None): ''' Creates a new network ''' body = {'name': name, 'admin_state_up': admin_state_up} if route...
def update_network(self, network, name): ''' Updates a network ''' net_id = self._find_network_id(network) return self.network_conn.update_network( network=net_id, body={'network': {'name': name}})
def delete_network(self, network): ''' Deletes the specified network ''' net_id = self._find_network_id(network) ret = self.network_conn.delete_network(network=net_id) return ret if ret else True
def create_subnet(self, network, cidr, name=None, ip_version=4): ''' Creates a new subnet ''' net_id = self._find_network_id(network) body = {'cidr': cidr, 'ip_version': ip_version, 'network_id': net_id, 'name': name} return...
def update_subnet(self, subnet, name=None): ''' Updates a subnet ''' subnet_id = self._find_subnet_id(subnet) return self.network_conn.update_subnet( subnet=subnet_id, body={'subnet': {'name': name}})
def delete_subnet(self, subnet): ''' Deletes the specified subnet ''' subnet_id = self._find_subnet_id(subnet) ret = self.network_conn.delete_subnet(subnet=subnet_id) return ret if ret else True
def create_router(self, name, ext_network=None, admin_state_up=True): ''' Creates a new router ''' body = {'name': name, 'admin_state_up': admin_state_up} if ext_network: net_id = self._find_network_id(ext_network) body['external_gateway_in...
def update_router(self, router, name=None, admin_state_up=None, **kwargs): ''' Updates a router ''' router_id = self._find_router_id(router) body = {} if 'ext_network' in kwargs: if kwargs.get('ext_network') is None: body['external_gateway_inf...
def delete_router(self, router): ''' Delete the specified router ''' router_id = self._find_router_id(router) ret = self.network_conn.delete_router(router=router_id) return ret if ret else True
def add_interface_router(self, router, subnet): ''' Adds an internal network interface to the specified router ''' router_id = self._find_router_id(router) subnet_id = self._find_subnet_id(subnet) return self.network_conn.add_interface_router( router=router_id...
def add_gateway_router(self, router, network): ''' Adds an external network gateway to the specified router ''' router_id = self._find_router_id(router) net_id = self._find_network_id(network) return self.network_conn.add_gateway_router( router=router_id, body...
def remove_gateway_router(self, router): ''' Removes an external network gateway from the specified router ''' router_id = self._find_router_id(router) return self.network_conn.remove_gateway_router(router=router_id)
def create_floatingip(self, floating_network, port=None): ''' Creates a new floatingip ''' net_id = self._find_network_id(floating_network) body = {'floating_network_id': net_id} if port: port_id = self._find_port_id(port) body['port_id'] = port_id...
def update_floatingip(self, floatingip_id, port=None): ''' Updates a floatingip, disassociates the floating ip if port is set to `None` ''' if port is None: body = {'floatingip': {}} else: port_id = self._find_port_id(port) body = {'flo...
def delete_floatingip(self, floatingip_id): ''' Deletes the specified floatingip ''' ret = self.network_conn.delete_floatingip(floatingip_id) return ret if ret else True
def create_security_group(self, name, desc=None): ''' Creates a new security group ''' body = {'security_group': {'name': name, 'description': desc}} return self.network_conn.create_security_group(body=body)
def update_security_group(self, sec_grp, name=None, desc=None): ''' Updates a security group ''' sec_grp_id = self._find_security_group_id(sec_grp) body = {'security_group': {}} if name: body['security_group']['name'] = name if desc: body['...
def delete_security_group(self, sec_grp): ''' Deletes the specified security group ''' sec_grp_id = self._find_security_group_id(sec_grp) ret = self.network_conn.delete_security_group(sec_grp_id) return ret if ret else True
def create_security_group_rule( self, sec_grp, remote_grp_id=None, direction='ingress', protocol=None, port_range_min=None, port_range_max=None, ether=None): ''' Creates a new security group rule ''' sec_grp_id = self._find_security_group_id(sec_grp) ...
def delete_security_group_rule(self, sec_grp_rule_id): ''' Deletes the specified security group rule ''' ret = self.network_conn.delete_security_group_rule( security_group_rule=sec_grp_rule_id) return ret if ret else True
def list_vpnservices(self, retrieve_all=True, **kwargs): ''' Fetches a list of all configured VPN services for a tenant ''' return self.network_conn.list_vpnservices(retrieve_all, **kwargs)
def show_vpnservice(self, vpnservice, **kwargs): ''' Fetches information of a specific VPN service ''' vpnservice_id = self._find_vpnservice_id(vpnservice) return self.network_conn.show_vpnservice(vpnservice_id, **kwargs)
def create_vpnservice(self, subnet, router, name, admin_state_up=True): ''' Creates a new VPN service ''' subnet_id = self._find_subnet_id(subnet) router_id = self._find_router_id(router) body = {'subnet_id': subnet_id, 'router_id': router_id, ...
def update_vpnservice(self, vpnservice, desc): ''' Updates a VPN service ''' vpnservice_id = self._find_vpnservice_id(vpnservice) body = {'description': desc} return self.network_conn.update_vpnservice(vpnservice_id, body...
def delete_vpnservice(self, vpnservice): ''' Deletes the specified VPN service ''' vpnservice_id = self._find_vpnservice_id(vpnservice) ret = self.network_conn.delete_vpnservice(vpnservice_id) return ret if ret else True
def create_ipsec_site_connection(self, name, ipsecpolicy, ikepolicy, vpnservice, peer_cidrs, peer_address, peer_id, ...
def delete_ipsec_site_connection(self, ipsec_site_connection): ''' Deletes the specified IPsecSiteConnection ''' ipsec_site_connection_id = self._find_ipsec_site_connection_id( ipsec_site_connection) ret = self.network_conn.delete_ipsec_site_connection( ip...
def create_ikepolicy(self, name, **kwargs): ''' Creates a new IKEPolicy ''' body = {'name': name} if 'phase1_negotiation_mode' in kwargs: body['phase1_negotiation_mode'] = kwargs['phase1_negotiation_mode'] if 'auth_algorithm' in kwargs: body['auth_...
def delete_ikepolicy(self, ikepolicy): ''' Deletes the specified IKEPolicy ''' ikepolicy_id = self._find_ikepolicy_id(ikepolicy) ret = self.network_conn.delete_ikepolicy(ikepolicy_id) return ret if ret else True
def create_ipsecpolicy(self, name, **kwargs): ''' Creates a new IPsecPolicy ''' body = {'name': name} if 'transform_protocol' in kwargs: body['transform_protocol'] = kwargs['transform_protocol'] if 'auth_algorithm' in kwargs: body['auth_algorithm']...
def delete_ipsecpolicy(self, ipseecpolicy): ''' Deletes the specified IPsecPolicy ''' ipseecpolicy_id = self._find_ipsecpolicy_id(ipseecpolicy) ret = self.network_conn.delete_ipsecpolicy(ipseecpolicy_id) return ret if ret else True
def create_firewall_rule(self, protocol, action, **kwargs): ''' Create a new firlwall rule ''' body = {'protocol': protocol, 'action': action} if 'tenant_id' in kwargs: body['tenant_id'] = kwargs['tenant_id'] if 'name' in kwargs: body['name'] = kwa...
def delete_firewall_rule(self, firewall_rule): ''' Deletes the specified firewall rule ''' firewall_rule_id = self._find_firewall_rule_id(firewall_rule) ret = self.network_conn.delete_firewall_rule(firewall_rule_id) return ret if ret else True
def update_firewall_rule(self, firewall_rule, protocol=None, action=None, name=None, description=None, ip_version=None, source_ip_address=None, destination_ip_address=None, source_port=None, destination_port=None, shared=None, enable...
def exist(name): ''' Return True if the chroot environment is present. ''' dev = os.path.join(name, 'dev') proc = os.path.join(name, 'proc') return all(os.path.isdir(i) for i in (name, dev, proc))
def create(name): ''' Create a basic chroot environment. Note that this environment is not functional. The caller needs to install the minimal required binaries, including Python if chroot.call is called. name Path to the chroot environment CLI Example: .. code-block:: bash ...
def call(name, function, *args, **kwargs): ''' Executes a Salt function inside a chroot environment. The chroot does not need to have Salt installed, but Python is required. name Path to the chroot environment function Salt execution module function CLI Example: .. c...
def save(name, filter=False): ''' Save the register to <salt cachedir>/thorium/saves/<name>, or to an absolute path. If an absolute path is specified, then the directory will be created non-recursively if it doesn't exist. USAGE: .. code-block:: yaml foo: file.save ...
def find_file(path, saltenv='base', **kwargs): ''' Search the environment for the relative path. ''' if 'env' in kwargs: # "env" is not supported; Use "saltenv". kwargs.pop('env') path = os.path.normpath(path) fnd = {'path': '', 'rel': ''} if os.path.isabs(path): ...
def serve_file(load, fnd): ''' Return a chunk from a file based on the data received ''' if 'env' in load: # "env" is not supported; Use "saltenv". load.pop('env') ret = {'data': '', 'dest': ''} if 'path' not in load or 'loc' not in load or 'saltenv' not in load: ...