repo
stringlengths
7
54
path
stringlengths
4
223
func_name
stringlengths
1
134
original_string
stringlengths
75
104k
language
stringclasses
1 value
code
stringlengths
75
104k
code_tokens
listlengths
20
28.4k
docstring
stringlengths
1
46.3k
docstring_tokens
listlengths
1
1.66k
sha
stringlengths
40
40
url
stringlengths
87
315
partition
stringclasses
1 value
summary
stringlengths
4
350
obf_code
stringlengths
7.85k
764k
saltstack/salt
salt/modules/win_powercfg.py
set_hibernate_timeout
def set_hibernate_timeout(timeout, power='ac', scheme=None): ''' Set the hibernate timeout in minutes for the given power scheme Args: timeout (int): The amount of time in minutes before the computer hibernates power (str): Set the value for AC or DC power. Default ...
python
def set_hibernate_timeout(timeout, power='ac', scheme=None): ''' Set the hibernate timeout in minutes for the given power scheme Args: timeout (int): The amount of time in minutes before the computer hibernates power (str): Set the value for AC or DC power. Default ...
[ "def", "set_hibernate_timeout", "(", "timeout", ",", "power", "=", "'ac'", ",", "scheme", "=", "None", ")", ":", "return", "_set_powercfg_value", "(", "scheme", "=", "scheme", ",", "sub_group", "=", "'SUB_SLEEP'", ",", "setting_guid", "=", "'HIBERNATEIDLE'", "...
Set the hibernate timeout in minutes for the given power scheme Args: timeout (int): The amount of time in minutes before the computer hibernates power (str): Set the value for AC or DC power. Default is ``ac``. Valid options are: - ``ac`` (AC P...
[ "Set", "the", "hibernate", "timeout", "in", "minutes", "for", "the", "given", "power", "scheme" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/win_powercfg.py#L299-L338
train
Sets the hibernate timeout in minutes for the given power scheme and returns a boolean value.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/pagerduty_schedule.py
present
def present(profile='pagerduty', subdomain=None, api_key=None, **kwargs): ''' Ensure that a pagerduty schedule exists. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/schedules/create. This means that most arguments are in a dict called "schedule....
python
def present(profile='pagerduty', subdomain=None, api_key=None, **kwargs): ''' Ensure that a pagerduty schedule exists. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/schedules/create. This means that most arguments are in a dict called "schedule....
[ "def", "present", "(", "profile", "=", "'pagerduty'", ",", "subdomain", "=", "None", ",", "api_key", "=", "None", ",", "*", "*", "kwargs", ")", ":", "# for convenience, we accept id, name, or email as the user id.", "kwargs", "[", "'schedule'", "]", "[", "'name'",...
Ensure that a pagerduty schedule exists. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/schedules/create. This means that most arguments are in a dict called "schedule." User id's can be pagerduty id, or name, or email address.
[ "Ensure", "that", "a", "pagerduty", "schedule", "exists", ".", "This", "method", "accepts", "as", "args", "everything", "defined", "in", "https", ":", "//", "developer", ".", "pagerduty", ".", "com", "/", "documentation", "/", "rest", "/", "schedules", "/", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/pagerduty_schedule.py#L48-L77
train
Ensure that a pagerduty schedule exists.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/pagerduty_schedule.py
_diff
def _diff(state_data, resource_object): '''helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update. ''' state_data['id'] = resource_object['schedule'...
python
def _diff(state_data, resource_object): '''helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update. ''' state_data['id'] = resource_object['schedule'...
[ "def", "_diff", "(", "state_data", ",", "resource_object", ")", ":", "state_data", "[", "'id'", "]", "=", "resource_object", "[", "'schedule'", "]", "[", "'id'", "]", "objects_differ", "=", "None", "# first check all the easy top-level properties: everything except the ...
helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update.
[ "helper", "method", "to", "compare", "salt", "state", "info", "with", "the", "PagerDuty", "API", "json", "structure", "and", "determine", "if", "we", "need", "to", "update", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/pagerduty_schedule.py#L94-L163
train
helper method to compare salt state info with PagerDuty API json structure and resource object and return the dict to pass to the PagerDuty API to perform the update.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_cron_id
def _cron_id(cron): '''SAFETYBELT, Only set if we really have an identifier''' cid = None if cron['identifier']: cid = cron['identifier'] else: cid = SALT_CRON_NO_IDENTIFIER if cid: return _ensure_string(cid)
python
def _cron_id(cron): '''SAFETYBELT, Only set if we really have an identifier''' cid = None if cron['identifier']: cid = cron['identifier'] else: cid = SALT_CRON_NO_IDENTIFIER if cid: return _ensure_string(cid)
[ "def", "_cron_id", "(", "cron", ")", ":", "cid", "=", "None", "if", "cron", "[", "'identifier'", "]", ":", "cid", "=", "cron", "[", "'identifier'", "]", "else", ":", "cid", "=", "SALT_CRON_NO_IDENTIFIER", "if", "cid", ":", "return", "_ensure_string", "("...
SAFETYBELT, Only set if we really have an identifier
[ "SAFETYBELT", "Only", "set", "if", "we", "really", "have", "an", "identifier" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L52-L60
train
Return the identifier of the current object.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_cron_matched
def _cron_matched(cron, cmd, identifier=None): '''Check if: - we find a cron with same cmd, old state behavior - but also be smart enough to remove states changed crons where we do not removed priorly by a cron.absent by matching on the provided identifier. We assure retrocompati...
python
def _cron_matched(cron, cmd, identifier=None): '''Check if: - we find a cron with same cmd, old state behavior - but also be smart enough to remove states changed crons where we do not removed priorly by a cron.absent by matching on the provided identifier. We assure retrocompati...
[ "def", "_cron_matched", "(", "cron", ",", "cmd", ",", "identifier", "=", "None", ")", ":", "ret", ",", "id_matched", "=", "False", ",", "None", "cid", "=", "_cron_id", "(", "cron", ")", "if", "cid", ":", "if", "not", "identifier", ":", "identifier", ...
Check if: - we find a cron with same cmd, old state behavior - but also be smart enough to remove states changed crons where we do not removed priorly by a cron.absent by matching on the provided identifier. We assure retrocompatibility by only checking on identifier if and o...
[ "Check", "if", ":", "-", "we", "find", "a", "cron", "with", "same", "cmd", "old", "state", "behavior", "-", "but", "also", "be", "smart", "enough", "to", "remove", "states", "changed", "crons", "where", "we", "do", "not", "removed", "priorly", "by", "a...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L63-L105
train
Check if a cron entry is matched by matching on the provided command and identifier.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_render_tab
def _render_tab(lst): ''' Takes a tab list structure and renders it to a list for applying it to a file ''' ret = [] for pre in lst['pre']: ret.append('{0}\n'.format(pre)) if ret: if ret[-1] != TAG: ret.append(TAG) else: ret.append(TAG) for env in ...
python
def _render_tab(lst): ''' Takes a tab list structure and renders it to a list for applying it to a file ''' ret = [] for pre in lst['pre']: ret.append('{0}\n'.format(pre)) if ret: if ret[-1] != TAG: ret.append(TAG) else: ret.append(TAG) for env in ...
[ "def", "_render_tab", "(", "lst", ")", ":", "ret", "=", "[", "]", "for", "pre", "in", "lst", "[", "'pre'", "]", ":", "ret", ".", "append", "(", "'{0}\\n'", ".", "format", "(", "pre", ")", ")", "if", "ret", ":", "if", "ret", "[", "-", "1", "]"...
Takes a tab list structure and renders it to a list for applying it to a file
[ "Takes", "a", "tab", "list", "structure", "and", "renders", "it", "to", "a", "list", "for", "applying", "it", "to", "a", "file" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L119-L177
train
Takes a tab list structure and renders it to a list for applying it to a file
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_get_cron_cmdstr
def _get_cron_cmdstr(path, user=None): ''' Returns a format string, to be used to build a crontab command. ''' if user: cmd = 'crontab -u {0}'.format(user) else: cmd = 'crontab' return '{0} {1}'.format(cmd, path)
python
def _get_cron_cmdstr(path, user=None): ''' Returns a format string, to be used to build a crontab command. ''' if user: cmd = 'crontab -u {0}'.format(user) else: cmd = 'crontab' return '{0} {1}'.format(cmd, path)
[ "def", "_get_cron_cmdstr", "(", "path", ",", "user", "=", "None", ")", ":", "if", "user", ":", "cmd", "=", "'crontab -u {0}'", ".", "format", "(", "user", ")", "else", ":", "cmd", "=", "'crontab'", "return", "'{0} {1}'", ".", "format", "(", "cmd", ",",...
Returns a format string, to be used to build a crontab command.
[ "Returns", "a", "format", "string", "to", "be", "used", "to", "build", "a", "crontab", "command", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L180-L188
train
Returns a format string to be used to build a crontab command.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
write_cron_file
def write_cron_file(user, path): ''' Writes the contents of a file to a user's crontab CLI Example: .. code-block:: bash salt '*' cron.write_cron_file root /tmp/new_cron .. versionchanged:: 2015.8.9 .. note:: Some OS' do not support specifying user via the `crontab` command...
python
def write_cron_file(user, path): ''' Writes the contents of a file to a user's crontab CLI Example: .. code-block:: bash salt '*' cron.write_cron_file root /tmp/new_cron .. versionchanged:: 2015.8.9 .. note:: Some OS' do not support specifying user via the `crontab` command...
[ "def", "write_cron_file", "(", "user", ",", "path", ")", ":", "if", "_check_instance_uid_match", "(", "user", ")", "or", "__grains__", ".", "get", "(", "'os_family'", ")", "in", "(", "'Solaris'", ",", "'AIX'", ")", ":", "return", "__salt__", "[", "'cmd.ret...
Writes the contents of a file to a user's crontab CLI Example: .. code-block:: bash salt '*' cron.write_cron_file root /tmp/new_cron .. versionchanged:: 2015.8.9 .. note:: Some OS' do not support specifying user via the `crontab` command i.e. (Solaris, AIX)
[ "Writes", "the", "contents", "of", "a", "file", "to", "a", "user", "s", "crontab" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L198-L220
train
Writes the contents of a file to a user s crontab CLI Example
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_write_cron_lines
def _write_cron_lines(user, lines): ''' Takes a list of lines to be committed to a user's crontab and writes it ''' lines = [salt.utils.stringutils.to_str(_l) for _l in lines] path = salt.utils.files.mkstemp() if _check_instance_uid_match(user) or __grains__.get('os_family') in ('Solaris', 'AIX'...
python
def _write_cron_lines(user, lines): ''' Takes a list of lines to be committed to a user's crontab and writes it ''' lines = [salt.utils.stringutils.to_str(_l) for _l in lines] path = salt.utils.files.mkstemp() if _check_instance_uid_match(user) or __grains__.get('os_family') in ('Solaris', 'AIX'...
[ "def", "_write_cron_lines", "(", "user", ",", "lines", ")", ":", "lines", "=", "[", "salt", ".", "utils", ".", "stringutils", ".", "to_str", "(", "_l", ")", "for", "_l", "in", "lines", "]", "path", "=", "salt", ".", "utils", ".", "files", ".", "mks...
Takes a list of lines to be committed to a user's crontab and writes it
[ "Takes", "a", "list", "of", "lines", "to", "be", "committed", "to", "a", "user", "s", "crontab", "and", "writes", "it" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L248-L267
train
Writes a list of lines to a user s crontab and returns the path to the new crontab file
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_date_time_match
def _date_time_match(cron, **kwargs): ''' Returns true if the minute, hour, etc. params match their counterparts from the dict returned from list_tab(). ''' return all([kwargs.get(x) is None or cron[x] == six.text_type(kwargs[x]) or (six.text_type(kwargs[x]).lower() == 'random' and c...
python
def _date_time_match(cron, **kwargs): ''' Returns true if the minute, hour, etc. params match their counterparts from the dict returned from list_tab(). ''' return all([kwargs.get(x) is None or cron[x] == six.text_type(kwargs[x]) or (six.text_type(kwargs[x]).lower() == 'random' and c...
[ "def", "_date_time_match", "(", "cron", ",", "*", "*", "kwargs", ")", ":", "return", "all", "(", "[", "kwargs", ".", "get", "(", "x", ")", "is", "None", "or", "cron", "[", "x", "]", "==", "six", ".", "text_type", "(", "kwargs", "[", "x", "]", "...
Returns true if the minute, hour, etc. params match their counterparts from the dict returned from list_tab().
[ "Returns", "true", "if", "the", "minute", "hour", "etc", ".", "params", "match", "their", "counterparts", "from", "the", "dict", "returned", "from", "list_tab", "()", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L270-L277
train
Returns true if the minute hour etc. params match their counterparts from the dict returned from list_tab(). Returns false otherwise
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
raw_cron
def raw_cron(user): ''' Return the contents of the user's crontab CLI Example: .. code-block:: bash salt '*' cron.raw_cron root ''' if _check_instance_uid_match(user) or __grains__.get('os_family') in ('Solaris', 'AIX'): cmd = 'crontab -l' # Preserve line endings ...
python
def raw_cron(user): ''' Return the contents of the user's crontab CLI Example: .. code-block:: bash salt '*' cron.raw_cron root ''' if _check_instance_uid_match(user) or __grains__.get('os_family') in ('Solaris', 'AIX'): cmd = 'crontab -l' # Preserve line endings ...
[ "def", "raw_cron", "(", "user", ")", ":", "if", "_check_instance_uid_match", "(", "user", ")", "or", "__grains__", ".", "get", "(", "'os_family'", ")", "in", "(", "'Solaris'", ",", "'AIX'", ")", ":", "cmd", "=", "'crontab -l'", "# Preserve line endings", "li...
Return the contents of the user's crontab CLI Example: .. code-block:: bash salt '*' cron.raw_cron root
[ "Return", "the", "contents", "of", "the", "user", "s", "crontab" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L280-L312
train
Return the contents of the user s crontab Taxonomy CLI Example : bash AttributeNames salt '*' cron. raw_cron root AttributeNames
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
list_tab
def list_tab(user): ''' Return the contents of the specified user's crontab CLI Example: .. code-block:: bash salt '*' cron.list_tab root ''' data = raw_cron(user) ret = {'pre': [], 'crons': [], 'special': [], 'env': []} flag = False commen...
python
def list_tab(user): ''' Return the contents of the specified user's crontab CLI Example: .. code-block:: bash salt '*' cron.list_tab root ''' data = raw_cron(user) ret = {'pre': [], 'crons': [], 'special': [], 'env': []} flag = False commen...
[ "def", "list_tab", "(", "user", ")", ":", "data", "=", "raw_cron", "(", "user", ")", "ret", "=", "{", "'pre'", ":", "[", "]", ",", "'crons'", ":", "[", "]", ",", "'special'", ":", "[", "]", ",", "'env'", ":", "[", "]", "}", "flag", "=", "Fals...
Return the contents of the specified user's crontab CLI Example: .. code-block:: bash salt '*' cron.list_tab root
[ "Return", "the", "contents", "of", "the", "specified", "user", "s", "crontab" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L315-L404
train
Return the contents of the specified user s crontab CLI Example : bash salt '*' cron. list_tab root
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
get_entry
def get_entry(user, identifier=None, cmd=None): ''' Return the specified entry from user's crontab. identifier will be used if specified, otherwise will lookup cmd Either identifier or cmd should be specified. user: User's crontab to query identifier: Search for line with ident...
python
def get_entry(user, identifier=None, cmd=None): ''' Return the specified entry from user's crontab. identifier will be used if specified, otherwise will lookup cmd Either identifier or cmd should be specified. user: User's crontab to query identifier: Search for line with ident...
[ "def", "get_entry", "(", "user", ",", "identifier", "=", "None", ",", "cmd", "=", "None", ")", ":", "cron_entries", "=", "list_tab", "(", "user", ")", ".", "get", "(", "'crons'", ",", "False", ")", "for", "cron_entry", "in", "cron_entries", ":", "if", ...
Return the specified entry from user's crontab. identifier will be used if specified, otherwise will lookup cmd Either identifier or cmd should be specified. user: User's crontab to query identifier: Search for line with identifier cmd: Search for cron line with cmd C...
[ "Return", "the", "specified", "entry", "from", "user", "s", "crontab", ".", "identifier", "will", "be", "used", "if", "specified", "otherwise", "will", "lookup", "cmd", "Either", "identifier", "or", "cmd", "should", "be", "specified", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L411-L438
train
Get the specified entry from user s crontab.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
set_special
def set_special(user, special, cmd, commented=False, comment=None, identifier=None): ''' Set up a special command in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_special root @hourly 'echo foob...
python
def set_special(user, special, cmd, commented=False, comment=None, identifier=None): ''' Set up a special command in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_special root @hourly 'echo foob...
[ "def", "set_special", "(", "user", ",", "special", ",", "cmd", ",", "commented", "=", "False", ",", "comment", "=", "None", ",", "identifier", "=", "None", ")", ":", "lst", "=", "list_tab", "(", "user", ")", "for", "cron", "in", "lst", "[", "'special...
Set up a special command in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_special root @hourly 'echo foobar'
[ "Set", "up", "a", "special", "command", "in", "the", "crontab", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L441-L516
train
Set a special command in the crontab.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
_get_cron_date_time
def _get_cron_date_time(**kwargs): ''' Returns a dict of date/time values to be used in a cron entry ''' # Define ranges (except daymonth, as it depends on the month) range_max = { 'minute': list(list(range(60))), 'hour': list(list(range(24))), 'month': list(list(range(1, 13)...
python
def _get_cron_date_time(**kwargs): ''' Returns a dict of date/time values to be used in a cron entry ''' # Define ranges (except daymonth, as it depends on the month) range_max = { 'minute': list(list(range(60))), 'hour': list(list(range(24))), 'month': list(list(range(1, 13)...
[ "def", "_get_cron_date_time", "(", "*", "*", "kwargs", ")", ":", "# Define ranges (except daymonth, as it depends on the month)", "range_max", "=", "{", "'minute'", ":", "list", "(", "list", "(", "range", "(", "60", ")", ")", ")", ",", "'hour'", ":", "list", "...
Returns a dict of date/time values to be used in a cron entry
[ "Returns", "a", "dict", "of", "date", "/", "time", "values", "to", "be", "used", "in", "a", "cron", "entry" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L519-L558
train
Returns a dict of date and time values to be used in a cron entry
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
set_job
def set_job(user, minute, hour, daymonth, month, dayweek, cmd, commented=False, comment=None, identifier=None): ''' Sets a cron job up for a specified user. CLI Example: .. code-block:: bash ...
python
def set_job(user, minute, hour, daymonth, month, dayweek, cmd, commented=False, comment=None, identifier=None): ''' Sets a cron job up for a specified user. CLI Example: .. code-block:: bash ...
[ "def", "set_job", "(", "user", ",", "minute", ",", "hour", ",", "daymonth", ",", "month", ",", "dayweek", ",", "cmd", ",", "commented", "=", "False", ",", "comment", "=", "None", ",", "identifier", "=", "None", ")", ":", "# Scrub the types", "minute", ...
Sets a cron job up for a specified user. CLI Example: .. code-block:: bash salt '*' cron.set_job root '*' '*' '*' '*' 1 /usr/local/weekly
[ "Sets", "a", "cron", "job", "up", "for", "a", "specified", "user", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L561-L661
train
Sets a cron job up for a user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
rm_special
def rm_special(user, cmd, special=None, identifier=None): ''' Remove a special cron job for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_special root /usr/bin/foo ''' lst = list_tab(user) ret = 'absent' rm_ = None for ind in range(len(lst['special']...
python
def rm_special(user, cmd, special=None, identifier=None): ''' Remove a special cron job for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_special root /usr/bin/foo ''' lst = list_tab(user) ret = 'absent' rm_ = None for ind in range(len(lst['special']...
[ "def", "rm_special", "(", "user", ",", "cmd", ",", "special", "=", "None", ",", "identifier", "=", "None", ")", ":", "lst", "=", "list_tab", "(", "user", ")", "ret", "=", "'absent'", "rm_", "=", "None", "for", "ind", "in", "range", "(", "len", "(",...
Remove a special cron job for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_special root /usr/bin/foo
[ "Remove", "a", "special", "cron", "job", "for", "a", "specified", "user", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L664-L694
train
Remove a special cron job for a specified user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
rm_job
def rm_job(user, cmd, minute=None, hour=None, daymonth=None, month=None, dayweek=None, identifier=None): ''' Remove a cron job for a specified user. If any of the day/time params are specified, the job will only be removed if the s...
python
def rm_job(user, cmd, minute=None, hour=None, daymonth=None, month=None, dayweek=None, identifier=None): ''' Remove a cron job for a specified user. If any of the day/time params are specified, the job will only be removed if the s...
[ "def", "rm_job", "(", "user", ",", "cmd", ",", "minute", "=", "None", ",", "hour", "=", "None", ",", "daymonth", "=", "None", ",", "month", "=", "None", ",", "dayweek", "=", "None", ",", "identifier", "=", "None", ")", ":", "lst", "=", "list_tab", ...
Remove a cron job for a specified user. If any of the day/time params are specified, the job will only be removed if the specified params match. CLI Example: .. code-block:: bash salt '*' cron.rm_job root /usr/local/weekly salt '*' cron.rm_job root /usr/bin/foo dayweek=1
[ "Remove", "a", "cron", "job", "for", "a", "specified", "user", ".", "If", "any", "of", "the", "day", "/", "time", "params", "are", "specified", "the", "job", "will", "only", "be", "removed", "if", "the", "specified", "params", "match", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L697-L742
train
Remove a cron job for a specified user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
set_env
def set_env(user, name, value=None): ''' Set up an environment variable in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_env root MAILTO user@example.com ''' lst = list_tab(user) for env in lst['env']: if name == env['name']: if value != env[...
python
def set_env(user, name, value=None): ''' Set up an environment variable in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_env root MAILTO user@example.com ''' lst = list_tab(user) for env in lst['env']: if name == env['name']: if value != env[...
[ "def", "set_env", "(", "user", ",", "name", ",", "value", "=", "None", ")", ":", "lst", "=", "list_tab", "(", "user", ")", "for", "env", "in", "lst", "[", "'env'", "]", ":", "if", "name", "==", "env", "[", "'name'", "]", ":", "if", "value", "!=...
Set up an environment variable in the crontab. CLI Example: .. code-block:: bash salt '*' cron.set_env root MAILTO user@example.com
[ "Set", "up", "an", "environment", "variable", "in", "the", "crontab", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L748-L775
train
Set an environment variable in the crontab.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/cron.py
rm_env
def rm_env(user, name): ''' Remove cron environment variable for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_env root MAILTO ''' lst = list_tab(user) ret = 'absent' rm_ = None for ind in range(len(lst['env'])): if name == lst['env'][ind]['n...
python
def rm_env(user, name): ''' Remove cron environment variable for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_env root MAILTO ''' lst = list_tab(user) ret = 'absent' rm_ = None for ind in range(len(lst['env'])): if name == lst['env'][ind]['n...
[ "def", "rm_env", "(", "user", ",", "name", ")", ":", "lst", "=", "list_tab", "(", "user", ")", "ret", "=", "'absent'", "rm_", "=", "None", "for", "ind", "in", "range", "(", "len", "(", "lst", "[", "'env'", "]", ")", ")", ":", "if", "name", "=="...
Remove cron environment variable for a specified user. CLI Example: .. code-block:: bash salt '*' cron.rm_env root MAILTO
[ "Remove", "cron", "environment", "variable", "for", "a", "specified", "user", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/cron.py#L778-L801
train
Remove a specific environment variable for a specified user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
exists
def exists(Bucket, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name, check to see if the given bucket exists. Returns True if the given bucket exists and returns False if the given bucket does not exist. CLI Example: .. code-block:: bash salt mymin...
python
def exists(Bucket, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name, check to see if the given bucket exists. Returns True if the given bucket exists and returns False if the given bucket does not exist. CLI Example: .. code-block:: bash salt mymin...
[ "def", "exists", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key", ","...
Given a bucket name, check to see if the given bucket exists. Returns True if the given bucket exists and returns False if the given bucket does not exist. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.exists mybucket
[ "Given", "a", "bucket", "name", "check", "to", "see", "if", "the", "given", "bucket", "exists", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L103-L127
train
Given a bucket name check to see if the given bucket exists.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
create
def create(Bucket, ACL=None, LocationConstraint=None, GrantFullControl=None, GrantRead=None, GrantReadACP=None, GrantWrite=None, GrantWriteACP=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, create an ...
python
def create(Bucket, ACL=None, LocationConstraint=None, GrantFullControl=None, GrantRead=None, GrantReadACP=None, GrantWrite=None, GrantWriteACP=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, create an ...
[ "def", "create", "(", "Bucket", ",", "ACL", "=", "None", ",", "LocationConstraint", "=", "None", ",", "GrantFullControl", "=", "None", ",", "GrantRead", "=", "None", ",", "GrantReadACP", "=", "None", ",", "GrantWrite", "=", "None", ",", "GrantWriteACP", "=...
Given a valid config, create an S3 Bucket. Returns {created: true} if the bucket was created and returns {created: False} if the bucket was not created. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.create my_bucket \\ GrantFullControl='emailaddress=...
[ "Given", "a", "valid", "config", "create", "an", "S3", "Bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L130-L177
train
Given a valid config create an S3 Bucket. Returns a dictionary with the name of the bucket and location of the new bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete
def delete(Bucket, MFA=None, RequestPayer=None, Force=False, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name, delete it, optionally emptying it first. Returns {deleted: true} if the bucket was deleted and returns {deleted: false} if the bucket was not deleted. ...
python
def delete(Bucket, MFA=None, RequestPayer=None, Force=False, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name, delete it, optionally emptying it first. Returns {deleted: true} if the bucket was deleted and returns {deleted: false} if the bucket was not deleted. ...
[ "def", "delete", "(", "Bucket", ",", "MFA", "=", "None", ",", "RequestPayer", "=", "None", ",", "Force", "=", "False", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", "...
Given a bucket name, delete it, optionally emptying it first. Returns {deleted: true} if the bucket was deleted and returns {deleted: false} if the bucket was not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete mybucket
[ "Given", "a", "bucket", "name", "delete", "it", "optionally", "emptying", "it", "first", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L180-L204
train
Given a bucket name delete it optionally emptying it first.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_objects
def delete_objects(Bucket, Delete, MFA=None, RequestPayer=None, region=None, key=None, keyid=None, profile=None): ''' Delete objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. ...
python
def delete_objects(Bucket, Delete, MFA=None, RequestPayer=None, region=None, key=None, keyid=None, profile=None): ''' Delete objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. ...
[ "def", "delete_objects", "(", "Bucket", ",", "Delete", ",", "MFA", "=", "None", ",", "RequestPayer", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "if", "isinstance...
Delete objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_objects mybucket '{Objects: [Key: myobject]}'
[ "Delete", "objects", "in", "a", "given", "S3", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L207-L249
train
Delete objects in a given S3 bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
describe
def describe(Bucket, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name describe its properties. Returns a dictionary of interesting properties. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.describe mybucket ''' try: ...
python
def describe(Bucket, region=None, key=None, keyid=None, profile=None): ''' Given a bucket name describe its properties. Returns a dictionary of interesting properties. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.describe mybucket ''' try: ...
[ "def", "describe", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key", "...
Given a bucket name describe its properties. Returns a dictionary of interesting properties. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.describe mybucket
[ "Given", "a", "bucket", "name", "describe", "its", "properties", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L252-L315
train
Given a bucket name describe its properties.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
empty
def empty(Bucket, MFA=None, RequestPayer=None, region=None, key=None, keyid=None, profile=None): ''' Delete all objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. code-block:: bash ...
python
def empty(Bucket, MFA=None, RequestPayer=None, region=None, key=None, keyid=None, profile=None): ''' Delete all objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. code-block:: bash ...
[ "def", "empty", "(", "Bucket", ",", "MFA", "=", "None", ",", "RequestPayer", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "stuff", "=", "list_object_versions", "("...
Delete all objects in a given S3 bucket. Returns {deleted: true} if all objects were deleted and {deleted: false, failed: [key, ...]} otherwise CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.empty mybucket
[ "Delete", "all", "objects", "in", "a", "given", "S3", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L318-L345
train
Delete all objects in a given S3 bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
list
def list(region=None, key=None, keyid=None, profile=None): ''' List all buckets owned by the authenticated sender of the request. Returns list of buckets CLI Example: .. code-block:: yaml Owner: {...} Buckets: - {...} - {...} ''' try: conn = _...
python
def list(region=None, key=None, keyid=None, profile=None): ''' List all buckets owned by the authenticated sender of the request. Returns list of buckets CLI Example: .. code-block:: yaml Owner: {...} Buckets: - {...} - {...} ''' try: conn = _...
[ "def", "list", "(", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key", ",", "keyid", "=", ...
List all buckets owned by the authenticated sender of the request. Returns list of buckets CLI Example: .. code-block:: yaml Owner: {...} Buckets: - {...} - {...}
[ "List", "all", "buckets", "owned", "by", "the", "authenticated", "sender", "of", "the", "request", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L348-L373
train
List all buckets owned by the authenticated sender of the request.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
list_object_versions
def list_object_versions(Bucket, Delimiter=None, EncodingType=None, Prefix=None, region=None, key=None, keyid=None, profile=None): ''' List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.list_object...
python
def list_object_versions(Bucket, Delimiter=None, EncodingType=None, Prefix=None, region=None, key=None, keyid=None, profile=None): ''' List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.list_object...
[ "def", "list_object_versions", "(", "Bucket", ",", "Delimiter", "=", "None", ",", "EncodingType", "=", "None", ",", "Prefix", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")",...
List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.list_object_versions mybucket
[ "List", "objects", "in", "a", "given", "S3", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L376-L410
train
List objects in a given S3 bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
list_objects
def list_objects(Bucket, Delimiter=None, EncodingType=None, Prefix=None, FetchOwner=False, StartAfter=None, region=None, key=None, keyid=None, profile=None): ''' List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash ...
python
def list_objects(Bucket, Delimiter=None, EncodingType=None, Prefix=None, FetchOwner=False, StartAfter=None, region=None, key=None, keyid=None, profile=None): ''' List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash ...
[ "def", "list_objects", "(", "Bucket", ",", "Delimiter", "=", "None", ",", "EncodingType", "=", "None", ",", "Prefix", "=", "None", ",", "FetchOwner", "=", "False", ",", "StartAfter", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ","...
List objects in a given S3 bucket. Returns a list of objects. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.list_objects mybucket
[ "List", "objects", "in", "a", "given", "S3", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L413-L446
train
List objects in a given S3 bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_acl
def put_acl(Bucket, ACL=None, AccessControlPolicy=None, GrantFullControl=None, GrantRead=None, GrantReadACP=None, GrantWrite=None, GrantWriteACP=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid confi...
python
def put_acl(Bucket, ACL=None, AccessControlPolicy=None, GrantFullControl=None, GrantRead=None, GrantReadACP=None, GrantWrite=None, GrantWriteACP=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid confi...
[ "def", "put_acl", "(", "Bucket", ",", "ACL", "=", "None", ",", "AccessControlPolicy", "=", "None", ",", "GrantFullControl", "=", "None", ",", "GrantRead", "=", "None", ",", "GrantReadACP", "=", "None", ",", "GrantWrite", "=", "None", ",", "GrantWriteACP", ...
Given a valid config, update the ACL for a bucket. Returns {updated: true} if the ACL was updated and returns {updated: False} if the ACL was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_acl my_bucket 'public' \\ GrantFullControl='e...
[ "Given", "a", "valid", "config", "update", "the", "ACL", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L449-L491
train
Given a valid config update the ACL for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_cors
def put_cors(Bucket, CORSRules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the CORS rules for a bucket. Returns {updated: true} if CORS was updated and returns {updated: False} if CORS was not updated. CLI Example: .. code-block:: ...
python
def put_cors(Bucket, CORSRules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the CORS rules for a bucket. Returns {updated: true} if CORS was updated and returns {updated: False} if CORS was not updated. CLI Example: .. code-block:: ...
[ "def", "put_cors", "(", "Bucket", ",", "CORSRules", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key...
Given a valid config, update the CORS rules for a bucket. Returns {updated: true} if CORS was updated and returns {updated: False} if CORS was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_cors my_bucket '[{\\ "AllowedHeaders":[],\\ ...
[ "Given", "a", "valid", "config", "update", "the", "CORS", "rules", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L494-L524
train
Given a valid config update the CORS rules for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_lifecycle_configuration
def put_lifecycle_configuration(Bucket, Rules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the Lifecycle rules for a bucket. Returns {updated: true} if Lifecycle was updated and returns {updated: False} if Lifecycle was not updated. CLI ...
python
def put_lifecycle_configuration(Bucket, Rules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the Lifecycle rules for a bucket. Returns {updated: true} if Lifecycle was updated and returns {updated: False} if Lifecycle was not updated. CLI ...
[ "def", "put_lifecycle_configuration", "(", "Bucket", ",", "Rules", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region"...
Given a valid config, update the Lifecycle rules for a bucket. Returns {updated: true} if Lifecycle was updated and returns {updated: False} if Lifecycle was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_lifecycle_configuration my_bucket '[{\\ ...
[ "Given", "a", "valid", "config", "update", "the", "Lifecycle", "rules", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L527-L559
train
Given a valid config update the Lifecycle rules for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_logging
def put_logging(Bucket, TargetBucket=None, TargetPrefix=None, TargetGrants=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the logging parameters for a bucket. Returns {updated: true} if parameters were updated and returns {updated: False} ...
python
def put_logging(Bucket, TargetBucket=None, TargetPrefix=None, TargetGrants=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the logging parameters for a bucket. Returns {updated: true} if parameters were updated and returns {updated: False} ...
[ "def", "put_logging", "(", "Bucket", ",", "TargetBucket", "=", "None", ",", "TargetPrefix", "=", "None", ",", "TargetGrants", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")",...
Given a valid config, update the logging parameters for a bucket. Returns {updated: true} if parameters were updated and returns {updated: False} if parameters were not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_logging my_bucket log_bucket '[{...}]' prefix
[ "Given", "a", "valid", "config", "update", "the", "logging", "parameters", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L562-L597
train
Given a valid config update the logging parameters for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_notification_configuration
def put_notification_configuration(Bucket, TopicConfigurations=None, QueueConfigurations=None, LambdaFunctionConfigurations=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the notification parameters for a bucket. Returns {updated: t...
python
def put_notification_configuration(Bucket, TopicConfigurations=None, QueueConfigurations=None, LambdaFunctionConfigurations=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the notification parameters for a bucket. Returns {updated: t...
[ "def", "put_notification_configuration", "(", "Bucket", ",", "TopicConfigurations", "=", "None", ",", "QueueConfigurations", "=", "None", ",", "LambdaFunctionConfigurations", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "N...
Given a valid config, update the notification parameters for a bucket. Returns {updated: true} if parameters were updated and returns {updated: False} if parameters were not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_notification_configuration my_bucket ...
[ "Given", "a", "valid", "config", "update", "the", "notification", "parameters", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L600-L643
train
Given a valid config update the notification parameters for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_policy
def put_policy(Bucket, Policy, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the policy for a bucket. Returns {updated: true} if policy was updated and returns {updated: False} if policy was not updated. CLI Example: .. code-block:: bash ...
python
def put_policy(Bucket, Policy, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the policy for a bucket. Returns {updated: true} if policy was updated and returns {updated: False} if policy was not updated. CLI Example: .. code-block:: bash ...
[ "def", "put_policy", "(", "Bucket", ",", "Policy", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key"...
Given a valid config, update the policy for a bucket. Returns {updated: true} if policy was updated and returns {updated: False} if policy was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_policy my_bucket {...}
[ "Given", "a", "valid", "config", "update", "the", "policy", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L646-L671
train
Given a valid config update the policy for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_replication
def put_replication(Bucket, Role, Rules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the replication configuration for a bucket. Returns {updated: true} if replication configuration was updated and returns {updated: False} if replication configuration w...
python
def put_replication(Bucket, Role, Rules, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the replication configuration for a bucket. Returns {updated: true} if replication configuration was updated and returns {updated: False} if replication configuration w...
[ "def", "put_replication", "(", "Bucket", ",", "Role", ",", "Rules", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "re...
Given a valid config, update the replication configuration for a bucket. Returns {updated: true} if replication configuration was updated and returns {updated: False} if replication configuration was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_replication ...
[ "Given", "a", "valid", "config", "update", "the", "replication", "configuration", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L688-L718
train
Given a valid config update the replication configuration for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_request_payment
def put_request_payment(Bucket, Payer, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the request payment configuration for a bucket. Returns {updated: true} if request payment configuration was updated and returns {updated: False} if request payment confi...
python
def put_request_payment(Bucket, Payer, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the request payment configuration for a bucket. Returns {updated: true} if request payment configuration was updated and returns {updated: False} if request payment confi...
[ "def", "put_request_payment", "(", "Bucket", ",", "Payer", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",",...
Given a valid config, update the request payment configuration for a bucket. Returns {updated: true} if request payment configuration was updated and returns {updated: False} if request payment configuration was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_...
[ "Given", "a", "valid", "config", "update", "the", "request", "payment", "configuration", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L721-L744
train
Given a valid config update the request payment configuration for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_tagging
def put_tagging(Bucket, region=None, key=None, keyid=None, profile=None, **kwargs): ''' Given a valid config, update the tags for a bucket. Returns {updated: true} if tags were updated and returns {updated: False} if tags were not updated. CLI Example: .. code-block:: bash ...
python
def put_tagging(Bucket, region=None, key=None, keyid=None, profile=None, **kwargs): ''' Given a valid config, update the tags for a bucket. Returns {updated: true} if tags were updated and returns {updated: False} if tags were not updated. CLI Example: .. code-block:: bash ...
[ "def", "put_tagging", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ",", "*", "*", "kwargs", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region",...
Given a valid config, update the tags for a bucket. Returns {updated: true} if tags were updated and returns {updated: False} if tags were not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_tagging my_bucket my_role [...]
[ "Given", "a", "valid", "config", "update", "the", "tags", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L747-L775
train
Given a valid config update the tags for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_versioning
def put_versioning(Bucket, Status, MFADelete=None, MFA=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the versioning configuration for a bucket. Returns {updated: true} if versioning configuration was updated and returns {updated: False} if versionin...
python
def put_versioning(Bucket, Status, MFADelete=None, MFA=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the versioning configuration for a bucket. Returns {updated: true} if versioning configuration was updated and returns {updated: False} if versionin...
[ "def", "put_versioning", "(", "Bucket", ",", "Status", ",", "MFADelete", "=", "None", ",", "MFA", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn"...
Given a valid config, update the versioning configuration for a bucket. Returns {updated: true} if versioning configuration was updated and returns {updated: False} if versioning configuration was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_versioning my_b...
[ "Given", "a", "valid", "config", "update", "the", "versioning", "configuration", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L778-L807
train
Given a valid config update the versioning configuration for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
put_website
def put_website(Bucket, ErrorDocument=None, IndexDocument=None, RedirectAllRequestsTo=None, RoutingRules=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the website configuration for a bucket. Returns {updated: true} if website configuration wa...
python
def put_website(Bucket, ErrorDocument=None, IndexDocument=None, RedirectAllRequestsTo=None, RoutingRules=None, region=None, key=None, keyid=None, profile=None): ''' Given a valid config, update the website configuration for a bucket. Returns {updated: true} if website configuration wa...
[ "def", "put_website", "(", "Bucket", ",", "ErrorDocument", "=", "None", ",", "IndexDocument", "=", "None", ",", "RedirectAllRequestsTo", "=", "None", ",", "RoutingRules", "=", "None", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", ...
Given a valid config, update the website configuration for a bucket. Returns {updated: true} if website configuration was updated and returns {updated: False} if website configuration was not updated. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.put_website my_bucket IndexD...
[ "Given", "a", "valid", "config", "update", "the", "website", "configuration", "for", "a", "bucket", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L810-L842
train
Given a valid config update the website configuration for a bucket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_cors
def delete_cors(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the CORS configuration for the given bucket Returns {deleted: true} if CORS was deleted and returns {deleted: False} if CORS was not deleted. CLI Example: .. code-block:: bash salt myminio...
python
def delete_cors(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the CORS configuration for the given bucket Returns {deleted: true} if CORS was deleted and returns {deleted: False} if CORS was not deleted. CLI Example: .. code-block:: bash salt myminio...
[ "def", "delete_cors", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key", ...
Delete the CORS configuration for the given bucket Returns {deleted: true} if CORS was deleted and returns {deleted: False} if CORS was not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_cors my_bucket
[ "Delete", "the", "CORS", "configuration", "for", "the", "given", "bucket" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L845-L866
train
Delete the CORS configuration for the given bucket
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_lifecycle_configuration
def delete_lifecycle_configuration(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the lifecycle configuration for the given bucket Returns {deleted: true} if Lifecycle was deleted and returns {deleted: False} if Lifecycle was not deleted. CLI Example: .. code-...
python
def delete_lifecycle_configuration(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the lifecycle configuration for the given bucket Returns {deleted: true} if Lifecycle was deleted and returns {deleted: False} if Lifecycle was not deleted. CLI Example: .. code-...
[ "def", "delete_lifecycle_configuration", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key...
Delete the lifecycle configuration for the given bucket Returns {deleted: true} if Lifecycle was deleted and returns {deleted: False} if Lifecycle was not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_lifecycle_configuration my_bucket
[ "Delete", "the", "lifecycle", "configuration", "for", "the", "given", "bucket" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L869-L890
train
Delete the lifecycle configuration for the given bucket
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_replication
def delete_replication(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the replication config from the given bucket Returns {deleted: true} if replication configuration was deleted and returns {deleted: False} if replication configuration was not deleted. CLI Exampl...
python
def delete_replication(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the replication config from the given bucket Returns {deleted: true} if replication configuration was deleted and returns {deleted: False} if replication configuration was not deleted. CLI Exampl...
[ "def", "delete_replication", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", ...
Delete the replication config from the given bucket Returns {deleted: true} if replication configuration was deleted and returns {deleted: False} if replication configuration was not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_replication my_bucket
[ "Delete", "the", "replication", "config", "from", "the", "given", "bucket" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L917-L938
train
Delete the replication config from the given bucket
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_tagging
def delete_tagging(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the tags from the given bucket Returns {deleted: true} if tags were deleted and returns {deleted: False} if tags were not deleted. CLI Example: .. code-block:: bash salt myminion boto_s...
python
def delete_tagging(Bucket, region=None, key=None, keyid=None, profile=None): ''' Delete the tags from the given bucket Returns {deleted: true} if tags were deleted and returns {deleted: False} if tags were not deleted. CLI Example: .. code-block:: bash salt myminion boto_s...
[ "def", "delete_tagging", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key...
Delete the tags from the given bucket Returns {deleted: true} if tags were deleted and returns {deleted: False} if tags were not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_tagging my_bucket
[ "Delete", "the", "tags", "from", "the", "given", "bucket" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L941-L962
train
Delete the tags from the given bucket Returns True if the tags were deleted False otherwise
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/boto_s3_bucket.py
delete_website
def delete_website(Bucket, region=None, key=None, keyid=None, profile=None): ''' Remove the website configuration from the given bucket Returns {deleted: true} if website configuration was deleted and returns {deleted: False} if website configuration was not deleted. CLI Example: ....
python
def delete_website(Bucket, region=None, key=None, keyid=None, profile=None): ''' Remove the website configuration from the given bucket Returns {deleted: true} if website configuration was deleted and returns {deleted: False} if website configuration was not deleted. CLI Example: ....
[ "def", "delete_website", "(", "Bucket", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "try", ":", "conn", "=", "_get_conn", "(", "region", "=", "region", ",", "key", "=", "key...
Remove the website configuration from the given bucket Returns {deleted: true} if website configuration was deleted and returns {deleted: False} if website configuration was not deleted. CLI Example: .. code-block:: bash salt myminion boto_s3_bucket.delete_website my_bucket
[ "Remove", "the", "website", "configuration", "from", "the", "given", "bucket" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/boto_s3_bucket.py#L965-L986
train
Delete the website configuration from the given bucket
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/acl/__init__.py
PublisherACL.user_is_blacklisted
def user_is_blacklisted(self, user): ''' Takes a username as a string and returns a boolean. True indicates that the provided user has been blacklisted ''' return not salt.utils.stringutils.check_whitelist_blacklist(user, blacklist=self.blacklist.get('users', []))
python
def user_is_blacklisted(self, user): ''' Takes a username as a string and returns a boolean. True indicates that the provided user has been blacklisted ''' return not salt.utils.stringutils.check_whitelist_blacklist(user, blacklist=self.blacklist.get('users', []))
[ "def", "user_is_blacklisted", "(", "self", ",", "user", ")", ":", "return", "not", "salt", ".", "utils", ".", "stringutils", ".", "check_whitelist_blacklist", "(", "user", ",", "blacklist", "=", "self", ".", "blacklist", ".", "get", "(", "'users'", ",", "[...
Takes a username as a string and returns a boolean. True indicates that the provided user has been blacklisted
[ "Takes", "a", "username", "as", "a", "string", "and", "returns", "a", "boolean", ".", "True", "indicates", "that", "the", "provided", "user", "has", "been", "blacklisted" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/acl/__init__.py#L29-L34
train
Returns a boolean indicating whether the user is blacklisted by the current user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/pagerduty_escalation_policy.py
present
def present(profile='pagerduty', subdomain=None, api_key=None, **kwargs): ''' Ensure that a pagerduty escalation policy exists. Will create or update as needed. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/escalation_policies/create. In addit...
python
def present(profile='pagerduty', subdomain=None, api_key=None, **kwargs): ''' Ensure that a pagerduty escalation policy exists. Will create or update as needed. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/escalation_policies/create. In addit...
[ "def", "present", "(", "profile", "=", "'pagerduty'", ",", "subdomain", "=", "None", ",", "api_key", "=", "None", ",", "*", "*", "kwargs", ")", ":", "# for convenience, we accept id, name, or email for users", "# and we accept the id or name for schedules", "for", "esca...
Ensure that a pagerduty escalation policy exists. Will create or update as needed. This method accepts as args everything defined in https://developer.pagerduty.com/documentation/rest/escalation_policies/create. In addition, user and schedule id's will be translated from name (or email address) into P...
[ "Ensure", "that", "a", "pagerduty", "escalation", "policy", "exists", ".", "Will", "create", "or", "update", "as", "needed", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/pagerduty_escalation_policy.py#L49-L107
train
Ensure that a pagerduty escalation policy exists.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/pagerduty_escalation_policy.py
_diff
def _diff(state_data, resource_object): '''helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update. ''' objects_differ = None for k, v in state_d...
python
def _diff(state_data, resource_object): '''helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update. ''' objects_differ = None for k, v in state_d...
[ "def", "_diff", "(", "state_data", ",", "resource_object", ")", ":", "objects_differ", "=", "None", "for", "k", ",", "v", "in", "state_data", ".", "items", "(", ")", ":", "if", "k", "==", "'escalation_rules'", ":", "v", "=", "_escalation_rules_to_string", ...
helper method to compare salt state info with the PagerDuty API json structure, and determine if we need to update. returns the dict to pass to the PD API to perform the update, or empty dict if no update.
[ "helper", "method", "to", "compare", "salt", "state", "info", "with", "the", "PagerDuty", "API", "json", "structure", "and", "determine", "if", "we", "need", "to", "update", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/pagerduty_escalation_policy.py#L127-L151
train
helper method to compare salt state info with PagerDuty API json structure and determine if we need to update.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/pagerduty_escalation_policy.py
_escalation_rules_to_string
def _escalation_rules_to_string(escalation_rules): 'convert escalation_rules dict to a string for comparison' result = '' for rule in escalation_rules: result += 'escalation_delay_in_minutes: {0} '.format(rule['escalation_delay_in_minutes']) for target in rule['targets']: result ...
python
def _escalation_rules_to_string(escalation_rules): 'convert escalation_rules dict to a string for comparison' result = '' for rule in escalation_rules: result += 'escalation_delay_in_minutes: {0} '.format(rule['escalation_delay_in_minutes']) for target in rule['targets']: result ...
[ "def", "_escalation_rules_to_string", "(", "escalation_rules", ")", ":", "result", "=", "''", "for", "rule", "in", "escalation_rules", ":", "result", "+=", "'escalation_delay_in_minutes: {0} '", ".", "format", "(", "rule", "[", "'escalation_delay_in_minutes'", "]", ")...
convert escalation_rules dict to a string for comparison
[ "convert", "escalation_rules", "dict", "to", "a", "string", "for", "comparison" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/pagerduty_escalation_policy.py#L154-L161
train
convert escalation_rules dict to a string for comparison
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/rabbitmq_user.py
_check_perms_changes
def _check_perms_changes(name, newperms, runas=None, existing=None): ''' Check whether Rabbitmq user's permissions need to be changed. ''' if not newperms: return False if existing is None: try: existing = __salt__['rabbitmq.list_user_permissions'](name, runas=runas) ...
python
def _check_perms_changes(name, newperms, runas=None, existing=None): ''' Check whether Rabbitmq user's permissions need to be changed. ''' if not newperms: return False if existing is None: try: existing = __salt__['rabbitmq.list_user_permissions'](name, runas=runas) ...
[ "def", "_check_perms_changes", "(", "name", ",", "newperms", ",", "runas", "=", "None", ",", "existing", "=", "None", ")", ":", "if", "not", "newperms", ":", "return", "False", "if", "existing", "is", "None", ":", "try", ":", "existing", "=", "__salt__",...
Check whether Rabbitmq user's permissions need to be changed.
[ "Check", "whether", "Rabbitmq", "user", "s", "permissions", "need", "to", "be", "changed", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/rabbitmq_user.py#L44-L73
train
Check whether Rabbitmq user s permissions need to be changed.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/rabbitmq_user.py
_get_current_tags
def _get_current_tags(name, runas=None): ''' Whether Rabbitmq user's tags need to be changed ''' try: return list(__salt__['rabbitmq.list_users'](runas=runas)[name]) except CommandExecutionError as err: log.error('Error: %s', err) return []
python
def _get_current_tags(name, runas=None): ''' Whether Rabbitmq user's tags need to be changed ''' try: return list(__salt__['rabbitmq.list_users'](runas=runas)[name]) except CommandExecutionError as err: log.error('Error: %s', err) return []
[ "def", "_get_current_tags", "(", "name", ",", "runas", "=", "None", ")", ":", "try", ":", "return", "list", "(", "__salt__", "[", "'rabbitmq.list_users'", "]", "(", "runas", "=", "runas", ")", "[", "name", "]", ")", "except", "CommandExecutionError", "as",...
Whether Rabbitmq user's tags need to be changed
[ "Whether", "Rabbitmq", "user", "s", "tags", "need", "to", "be", "changed" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/rabbitmq_user.py#L76-L84
train
Return a list of Rabbitmq user s tags
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/rabbitmq_user.py
present
def present(name, password=None, force=False, tags=None, perms=(), runas=None): ''' Ensure the RabbitMQ user exists. name User name password User's password, if one needs to be set force If user exists, forcibly cha...
python
def present(name, password=None, force=False, tags=None, perms=(), runas=None): ''' Ensure the RabbitMQ user exists. name User name password User's password, if one needs to be set force If user exists, forcibly cha...
[ "def", "present", "(", "name", ",", "password", "=", "None", ",", "force", "=", "False", ",", "tags", "=", "None", ",", "perms", "=", "(", ")", ",", "runas", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "...
Ensure the RabbitMQ user exists. name User name password User's password, if one needs to be set force If user exists, forcibly change the password tags Optional list of tags for the user perms A list of dicts with vhost keys and 3-tuple values runas ...
[ "Ensure", "the", "RabbitMQ", "user", "exists", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/rabbitmq_user.py#L87-L229
train
Ensure a RabbitMQ user exists and is up to date.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/rabbitmq_user.py
absent
def absent(name, runas=None): ''' Ensure the named user is absent name The name of the user to remove runas User to run the command ''' ret = {'name': name, 'result': False, 'comment': '', 'changes': {}} try: user_exists = __salt__['rabbitmq.user_exists']...
python
def absent(name, runas=None): ''' Ensure the named user is absent name The name of the user to remove runas User to run the command ''' ret = {'name': name, 'result': False, 'comment': '', 'changes': {}} try: user_exists = __salt__['rabbitmq.user_exists']...
[ "def", "absent", "(", "name", ",", "runas", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "try", ":", "user_exists", "=", "__salt__",...
Ensure the named user is absent name The name of the user to remove runas User to run the command
[ "Ensure", "the", "named", "user", "is", "absent" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/rabbitmq_user.py#L232-L272
train
Ensure the named user is absent
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
pause
def pause(jid, state_id=None, duration=None): ''' Set up a state id pause, this instructs a running state to pause at a given state id. This needs to pass in the jid of the running state and can optionally pass in a duration in seconds. ''' minion = salt.minion.MasterMinion(__opts__) minion....
python
def pause(jid, state_id=None, duration=None): ''' Set up a state id pause, this instructs a running state to pause at a given state id. This needs to pass in the jid of the running state and can optionally pass in a duration in seconds. ''' minion = salt.minion.MasterMinion(__opts__) minion....
[ "def", "pause", "(", "jid", ",", "state_id", "=", "None", ",", "duration", "=", "None", ")", ":", "minion", "=", "salt", ".", "minion", ".", "MasterMinion", "(", "__opts__", ")", "minion", ".", "functions", "[", "'state.pause'", "]", "(", "jid", ",", ...
Set up a state id pause, this instructs a running state to pause at a given state id. This needs to pass in the jid of the running state and can optionally pass in a duration in seconds.
[ "Set", "up", "a", "state", "id", "pause", "this", "instructs", "a", "running", "state", "to", "pause", "at", "a", "given", "state", "id", ".", "This", "needs", "to", "pass", "in", "the", "jid", "of", "the", "running", "state", "and", "can", "optionally...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L19-L26
train
Pause a state id at a given jid
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
resume
def resume(jid, state_id=None): ''' Remove a pause from a jid, allowing it to continue ''' minion = salt.minion.MasterMinion(__opts__) minion.functions['state.resume'](jid, state_id)
python
def resume(jid, state_id=None): ''' Remove a pause from a jid, allowing it to continue ''' minion = salt.minion.MasterMinion(__opts__) minion.functions['state.resume'](jid, state_id)
[ "def", "resume", "(", "jid", ",", "state_id", "=", "None", ")", ":", "minion", "=", "salt", ".", "minion", ".", "MasterMinion", "(", "__opts__", ")", "minion", ".", "functions", "[", "'state.resume'", "]", "(", "jid", ",", "state_id", ")" ]
Remove a pause from a jid, allowing it to continue
[ "Remove", "a", "pause", "from", "a", "jid", "allowing", "it", "to", "continue" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L32-L37
train
Resume a paused state
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
soft_kill
def soft_kill(jid, state_id=None): ''' Set up a state run to die before executing the given state id, this instructs a running state to safely exit at a given state id. This needs to pass in the jid of the running state. If a state_id is not passed then the jid referenced will be safely exited a...
python
def soft_kill(jid, state_id=None): ''' Set up a state run to die before executing the given state id, this instructs a running state to safely exit at a given state id. This needs to pass in the jid of the running state. If a state_id is not passed then the jid referenced will be safely exited a...
[ "def", "soft_kill", "(", "jid", ",", "state_id", "=", "None", ")", ":", "minion", "=", "salt", ".", "minion", ".", "MasterMinion", "(", "__opts__", ")", "minion", ".", "functions", "[", "'state.soft_kill'", "]", "(", "jid", ",", "state_id", ")" ]
Set up a state run to die before executing the given state id, this instructs a running state to safely exit at a given state id. This needs to pass in the jid of the running state. If a state_id is not passed then the jid referenced will be safely exited at the beginning of the next state run.
[ "Set", "up", "a", "state", "run", "to", "die", "before", "executing", "the", "given", "state", "id", "this", "instructs", "a", "running", "state", "to", "safely", "exit", "at", "a", "given", "state", "id", ".", "This", "needs", "to", "pass", "in", "the...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L43-L52
train
This is a low level function that can be used to safely kill a state run at a given state id.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
orchestrate
def orchestrate(mods, saltenv='base', test=None, exclude=None, pillar=None, pillarenv=None, pillar_enc=None, orchestration_jid=None): ''' .. versionadded:: 0.17.0 Execute a state run from the mas...
python
def orchestrate(mods, saltenv='base', test=None, exclude=None, pillar=None, pillarenv=None, pillar_enc=None, orchestration_jid=None): ''' .. versionadded:: 0.17.0 Execute a state run from the mas...
[ "def", "orchestrate", "(", "mods", ",", "saltenv", "=", "'base'", ",", "test", "=", "None", ",", "exclude", "=", "None", ",", "pillar", "=", "None", ",", "pillarenv", "=", "None", ",", "pillar_enc", "=", "None", ",", "orchestration_jid", "=", "None", "...
.. versionadded:: 0.17.0 Execute a state run from the master, used as a powerful orchestration system. .. seealso:: More Orchestrate documentation * :ref:`Full Orchestrate Tutorial <orchestrate-runner>` * :py:mod:`Docs for the master-side state module <salt.states.saltmod>` CLI Examp...
[ "..", "versionadded", "::", "0", ".", "17", ".", "0" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L55-L135
train
Execute a state run from the master and return the state module id
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
orchestrate_single
def orchestrate_single(fun, name, test=None, queue=False, pillar=None, **kwargs): ''' Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_single fun=salt.wheel name=key.list_all ''' if pillar is not ...
python
def orchestrate_single(fun, name, test=None, queue=False, pillar=None, **kwargs): ''' Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_single fun=salt.wheel name=key.list_all ''' if pillar is not ...
[ "def", "orchestrate_single", "(", "fun", ",", "name", ",", "test", "=", "None", ",", "queue", "=", "False", ",", "pillar", "=", "None", ",", "*", "*", "kwargs", ")", ":", "if", "pillar", "is", "not", "None", "and", "not", "isinstance", "(", "pillar",...
Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_single fun=salt.wheel name=key.list_all
[ "Execute", "a", "single", "state", "orchestration", "routine" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L143-L170
train
Execute a single state orchestration routine
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
orchestrate_high
def orchestrate_high(data, test=None, queue=False, pillar=None, **kwargs): ''' Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_high '{ stage_one: {salt.state: [{tgt: "db*"}, {...
python
def orchestrate_high(data, test=None, queue=False, pillar=None, **kwargs): ''' Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_high '{ stage_one: {salt.state: [{tgt: "db*"}, {...
[ "def", "orchestrate_high", "(", "data", ",", "test", "=", "None", ",", "queue", "=", "False", ",", "pillar", "=", "None", ",", "*", "*", "kwargs", ")", ":", "if", "pillar", "is", "not", "None", "and", "not", "isinstance", "(", "pillar", ",", "dict", ...
Execute a single state orchestration routine .. versionadded:: 2015.5.0 CLI Example: .. code-block:: bash salt-run state.orchestrate_high '{ stage_one: {salt.state: [{tgt: "db*"}, {sls: postgres_setup}]}, stage_two: {salt.state: [{tgt: "web...
[ "Execute", "a", "single", "state", "orchestration", "routine" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L173-L206
train
Execute a single state orchestration routine
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
orchestrate_show_sls
def orchestrate_show_sls(mods, saltenv='base', test=None, queue=False, pillar=None, pillarenv=None, pillar_enc=None): ''' Display the state data from a specific s...
python
def orchestrate_show_sls(mods, saltenv='base', test=None, queue=False, pillar=None, pillarenv=None, pillar_enc=None): ''' Display the state data from a specific s...
[ "def", "orchestrate_show_sls", "(", "mods", ",", "saltenv", "=", "'base'", ",", "test", "=", "None", ",", "queue", "=", "False", ",", "pillar", "=", "None", ",", "pillarenv", "=", "None", ",", "pillar_enc", "=", "None", ")", ":", "if", "pillar", "is", ...
Display the state data from a specific sls, or list of sls files, after being render using the master minion. Note, the master minion adds a "_master" suffix to it's minion id. .. seealso:: The state.show_sls module function CLI Example: .. code-block:: bash salt-run state.orch_show_sls ...
[ "Display", "the", "state", "data", "from", "a", "specific", "sls", "or", "list", "of", "sls", "files", "after", "being", "render", "using", "the", "master", "minion", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L209-L245
train
Display the state data from a specific sls or list of sls files
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/runners/state.py
event
def event(tagmatch='*', count=-1, quiet=False, sock_dir=None, pretty=False, node='master'): r''' Watch Salt's event bus and block until the given tag is matched .. versionadded:: 2014.7.0 .. versionchanged:: 2019.2.0 ``tagmatch`` can now be eith...
python
def event(tagmatch='*', count=-1, quiet=False, sock_dir=None, pretty=False, node='master'): r''' Watch Salt's event bus and block until the given tag is matched .. versionadded:: 2014.7.0 .. versionchanged:: 2019.2.0 ``tagmatch`` can now be eith...
[ "def", "event", "(", "tagmatch", "=", "'*'", ",", "count", "=", "-", "1", ",", "quiet", "=", "False", ",", "sock_dir", "=", "None", ",", "pretty", "=", "False", ",", "node", "=", "'master'", ")", ":", "statemod", "=", "salt", ".", "loader", ".", ...
r''' Watch Salt's event bus and block until the given tag is matched .. versionadded:: 2014.7.0 .. versionchanged:: 2019.2.0 ``tagmatch`` can now be either a glob or regular expression. This is useful for utilizing Salt's event bus from shell scripts or for taking simple actions directly f...
[ "r", "Watch", "Salt", "s", "event", "bus", "and", "block", "until", "the", "given", "tag", "is", "matched" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/runners/state.py#L251-L313
train
r Watch the event bus and block until the given tag is matched.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/smtp.py
send_msg
def send_msg(recipient, message, subject='Message from Salt', sender=None, server=None, use_ssl='True', username=None, password=None, profile=None, attachments=None): ''' Send a message to an SMT...
python
def send_msg(recipient, message, subject='Message from Salt', sender=None, server=None, use_ssl='True', username=None, password=None, profile=None, attachments=None): ''' Send a message to an SMT...
[ "def", "send_msg", "(", "recipient", ",", "message", ",", "subject", "=", "'Message from Salt'", ",", "sender", "=", "None", ",", "server", "=", "None", ",", "use_ssl", "=", "'True'", ",", "username", "=", "None", ",", "password", "=", "None", ",", "prof...
Send a message to an SMTP recipient. Designed for use in states. CLI Examples: .. code-block:: bash salt '*' smtp.send_msg 'admin@example.com' 'This is a salt module test' profile='my-smtp-account' salt '*' smtp.send_msg 'admin@example.com' 'This is a salt module test' username='myuser' passw...
[ "Send", "a", "message", "to", "an", "SMTP", "recipient", ".", "Designed", "for", "use", "in", "states", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/smtp.py#L77-L175
train
Send a message to an SMTP recipient.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_distinguished_name
def add_distinguished_name(list_name, item_name): ''' Adds a distinguished name to a distinguished name list. list_name(str): The name of the specific policy distinguished name list to append to. item_name(str): The distinguished name to append. CLI Example: .. code-block:: bash sal...
python
def add_distinguished_name(list_name, item_name): ''' Adds a distinguished name to a distinguished name list. list_name(str): The name of the specific policy distinguished name list to append to. item_name(str): The distinguished name to append. CLI Example: .. code-block:: bash sal...
[ "def", "add_distinguished_name", "(", "list_name", ",", "item_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_distinguished_names\"", ",", "\"params\"", ":", "[", "list_name"...
Adds a distinguished name to a distinguished name list. list_name(str): The name of the specific policy distinguished name list to append to. item_name(str): The distinguished name to append. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_distinguished_name MyDistinguishedList...
[ "Adds", "a", "distinguished", "name", "to", "a", "distinguished", "name", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L76-L98
train
Adds a distinguished name to a specific policy distinguished name list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_distinguished_name_list
def add_distinguished_name_list(list_name): ''' Add a list of policy distinguished names. list_name(str): The name of the specific policy distinguished name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_distinguished_name_list MyDistinguishedList ''' ...
python
def add_distinguished_name_list(list_name): ''' Add a list of policy distinguished names. list_name(str): The name of the specific policy distinguished name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_distinguished_name_list MyDistinguishedList ''' ...
[ "def", "add_distinguished_name_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_distinguished_names_list\"", ",", "\"params\"", ":", "[", "{", "\"list_name\"",...
Add a list of policy distinguished names. list_name(str): The name of the specific policy distinguished name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_distinguished_name_list MyDistinguishedList
[ "Add", "a", "list", "of", "policy", "distinguished", "names", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L101-L121
train
Adds a list of policy distinguished names to the current node.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_domain_name
def add_domain_name(list_name, item_name): ''' Adds a domain name to a domain name list. list_name(str): The name of the specific policy domain name list to append to. item_name(str): The domain name to append. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name...
python
def add_domain_name(list_name, item_name): ''' Adds a domain name to a domain name list. list_name(str): The name of the specific policy domain name list to append to. item_name(str): The domain name to append. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name...
[ "def", "add_domain_name", "(", "list_name", ",", "item_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_domain_names\"", ",", "\"params\"", ":", "[", "list_name", ",", "{"...
Adds a domain name to a domain name list. list_name(str): The name of the specific policy domain name list to append to. item_name(str): The domain name to append. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name MyDomainName foo.bar.com
[ "Adds", "a", "domain", "name", "to", "a", "domain", "name", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L124-L146
train
Adds a domain name to a specific policy domain name list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_domain_name_list
def add_domain_name_list(list_name): ''' Add a list of policy domain names. list_name(str): The name of the specific policy domain name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name_list MyDomainNameList ''' payload = {"jsonrpc": "2.0", ...
python
def add_domain_name_list(list_name): ''' Add a list of policy domain names. list_name(str): The name of the specific policy domain name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name_list MyDomainNameList ''' payload = {"jsonrpc": "2.0", ...
[ "def", "add_domain_name_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_domain_names_list\"", ",", "\"params\"", ":", "[", "{", "\"list_name\"", ":", "lis...
Add a list of policy domain names. list_name(str): The name of the specific policy domain name list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_domain_name_list MyDomainNameList
[ "Add", "a", "list", "of", "policy", "domain", "names", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L149-L169
train
Adds a list of policy domain names.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_ip_address
def add_ip_address(list_name, item_name): ''' Add an IP address to an IP address list. list_name(str): The name of the specific policy IP address list to append to. item_name(str): The IP address to append to the list. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_...
python
def add_ip_address(list_name, item_name): ''' Add an IP address to an IP address list. list_name(str): The name of the specific policy IP address list to append to. item_name(str): The IP address to append to the list. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_...
[ "def", "add_ip_address", "(", "list_name", ",", "item_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_ip_addresses\"", ",", "\"params\"", ":", "[", "list_name", ",", "{",...
Add an IP address to an IP address list. list_name(str): The name of the specific policy IP address list to append to. item_name(str): The IP address to append to the list. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_address MyIPAddressList 10.0.0.0/24
[ "Add", "an", "IP", "address", "to", "an", "IP", "address", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L172-L194
train
Adds an IP address to an IP address list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
add_ip_address_list
def add_ip_address_list(list_name): ''' Retrieves a list of all IP address lists. list_name(str): The name of the specific IP address list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_address_list MyIPAddressList ''' payload = {"jsonrpc": "2.0", ...
python
def add_ip_address_list(list_name): ''' Retrieves a list of all IP address lists. list_name(str): The name of the specific IP address list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_address_list MyIPAddressList ''' payload = {"jsonrpc": "2.0", ...
[ "def", "add_ip_address_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"add_policy_ip_addresses_list\"", ",", "\"params\"", ":", "[", "{", "\"list_name\"", ":", "list...
Retrieves a list of all IP address lists. list_name(str): The name of the specific IP address list to add. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.add_ip_address_list MyIPAddressList
[ "Retrieves", "a", "list", "of", "all", "IP", "address", "lists", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L197-L217
train
Adds a specific IP address list to the current list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
get_distinguished_name_list
def get_distinguished_name_list(list_name): ''' Retrieves a specific policy distinguished name list. list_name(str): The name of the specific policy distinguished name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_distinguished_name_list MyDistinguishedLi...
python
def get_distinguished_name_list(list_name): ''' Retrieves a specific policy distinguished name list. list_name(str): The name of the specific policy distinguished name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_distinguished_name_list MyDistinguishedLi...
[ "def", "get_distinguished_name_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"get_policy_distinguished_names\"", ",", "\"params\"", ":", "[", "list_name", ",", "0", ...
Retrieves a specific policy distinguished name list. list_name(str): The name of the specific policy distinguished name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_distinguished_name_list MyDistinguishedList
[ "Retrieves", "a", "specific", "policy", "distinguished", "name", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L220-L240
train
Retrieves a specific policy distinguished name list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
get_domain_list
def get_domain_list(list_name): ''' Retrieves a specific policy domain name list. list_name(str): The name of the specific policy domain name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_domain_list MyDomainNameList ''' payload = {"jsonrpc": "2....
python
def get_domain_list(list_name): ''' Retrieves a specific policy domain name list. list_name(str): The name of the specific policy domain name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_domain_list MyDomainNameList ''' payload = {"jsonrpc": "2....
[ "def", "get_domain_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"get_policy_domain_names\"", ",", "\"params\"", ":", "[", "list_name", ",", "0", ",", "256", "]...
Retrieves a specific policy domain name list. list_name(str): The name of the specific policy domain name list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_domain_list MyDomainNameList
[ "Retrieves", "a", "specific", "policy", "domain", "name", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L264-L284
train
Retrieves a specific policy domain name list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/bluecoat_sslv.py
get_ip_address_list
def get_ip_address_list(list_name): ''' Retrieves a specific IP address list. list_name(str): The name of the specific policy IP address list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_ip_address_list MyIPAddressList ''' payload = {"jsonrpc": "2.0"...
python
def get_ip_address_list(list_name): ''' Retrieves a specific IP address list. list_name(str): The name of the specific policy IP address list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_ip_address_list MyIPAddressList ''' payload = {"jsonrpc": "2.0"...
[ "def", "get_ip_address_list", "(", "list_name", ")", ":", "payload", "=", "{", "\"jsonrpc\"", ":", "\"2.0\"", ",", "\"id\"", ":", "\"ID0\"", ",", "\"method\"", ":", "\"get_policy_ip_addresses\"", ",", "\"params\"", ":", "[", "list_name", ",", "0", ",", "256", ...
Retrieves a specific IP address list. list_name(str): The name of the specific policy IP address list to retrieve. CLI Example: .. code-block:: bash salt '*' bluecoat_sslv.get_ip_address_list MyIPAddressList
[ "Retrieves", "a", "specific", "IP", "address", "list", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/bluecoat_sslv.py#L308-L328
train
Retrieves a specific IP address list.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/utils/win_runas.py
runas
def runas(cmdLine, username, password=None, cwd=None): ''' Run a command as another user. If the process is running as an admin or system account this method does not require a password. Other non privileged accounts need to provide a password for the user to runas. Commands are run in with the high...
python
def runas(cmdLine, username, password=None, cwd=None): ''' Run a command as another user. If the process is running as an admin or system account this method does not require a password. Other non privileged accounts need to provide a password for the user to runas. Commands are run in with the high...
[ "def", "runas", "(", "cmdLine", ",", "username", ",", "password", "=", "None", ",", "cwd", "=", "None", ")", ":", "# Elevate the token from the current process", "access", "=", "(", "win32security", ".", "TOKEN_QUERY", "|", "win32security", ".", "TOKEN_ADJUST_PRIV...
Run a command as another user. If the process is running as an admin or system account this method does not require a password. Other non privileged accounts need to provide a password for the user to runas. Commands are run in with the highest level privileges possible for the account provided.
[ "Run", "a", "command", "as", "another", "user", ".", "If", "the", "process", "is", "running", "as", "an", "admin", "or", "system", "account", "this", "method", "does", "not", "require", "a", "password", ".", "Other", "non", "privileged", "accounts", "need"...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/utils/win_runas.py#L62-L224
train
Run a command as another user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/utils/win_runas.py
runas_unpriv
def runas_unpriv(cmd, username, password, cwd=None): ''' Runas that works for non-priviledged users ''' # Create a pipe to set as stdout in the child. The write handle needs to be # inheritable. c2pread, c2pwrite = salt.platform.win.CreatePipe( inherit_read=False, inherit_write=True, ...
python
def runas_unpriv(cmd, username, password, cwd=None): ''' Runas that works for non-priviledged users ''' # Create a pipe to set as stdout in the child. The write handle needs to be # inheritable. c2pread, c2pwrite = salt.platform.win.CreatePipe( inherit_read=False, inherit_write=True, ...
[ "def", "runas_unpriv", "(", "cmd", ",", "username", ",", "password", ",", "cwd", "=", "None", ")", ":", "# Create a pipe to set as stdout in the child. The write handle needs to be", "# inheritable.", "c2pread", ",", "c2pwrite", "=", "salt", ".", "platform", ".", "win...
Runas that works for non-priviledged users
[ "Runas", "that", "works", "for", "non", "-", "priviledged", "users" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/utils/win_runas.py#L227-L295
train
Runs a command on the specified user and returns a dictionary of the process info.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/matchers/data_match.py
match
def match(tgt, functions=None, opts=None): ''' Match based on the local data store on the minion ''' if not opts: opts = __opts__ if functions is None: utils = salt.loader.utils(opts) functions = salt.loader.minion_mods(opts, utils=utils) comps = tgt.split(':') if len...
python
def match(tgt, functions=None, opts=None): ''' Match based on the local data store on the minion ''' if not opts: opts = __opts__ if functions is None: utils = salt.loader.utils(opts) functions = salt.loader.minion_mods(opts, utils=utils) comps = tgt.split(':') if len...
[ "def", "match", "(", "tgt", ",", "functions", "=", "None", ",", "opts", "=", "None", ")", ":", "if", "not", "opts", ":", "opts", "=", "__opts__", "if", "functions", "is", "None", ":", "utils", "=", "salt", ".", "loader", ".", "utils", "(", "opts", ...
Match based on the local data store on the minion
[ "Match", "based", "on", "the", "local", "data", "store", "on", "the", "minion" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/matchers/data_match.py#L19-L48
train
Match based on the local data store on the minion
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/glance.py
_find_image
def _find_image(name): ''' Tries to find image with given name, returns - image, 'Found image <name>' - None, 'No such image found' - False, 'Found more than one image with given name' ''' try: images = __salt__['glance.image_list'](name=name) except kstone_Unauthoriz...
python
def _find_image(name): ''' Tries to find image with given name, returns - image, 'Found image <name>' - None, 'No such image found' - False, 'Found more than one image with given name' ''' try: images = __salt__['glance.image_list'](name=name) except kstone_Unauthoriz...
[ "def", "_find_image", "(", "name", ")", ":", "try", ":", "images", "=", "__salt__", "[", "'glance.image_list'", "]", "(", "name", "=", "name", ")", "except", "kstone_Unauthorized", ":", "return", "False", ",", "'keystoneclient: Unauthorized'", "except", "glance_...
Tries to find image with given name, returns - image, 'Found image <name>' - None, 'No such image found' - False, 'Found more than one image with given name'
[ "Tries", "to", "find", "image", "with", "given", "name", "returns", "-", "image", "Found", "image", "<name", ">", "-", "None", "No", "such", "image", "found", "-", "False", "Found", "more", "than", "one", "image", "with", "given", "name" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/glance.py#L43-L70
train
Tries to find image with given name returns - image None - no such image found returns - glanceclient - Unauthorized
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/glance.py
image_present
def image_present(name, visibility='public', protected=None, checksum=None, location=None, disk_format='raw', wait_for=None, timeout=30): ''' Checks if given image is present with properties set as specified. An image should got through the stages 'queued', 'saving' before becoming ...
python
def image_present(name, visibility='public', protected=None, checksum=None, location=None, disk_format='raw', wait_for=None, timeout=30): ''' Checks if given image is present with properties set as specified. An image should got through the stages 'queued', 'saving' before becoming ...
[ "def", "image_present", "(", "name", ",", "visibility", "=", "'public'", ",", "protected", "=", "None", ",", "checksum", "=", "None", ",", "location", "=", "None", ",", "disk_format", "=", "'raw'", ",", "wait_for", "=", "None", ",", "timeout", "=", "30",...
Checks if given image is present with properties set as specified. An image should got through the stages 'queued', 'saving' before becoming 'active'. The attribute 'checksum' can only be checked once the image is active. If you don't specify 'wait_for' but 'checksum' the function will wait for...
[ "Checks", "if", "given", "image", "is", "present", "with", "properties", "set", "as", "specified", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/glance.py#L73-L250
train
Ensures that the given image is present with the given properties.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
returner
def returner(ret): ''' Return data to one of potentially many clustered cassandra nodes ''' query = '''INSERT INTO {keyspace}.salt_returns ( jid, minion_id, fun, alter_time, full_ret, return, success ) VALUES (?, ?, ?, ?, ?, ?, ?)'''.format(keyspace=_get_keyspace()) ...
python
def returner(ret): ''' Return data to one of potentially many clustered cassandra nodes ''' query = '''INSERT INTO {keyspace}.salt_returns ( jid, minion_id, fun, alter_time, full_ret, return, success ) VALUES (?, ?, ?, ?, ?, ?, ?)'''.format(keyspace=_get_keyspace()) ...
[ "def", "returner", "(", "ret", ")", ":", "query", "=", "'''INSERT INTO {keyspace}.salt_returns (\n jid, minion_id, fun, alter_time, full_ret, return, success\n ) VALUES (?, ?, ?, ?, ?, ?, ?)'''", ".", "format", "(", "keyspace", "=", "_get_keyspace", "(", ...
Return data to one of potentially many clustered cassandra nodes
[ "Return", "data", "to", "one", "of", "potentially", "many", "clustered", "cassandra", "nodes" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L192-L243
train
Return data to one of potentially many clustered cassandra nodes
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
event_return
def event_return(events): ''' Return event to one of potentially many clustered cassandra nodes Requires that configuration be enabled via 'event_return' option in master config. Cassandra does not support an auto-increment feature due to the highly inefficient nature of creating a monotonical...
python
def event_return(events): ''' Return event to one of potentially many clustered cassandra nodes Requires that configuration be enabled via 'event_return' option in master config. Cassandra does not support an auto-increment feature due to the highly inefficient nature of creating a monotonical...
[ "def", "event_return", "(", "events", ")", ":", "for", "event", "in", "events", ":", "tag", "=", "event", ".", "get", "(", "'tag'", ",", "''", ")", "data", "=", "event", ".", "get", "(", "'data'", ",", "''", ")", "query", "=", "'''INSERT INTO {keyspa...
Return event to one of potentially many clustered cassandra nodes Requires that configuration be enabled via 'event_return' option in master config. Cassandra does not support an auto-increment feature due to the highly inefficient nature of creating a monotonically increasing number across all no...
[ "Return", "event", "to", "one", "of", "potentially", "many", "clustered", "cassandra", "nodes" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L246-L283
train
Return events to one of potentially many clustered cassandra nodes
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
save_load
def save_load(jid, load, minions=None): ''' Save the load to the specified jid id ''' # Load is being stored as a text datatype. Single quotes are used in the # VALUES list. Therefore, all single quotes contained in the results from # salt.utils.json.dumps(load) must be escaped Cassandra style. ...
python
def save_load(jid, load, minions=None): ''' Save the load to the specified jid id ''' # Load is being stored as a text datatype. Single quotes are used in the # VALUES list. Therefore, all single quotes contained in the results from # salt.utils.json.dumps(load) must be escaped Cassandra style. ...
[ "def", "save_load", "(", "jid", ",", "load", ",", "minions", "=", "None", ")", ":", "# Load is being stored as a text datatype. Single quotes are used in the", "# VALUES list. Therefore, all single quotes contained in the results from", "# salt.utils.json.dumps(load) must be escaped Cass...
Save the load to the specified jid id
[ "Save", "the", "load", "to", "the", "specified", "jid", "id" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L286-L312
train
Save the load to the specified jid id
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
get_jid
def get_jid(jid): ''' Return the information returned when the specified job id was executed ''' query = '''SELECT minion_id, full_ret FROM {keyspace}.salt_returns WHERE jid = ?;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionE...
python
def get_jid(jid): ''' Return the information returned when the specified job id was executed ''' query = '''SELECT minion_id, full_ret FROM {keyspace}.salt_returns WHERE jid = ?;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionE...
[ "def", "get_jid", "(", "jid", ")", ":", "query", "=", "'''SELECT minion_id, full_ret FROM {keyspace}.salt_returns\n WHERE jid = ?;'''", ".", "format", "(", "keyspace", "=", "_get_keyspace", "(", ")", ")", "ret", "=", "{", "}", "# cassandra_cql.cql_query may ...
Return the information returned when the specified job id was executed
[ "Return", "the", "information", "returned", "when", "the", "specified", "job", "id", "was", "executed" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L350-L376
train
Return the information returned when the specified job id was executed
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
get_fun
def get_fun(fun): ''' Return a dict of the last function called for all minions ''' query = '''SELECT minion_id, last_fun FROM {keyspace}.minions WHERE last_fun = ?;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionError try:...
python
def get_fun(fun): ''' Return a dict of the last function called for all minions ''' query = '''SELECT minion_id, last_fun FROM {keyspace}.minions WHERE last_fun = ?;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionError try:...
[ "def", "get_fun", "(", "fun", ")", ":", "query", "=", "'''SELECT minion_id, last_fun FROM {keyspace}.minions\n WHERE last_fun = ?;'''", ".", "format", "(", "keyspace", "=", "_get_keyspace", "(", ")", ")", "ret", "=", "{", "}", "# cassandra_cql.cql_query may ...
Return a dict of the last function called for all minions
[ "Return", "a", "dict", "of", "the", "last", "function", "called", "for", "all", "minions" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L380-L406
train
Return a dict of the last function called for all minions
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
get_jids
def get_jids(): ''' Return a list of all job ids ''' query = '''SELECT jid, load FROM {keyspace}.jids;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionError try: data = __salt__['cassandra_cql.cql_query'](query) if data: ...
python
def get_jids(): ''' Return a list of all job ids ''' query = '''SELECT jid, load FROM {keyspace}.jids;'''.format(keyspace=_get_keyspace()) ret = {} # cassandra_cql.cql_query may raise a CommandExecutionError try: data = __salt__['cassandra_cql.cql_query'](query) if data: ...
[ "def", "get_jids", "(", ")", ":", "query", "=", "'''SELECT jid, load FROM {keyspace}.jids;'''", ".", "format", "(", "keyspace", "=", "_get_keyspace", "(", ")", ")", "ret", "=", "{", "}", "# cassandra_cql.cql_query may raise a CommandExecutionError", "try", ":", "data"...
Return a list of all job ids
[ "Return", "a", "list", "of", "all", "job", "ids" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L410-L437
train
Return a list of all job ids
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/returners/cassandra_cql_return.py
get_minions
def get_minions(): ''' Return a list of minions ''' query = '''SELECT DISTINCT minion_id FROM {keyspace}.minions;'''.format(keyspace=_get_keyspace()) ret = [] # cassandra_cql.cql_query may raise a CommandExecutionError try: data = __salt__['cassandra_cql.cql_query'](...
python
def get_minions(): ''' Return a list of minions ''' query = '''SELECT DISTINCT minion_id FROM {keyspace}.minions;'''.format(keyspace=_get_keyspace()) ret = [] # cassandra_cql.cql_query may raise a CommandExecutionError try: data = __salt__['cassandra_cql.cql_query'](...
[ "def", "get_minions", "(", ")", ":", "query", "=", "'''SELECT DISTINCT minion_id\n FROM {keyspace}.minions;'''", ".", "format", "(", "keyspace", "=", "_get_keyspace", "(", ")", ")", "ret", "=", "[", "]", "# cassandra_cql.cql_query may raise a CommandExecutionE...
Return a list of minions
[ "Return", "a", "list", "of", "minions" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/returners/cassandra_cql_return.py#L441-L466
train
Return a list of minions in the keyspace
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/output/json_out.py
output
def output(data, **kwargs): # pylint: disable=unused-argument ''' Print the output data in JSON ''' try: if 'output_indent' not in __opts__: return salt.utils.json.dumps(data, default=repr, indent=4) indent = __opts__.get('output_indent') sort_keys = False ...
python
def output(data, **kwargs): # pylint: disable=unused-argument ''' Print the output data in JSON ''' try: if 'output_indent' not in __opts__: return salt.utils.json.dumps(data, default=repr, indent=4) indent = __opts__.get('output_indent') sort_keys = False ...
[ "def", "output", "(", "data", ",", "*", "*", "kwargs", ")", ":", "# pylint: disable=unused-argument", "try", ":", "if", "'output_indent'", "not", "in", "__opts__", ":", "return", "salt", ".", "utils", ".", "json", ".", "dumps", "(", "data", ",", "default",...
Print the output data in JSON
[ "Print", "the", "output", "data", "in", "JSON" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/output/json_out.py#L56-L92
train
Print the output data in JSON
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/mssql_role.py
present
def present(name, owner=None, grants=None, **kwargs): ''' Ensure that the named database is present with the specified options name The name of the database to manage owner Adds owner using AUTHORIZATION option Grants Can only be a list of strings ''' ret = {'name': ...
python
def present(name, owner=None, grants=None, **kwargs): ''' Ensure that the named database is present with the specified options name The name of the database to manage owner Adds owner using AUTHORIZATION option Grants Can only be a list of strings ''' ret = {'name': ...
[ "def", "present", "(", "name", ",", "owner", "=", "None", ",", "grants", "=", "None", ",", "*", "*", "kwargs", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "True", ",", "'comment'", ":",...
Ensure that the named database is present with the specified options name The name of the database to manage owner Adds owner using AUTHORIZATION option Grants Can only be a list of strings
[ "Ensure", "that", "the", "named", "database", "is", "present", "with", "the", "specified", "options" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/mssql_role.py#L24-L55
train
Ensure that the named database is present with the specified options
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/servicenow.py
set_change_request_state
def set_change_request_state(change_id, state='approved'): ''' Set the approval state of a change request/record :param change_id: The ID of the change request, e.g. CHG123545 :type change_id: ``str`` :param state: The target state, e.g. approved :type state: ``str`` CLI Example: ....
python
def set_change_request_state(change_id, state='approved'): ''' Set the approval state of a change request/record :param change_id: The ID of the change request, e.g. CHG123545 :type change_id: ``str`` :param state: The target state, e.g. approved :type state: ``str`` CLI Example: ....
[ "def", "set_change_request_state", "(", "change_id", ",", "state", "=", "'approved'", ")", ":", "client", "=", "_get_client", "(", ")", "client", ".", "table", "=", "'change_request'", "# Get the change record first", "record", "=", "client", ".", "get", "(", "{...
Set the approval state of a change request/record :param change_id: The ID of the change request, e.g. CHG123545 :type change_id: ``str`` :param state: The target state, e.g. approved :type state: ``str`` CLI Example: .. code-block:: bash salt myminion servicenow.set_change_reques...
[ "Set", "the", "approval", "state", "of", "a", "change", "request", "/", "record" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/servicenow.py#L61-L88
train
Set the approval state of a change request
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/servicenow.py
delete_record
def delete_record(table, sys_id): ''' Delete an existing record :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` CLI Example: .. code-block:: bash salt myminion servicenow.delete_record sys_co...
python
def delete_record(table, sys_id): ''' Delete an existing record :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` CLI Example: .. code-block:: bash salt myminion servicenow.delete_record sys_co...
[ "def", "delete_record", "(", "table", ",", "sys_id", ")", ":", "client", "=", "_get_client", "(", ")", "client", ".", "table", "=", "table", "response", "=", "client", ".", "delete", "(", "sys_id", ")", "return", "response" ]
Delete an existing record :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` CLI Example: .. code-block:: bash salt myminion servicenow.delete_record sys_computer 2134566
[ "Delete", "an", "existing", "record" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/servicenow.py#L91-L110
train
Delete an existing record in a table
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/servicenow.py
non_structured_query
def non_structured_query(table, query=None, **kwargs): ''' Run a non-structed (not a dict) query on a servicenow table. See http://wiki.servicenow.com/index.php?title=Encoded_Query_Strings#gsc.tab=0 for help on constructing a non-structured query string. :param table: The table name, e.g. sys_user ...
python
def non_structured_query(table, query=None, **kwargs): ''' Run a non-structed (not a dict) query on a servicenow table. See http://wiki.servicenow.com/index.php?title=Encoded_Query_Strings#gsc.tab=0 for help on constructing a non-structured query string. :param table: The table name, e.g. sys_user ...
[ "def", "non_structured_query", "(", "table", ",", "query", "=", "None", ",", "*", "*", "kwargs", ")", ":", "client", "=", "_get_client", "(", ")", "client", ".", "table", "=", "table", "# underlying lib doesn't use six or past.basestring,", "# does isinstance(x, str...
Run a non-structed (not a dict) query on a servicenow table. See http://wiki.servicenow.com/index.php?title=Encoded_Query_Strings#gsc.tab=0 for help on constructing a non-structured query string. :param table: The table name, e.g. sys_user :type table: ``str`` :param query: The query to run (or u...
[ "Run", "a", "non", "-", "structed", "(", "not", "a", "dict", ")", "query", "on", "a", "servicenow", "table", ".", "See", "http", ":", "//", "wiki", ".", "servicenow", ".", "com", "/", "index", ".", "php?title", "=", "Encoded_Query_Strings#gsc", ".", "t...
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/servicenow.py#L113-L145
train
Run a non - structured query on a servicenow table.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/servicenow.py
update_record_field
def update_record_field(table, sys_id, field, value): ''' Update the value of a record's field in a servicenow table :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` :param field: The new value :type f...
python
def update_record_field(table, sys_id, field, value): ''' Update the value of a record's field in a servicenow table :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` :param field: The new value :type f...
[ "def", "update_record_field", "(", "table", ",", "sys_id", ",", "field", ",", "value", ")", ":", "client", "=", "_get_client", "(", ")", "client", ".", "table", "=", "table", "response", "=", "client", ".", "update", "(", "{", "field", ":", "value", "}...
Update the value of a record's field in a servicenow table :param table: The table name, e.g. sys_user :type table: ``str`` :param sys_id: The unique ID of the record :type sys_id: ``str`` :param field: The new value :type field: ``str`` :param value: The new value :type value: `...
[ "Update", "the", "value", "of", "a", "record", "s", "field", "in", "a", "servicenow", "table" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/servicenow.py#L148-L173
train
Update the value of a record s field in a servicenow table
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/cabal.py
_parse_pkg_string
def _parse_pkg_string(pkg): ''' Parse pkg string and return a tuple of package name, separator, and package version. Cabal support install package with following format: * foo-1.0 * foo < 1.2 * foo > 1.3 For the sake of simplicity only the first form is supported, support for othe...
python
def _parse_pkg_string(pkg): ''' Parse pkg string and return a tuple of package name, separator, and package version. Cabal support install package with following format: * foo-1.0 * foo < 1.2 * foo > 1.3 For the sake of simplicity only the first form is supported, support for othe...
[ "def", "_parse_pkg_string", "(", "pkg", ")", ":", "pkg_name", ",", "separator", ",", "pkg_ver", "=", "pkg", ".", "partition", "(", "'-'", ")", "return", "(", "pkg_name", ".", "strip", "(", ")", ",", "separator", ",", "pkg_ver", ".", "strip", "(", ")", ...
Parse pkg string and return a tuple of package name, separator, and package version. Cabal support install package with following format: * foo-1.0 * foo < 1.2 * foo > 1.3 For the sake of simplicity only the first form is supported, support for other forms can be added later.
[ "Parse", "pkg", "string", "and", "return", "a", "tuple", "of", "package", "name", "separator", "and", "package", "version", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/cabal.py#L40-L55
train
Parse pkg string and return a tuple of package name separator and and package version.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/cabal.py
installed
def installed(name, pkgs=None, user=None, install_global=False, env=None): ''' Verify that the given package is installed and is at the correct version (if specified). .. code-block:: yaml ShellCheck-0.3.5: cabal: - ...
python
def installed(name, pkgs=None, user=None, install_global=False, env=None): ''' Verify that the given package is installed and is at the correct version (if specified). .. code-block:: yaml ShellCheck-0.3.5: cabal: - ...
[ "def", "installed", "(", "name", ",", "pkgs", "=", "None", ",", "user", "=", "None", ",", "install_global", "=", "False", ",", "env", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "None", ",", "'comment'", ":"...
Verify that the given package is installed and is at the correct version (if specified). .. code-block:: yaml ShellCheck-0.3.5: cabal: - installed: name The package to install user The user to run cabal install with install_global Install pack...
[ "Verify", "that", "the", "given", "package", "is", "installed", "and", "is", "at", "the", "correct", "version", "(", "if", "specified", ")", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/cabal.py#L58-L169
train
Verify that the given package is installed at the correct version.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/cabal.py
removed
def removed(name, user=None, env=None): ''' Verify that given package is not installed. ''' ret = {'name': name, 'result': None, 'comment': '', 'changes': {}} try: installed_pkgs = __salt__['cabal.list']( user=user, installed=True, env=env) except (C...
python
def removed(name, user=None, env=None): ''' Verify that given package is not installed. ''' ret = {'name': name, 'result': None, 'comment': '', 'changes': {}} try: installed_pkgs = __salt__['cabal.list']( user=user, installed=True, env=env) except (C...
[ "def", "removed", "(", "name", ",", "user", "=", "None", ",", "env", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "try", ":", "in...
Verify that given package is not installed.
[ "Verify", "that", "given", "package", "is", "not", "installed", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/cabal.py#L172-L206
train
Verify that given package is not installed.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/beacons/service.py
beacon
def beacon(config): ''' Scan for the configured services and fire events Example Config .. code-block:: yaml beacons: service: - services: salt-master: {} mysql: {} The config above sets up beacons to check for the salt-master and...
python
def beacon(config): ''' Scan for the configured services and fire events Example Config .. code-block:: yaml beacons: service: - services: salt-master: {} mysql: {} The config above sets up beacons to check for the salt-master and...
[ "def", "beacon", "(", "config", ")", ":", "ret", "=", "[", "]", "_config", "=", "{", "}", "list", "(", "map", "(", "_config", ".", "update", ",", "config", ")", ")", "for", "service", "in", "_config", ".", "get", "(", "'services'", ",", "{", "}",...
Scan for the configured services and fire events Example Config .. code-block:: yaml beacons: service: - services: salt-master: {} mysql: {} The config above sets up beacons to check for the salt-master and mysql services. The config...
[ "Scan", "for", "the", "configured", "services", "and", "fire", "events" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/beacons/service.py#L44-L164
train
Scan for the configured services and fire events at each beacon interval.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/jira_mod.py
_get_credentials
def _get_credentials(server=None, username=None, password=None): ''' Returns the credentials merged with the config data (opts + pillar). ''' jira_cfg = __salt__['config.merge']('jira', default={}) if not server: server = jira_cfg.get('server') i...
python
def _get_credentials(server=None, username=None, password=None): ''' Returns the credentials merged with the config data (opts + pillar). ''' jira_cfg = __salt__['config.merge']('jira', default={}) if not server: server = jira_cfg.get('server') i...
[ "def", "_get_credentials", "(", "server", "=", "None", ",", "username", "=", "None", ",", "password", "=", "None", ")", ":", "jira_cfg", "=", "__salt__", "[", "'config.merge'", "]", "(", "'jira'", ",", "default", "=", "{", "}", ")", "if", "not", "serve...
Returns the credentials merged with the config data (opts + pillar).
[ "Returns", "the", "credentials", "merged", "with", "the", "config", "data", "(", "opts", "+", "pillar", ")", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/jira_mod.py#L50-L63
train
Returns the server username and password for the JIRA server
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/jira_mod.py
create_issue
def create_issue(project, summary, description, template_engine='jinja', context=None, defaults=None, saltenv='base', issuetype='Bug', priority='Normal', labels=None, ...
python
def create_issue(project, summary, description, template_engine='jinja', context=None, defaults=None, saltenv='base', issuetype='Bug', priority='Normal', labels=None, ...
[ "def", "create_issue", "(", "project", ",", "summary", ",", "description", ",", "template_engine", "=", "'jinja'", ",", "context", "=", "None", ",", "defaults", "=", "None", ",", "saltenv", "=", "'base'", ",", "issuetype", "=", "'Bug'", ",", "priority", "=...
Create a JIRA issue using the named settings. Return the JIRA ticket ID. project The name of the project to attach the JIRA ticket to. summary The summary (title) of the JIRA ticket. When the ``template_engine`` argument is set to a proper value of an existing Salt template engine ...
[ "Create", "a", "JIRA", "issue", "using", "the", "named", "settings", ".", "Return", "the", "JIRA", "ticket", "ID", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/jira_mod.py#L80-L183
train
Create a JIRA issue using the named settings.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/jira_mod.py
assign_issue
def assign_issue(issue_key, assignee, server=None, username=None, password=None): ''' Assign the issue to an existing user. Return ``True`` when the issue has been properly assigned. issue_key The JIRA ID of the ticket to manip...
python
def assign_issue(issue_key, assignee, server=None, username=None, password=None): ''' Assign the issue to an existing user. Return ``True`` when the issue has been properly assigned. issue_key The JIRA ID of the ticket to manip...
[ "def", "assign_issue", "(", "issue_key", ",", "assignee", ",", "server", "=", "None", ",", "username", "=", "None", ",", "password", "=", "None", ")", ":", "jira_", "=", "_get_jira", "(", "server", "=", "server", ",", "username", "=", "username", ",", ...
Assign the issue to an existing user. Return ``True`` when the issue has been properly assigned. issue_key The JIRA ID of the ticket to manipulate. assignee The name of the user to assign the ticket to. CLI Example: salt '*' jira.assign_issue NET-123 example_user
[ "Assign", "the", "issue", "to", "an", "existing", "user", ".", "Return", "True", "when", "the", "issue", "has", "been", "properly", "assigned", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/jira_mod.py#L186-L209
train
Assign the issue to an existing user. Return True when the issue has been properly assigned to an existing user. Return False when the issue has been successfully assigned to an existing user.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/jira_mod.py
add_comment
def add_comment(issue_key, comment, visibility=None, is_internal=False, server=None, username=None, password=None): ''' Add a comment to an existing ticket. Return ``True`` when it successfully added the comment....
python
def add_comment(issue_key, comment, visibility=None, is_internal=False, server=None, username=None, password=None): ''' Add a comment to an existing ticket. Return ``True`` when it successfully added the comment....
[ "def", "add_comment", "(", "issue_key", ",", "comment", ",", "visibility", "=", "None", ",", "is_internal", "=", "False", ",", "server", "=", "None", ",", "username", "=", "None", ",", "password", "=", "None", ")", ":", "jira_", "=", "_get_jira", "(", ...
Add a comment to an existing ticket. Return ``True`` when it successfully added the comment. issue_key The issue ID to add the comment to. comment The body of the comment to be added. visibility: ``None`` A dictionary having two keys: - ``type``: is ``role`` (or ``gro...
[ "Add", "a", "comment", "to", "an", "existing", "ticket", ".", "Return", "True", "when", "it", "successfully", "added", "the", "comment", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/jira_mod.py#L212-L253
train
Adds a comment to an existing ticket.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/modules/jira_mod.py
issue_closed
def issue_closed(issue_key, server=None, username=None, password=None): ''' Check if the issue is closed. issue_key The JIRA iD of the ticket to close. Returns: - ``True``: the ticket exists and it is closed. - ``False``: the ticket e...
python
def issue_closed(issue_key, server=None, username=None, password=None): ''' Check if the issue is closed. issue_key The JIRA iD of the ticket to close. Returns: - ``True``: the ticket exists and it is closed. - ``False``: the ticket e...
[ "def", "issue_closed", "(", "issue_key", ",", "server", "=", "None", ",", "username", "=", "None", ",", "password", "=", "None", ")", ":", "if", "not", "issue_key", ":", "return", "None", "jira_", "=", "_get_jira", "(", "server", "=", "server", ",", "u...
Check if the issue is closed. issue_key The JIRA iD of the ticket to close. Returns: - ``True``: the ticket exists and it is closed. - ``False``: the ticket exists and it has not been closed. - ``None``: the ticket does not exist. CLI Example: .. code-block:: bash salt ...
[ "Check", "if", "the", "issue", "is", "closed", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/jira_mod.py#L256-L288
train
Check if the issue is closed.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/grains/junos.py
_remove_complex_types
def _remove_complex_types(dictionary): ''' Linode-python is now returning some complex types that are not serializable by msgpack. Kill those. ''' for k, v in six.iteritems(dictionary): if isinstance(v, dict): dictionary[k] = _remove_complex_types(v) elif hasattr(v, 'to_...
python
def _remove_complex_types(dictionary): ''' Linode-python is now returning some complex types that are not serializable by msgpack. Kill those. ''' for k, v in six.iteritems(dictionary): if isinstance(v, dict): dictionary[k] = _remove_complex_types(v) elif hasattr(v, 'to_...
[ "def", "_remove_complex_types", "(", "dictionary", ")", ":", "for", "k", ",", "v", "in", "six", ".", "iteritems", "(", "dictionary", ")", ":", "if", "isinstance", "(", "v", ",", "dict", ")", ":", "dictionary", "[", "k", "]", "=", "_remove_complex_types",...
Linode-python is now returning some complex types that are not serializable by msgpack. Kill those.
[ "Linode", "-", "python", "is", "now", "returning", "some", "complex", "types", "that", "are", "not", "serializable", "by", "msgpack", ".", "Kill", "those", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/grains/junos.py#L30-L41
train
Remove complex types from Linode - python dictionary.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
saltstack/salt
salt/states/module.py
run
def run(**kwargs): ''' Run a single module function or a range of module functions in a batch. Supersedes ``module.run`` function, which requires ``m_`` prefix to function-specific parameters. :param returner: Specify a common returner for the whole batch to send the return data :param...
python
def run(**kwargs): ''' Run a single module function or a range of module functions in a batch. Supersedes ``module.run`` function, which requires ``m_`` prefix to function-specific parameters. :param returner: Specify a common returner for the whole batch to send the return data :param...
[ "def", "run", "(", "*", "*", "kwargs", ")", ":", "if", "'name'", "in", "kwargs", ":", "kwargs", ".", "pop", "(", "'name'", ")", "ret", "=", "{", "'name'", ":", "list", "(", "kwargs", ")", ",", "'changes'", ":", "{", "}", ",", "'comment'", ":", ...
Run a single module function or a range of module functions in a batch. Supersedes ``module.run`` function, which requires ``m_`` prefix to function-specific parameters. :param returner: Specify a common returner for the whole batch to send the return data :param kwargs: Pass any argum...
[ "Run", "a", "single", "module", "function", "or", "a", "range", "of", "module", "functions", "in", "a", "batch", ".", "Supersedes", "module", ".", "run", "function", "which", "requires", "m_", "prefix", "to", "function", "-", "specific", "parameters", "." ]
e8541fd6e744ab0df786c0f76102e41631f45d46
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/module.py#L350-L436
train
Execute a single module function or a range of module functions in a batch.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...