partition
stringclasses
3 values
func_name
stringlengths
1
134
docstring
stringlengths
1
46.9k
path
stringlengths
4
223
original_string
stringlengths
75
104k
code
stringlengths
75
104k
docstring_tokens
listlengths
1
1.97k
repo
stringlengths
7
55
language
stringclasses
1 value
url
stringlengths
87
315
code_tokens
listlengths
19
28.4k
sha
stringlengths
40
40
train
document_exists
Return a boolean indicating whether given document exists index Index name where the document resides id Document identifier doc_type Type of the document, use _all to fetch the first document matching the ID across all types CLI example:: salt myminion elasticsearch.d...
salt/modules/elasticsearch.py
def document_exists(index, id, doc_type='_all', hosts=None, profile=None): ''' Return a boolean indicating whether given document exists index Index name where the document resides id Document identifier doc_type Type of the document, use _all to fetch the first document mat...
def document_exists(index, id, doc_type='_all', hosts=None, profile=None): ''' Return a boolean indicating whether given document exists index Index name where the document resides id Document identifier doc_type Type of the document, use _all to fetch the first document mat...
[ "Return", "a", "boolean", "indicating", "whether", "given", "document", "exists" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L433-L455
[ "def", "document_exists", "(", "index", ",", "id", ",", "doc_type", "=", "'_all'", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "exis...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_create
Create an index index Index name body Index definition, such as settings and mappings as defined in https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html source URL to file specifying index definition. Cannot be used in combination with ``body``. ...
salt/modules/elasticsearch.py
def index_create(index, body=None, hosts=None, profile=None, source=None): ''' Create an index index Index name body Index definition, such as settings and mappings as defined in https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html source ...
def index_create(index, body=None, hosts=None, profile=None, source=None): ''' Create an index index Index name body Index definition, such as settings and mappings as defined in https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html source ...
[ "Create", "an", "index" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L483-L514
[ "def", "index_create", "(", "index", ",", "body", "=", "None", ",", "hosts", "=", "None", ",", "profile", "=", "None", ",", "source", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "if", "source", "and", "body",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_delete
Delete an index index Index name CLI example:: salt myminion elasticsearch.index_delete testindex
salt/modules/elasticsearch.py
def index_delete(index, hosts=None, profile=None): ''' Delete an index index Index name CLI example:: salt myminion elasticsearch.index_delete testindex ''' es = _get_instance(hosts, profile) try: result = es.indices.delete(index=index) return result.get(...
def index_delete(index, hosts=None, profile=None): ''' Delete an index index Index name CLI example:: salt myminion elasticsearch.index_delete testindex ''' es = _get_instance(hosts, profile) try: result = es.indices.delete(index=index) return result.get(...
[ "Delete", "an", "index" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L517-L537
[ "def", "index_delete", "(", "index", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "indices", ".", "delete", "(", "index", "=", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_exists
Return a boolean indicating whether given index exists index Index name CLI example:: salt myminion elasticsearch.index_exists testindex
salt/modules/elasticsearch.py
def index_exists(index, hosts=None, profile=None): ''' Return a boolean indicating whether given index exists index Index name CLI example:: salt myminion elasticsearch.index_exists testindex ''' es = _get_instance(hosts, profile) try: return es.indices.exists(ind...
def index_exists(index, hosts=None, profile=None): ''' Return a boolean indicating whether given index exists index Index name CLI example:: salt myminion elasticsearch.index_exists testindex ''' es = _get_instance(hosts, profile) try: return es.indices.exists(ind...
[ "Return", "a", "boolean", "indicating", "whether", "given", "index", "exists" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L540-L558
[ "def", "index_exists", "(", "index", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "indices", ".", "exists", "(", "index", "=", "index...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_get
Check for the existence of an index and if it exists, return it index Index name CLI example:: salt myminion elasticsearch.index_get testindex
salt/modules/elasticsearch.py
def index_get(index, hosts=None, profile=None): ''' Check for the existence of an index and if it exists, return it index Index name CLI example:: salt myminion elasticsearch.index_get testindex ''' es = _get_instance(hosts, profile) try: return es.indices.get(ind...
def index_get(index, hosts=None, profile=None): ''' Check for the existence of an index and if it exists, return it index Index name CLI example:: salt myminion elasticsearch.index_get testindex ''' es = _get_instance(hosts, profile) try: return es.indices.get(ind...
[ "Check", "for", "the", "existence", "of", "an", "index", "and", "if", "it", "exists", "return", "it" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L561-L579
[ "def", "index_get", "(", "index", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "indices", ".", "get", "(", "index", "=", "index", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_open
.. versionadded:: 2017.7.0 Open specified index. index Index to be opened allow_no_indices Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes _all string or when no indices have been specified) expand_wildcards Whether to expand...
salt/modules/elasticsearch.py
def index_open(index, allow_no_indices=True, expand_wildcards='closed', ignore_unavailable=True, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Open specified index. index Index to be opened allow_no_indices Whether to ignore if a wildcard indices expression resolves int...
def index_open(index, allow_no_indices=True, expand_wildcards='closed', ignore_unavailable=True, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Open specified index. index Index to be opened allow_no_indices Whether to ignore if a wildcard indices expression resolves int...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L582-L608
[ "def", "index_open", "(", "index", ",", "allow_no_indices", "=", "True", ",", "expand_wildcards", "=", "'closed'", ",", "ignore_unavailable", "=", "True", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "h...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
mapping_create
Create a mapping in a given index index Index for the mapping doc_type Name of the document type body Mapping definition as specified in https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-put-mapping.html source URL to file specifying mapping definit...
salt/modules/elasticsearch.py
def mapping_create(index, doc_type, body=None, hosts=None, profile=None, source=None): ''' Create a mapping in a given index index Index for the mapping doc_type Name of the document type body Mapping definition as specified in https://www.elastic.co/guide/en/elasticsearch/r...
def mapping_create(index, doc_type, body=None, hosts=None, profile=None, source=None): ''' Create a mapping in a given index index Index for the mapping doc_type Name of the document type body Mapping definition as specified in https://www.elastic.co/guide/en/elasticsearch/r...
[ "Create", "a", "mapping", "in", "a", "given", "index" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L640-L670
[ "def", "mapping_create", "(", "index", ",", "doc_type", ",", "body", "=", "None", ",", "hosts", "=", "None", ",", "profile", "=", "None", ",", "source", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "if", "sour...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
mapping_delete
Delete a mapping (type) along with its data. As of Elasticsearch 5.0 this is no longer available. index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.mapping_delete testindex user
salt/modules/elasticsearch.py
def mapping_delete(index, doc_type, hosts=None, profile=None): ''' Delete a mapping (type) along with its data. As of Elasticsearch 5.0 this is no longer available. index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.map...
def mapping_delete(index, doc_type, hosts=None, profile=None): ''' Delete a mapping (type) along with its data. As of Elasticsearch 5.0 this is no longer available. index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.map...
[ "Delete", "a", "mapping", "(", "type", ")", "along", "with", "its", "data", ".", "As", "of", "Elasticsearch", "5", ".", "0", "this", "is", "no", "longer", "available", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L673-L696
[ "def", "mapping_delete", "(", "index", ",", "doc_type", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "indices", ".", "delete_mappi...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
mapping_get
Retrieve mapping definition of index or index/type index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.mapping_get testindex user
salt/modules/elasticsearch.py
def mapping_get(index, doc_type, hosts=None, profile=None): ''' Retrieve mapping definition of index or index/type index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.mapping_get testindex user ''' es = _get_inst...
def mapping_get(index, doc_type, hosts=None, profile=None): ''' Retrieve mapping definition of index or index/type index Index for the mapping doc_type Name of the document type CLI example:: salt myminion elasticsearch.mapping_get testindex user ''' es = _get_inst...
[ "Retrieve", "mapping", "definition", "of", "index", "or", "index", "/", "type" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L699-L719
[ "def", "mapping_get", "(", "index", ",", "doc_type", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "indices", ".", "get_mapping", "(", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_template_create
Create an index template name Index template name body Template definition as specified in http://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html source URL to file specifying template definition. Cannot be used in combination with ``body``. CLI...
salt/modules/elasticsearch.py
def index_template_create(name, body=None, hosts=None, profile=None, source=None): ''' Create an index template name Index template name body Template definition as specified in http://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html source UR...
def index_template_create(name, body=None, hosts=None, profile=None, source=None): ''' Create an index template name Index template name body Template definition as specified in http://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html source UR...
[ "Create", "an", "index", "template" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L722-L751
[ "def", "index_template_create", "(", "name", ",", "body", "=", "None", ",", "hosts", "=", "None", ",", "profile", "=", "None", ",", "source", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "if", "source", "and", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_template_delete
Delete an index template (type) along with its data name Index template name CLI example:: salt myminion elasticsearch.index_template_delete testindex_templ user
salt/modules/elasticsearch.py
def index_template_delete(name, hosts=None, profile=None): ''' Delete an index template (type) along with its data name Index template name CLI example:: salt myminion elasticsearch.index_template_delete testindex_templ user ''' es = _get_instance(hosts, profile) try: ...
def index_template_delete(name, hosts=None, profile=None): ''' Delete an index template (type) along with its data name Index template name CLI example:: salt myminion elasticsearch.index_template_delete testindex_templ user ''' es = _get_instance(hosts, profile) try: ...
[ "Delete", "an", "index", "template", "(", "type", ")", "along", "with", "its", "data" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L754-L773
[ "def", "index_template_delete", "(", "name", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "indices", ".", "delete_template", "(", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_template_exists
Return a boolean indicating whether given index template exists name Index template name CLI example:: salt myminion elasticsearch.index_template_exists testindex_templ
salt/modules/elasticsearch.py
def index_template_exists(name, hosts=None, profile=None): ''' Return a boolean indicating whether given index template exists name Index template name CLI example:: salt myminion elasticsearch.index_template_exists testindex_templ ''' es = _get_instance(hosts, profile) tr...
def index_template_exists(name, hosts=None, profile=None): ''' Return a boolean indicating whether given index template exists name Index template name CLI example:: salt myminion elasticsearch.index_template_exists testindex_templ ''' es = _get_instance(hosts, profile) tr...
[ "Return", "a", "boolean", "indicating", "whether", "given", "index", "template", "exists" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L776-L791
[ "def", "index_template_exists", "(", "name", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "indices", ".", "exists_template", "(", "name",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
index_template_get
Retrieve template definition of index or index/type name Index template name CLI example:: salt myminion elasticsearch.index_template_get testindex_templ
salt/modules/elasticsearch.py
def index_template_get(name, hosts=None, profile=None): ''' Retrieve template definition of index or index/type name Index template name CLI example:: salt myminion elasticsearch.index_template_get testindex_templ ''' es = _get_instance(hosts, profile) try: return...
def index_template_get(name, hosts=None, profile=None): ''' Retrieve template definition of index or index/type name Index template name CLI example:: salt myminion elasticsearch.index_template_get testindex_templ ''' es = _get_instance(hosts, profile) try: return...
[ "Retrieve", "template", "definition", "of", "index", "or", "index", "/", "type" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L794-L812
[ "def", "index_template_get", "(", "name", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "indices", ".", "get_template", "(", "name", "="...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
pipeline_get
.. versionadded:: 2017.7.0 Retrieve Ingest pipeline definition. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_get mypipeline
salt/modules/elasticsearch.py
def pipeline_get(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Retrieve Ingest pipeline definition. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_get mypipeline ''' es = _get_instance(hosts, profile) ...
def pipeline_get(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Retrieve Ingest pipeline definition. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_get mypipeline ''' es = _get_instance(hosts, profile) ...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L815-L837
[ "def", "pipeline_get", "(", "id", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "ingest", ".", "get_pipeline", "(", "id", "=", "id", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
pipeline_delete
.. versionadded:: 2017.7.0 Delete Ingest pipeline. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_delete mypipeline
salt/modules/elasticsearch.py
def pipeline_delete(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete Ingest pipeline. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_delete mypipeline ''' es = _get_instance(hosts, profile) try...
def pipeline_delete(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete Ingest pipeline. Available since Elasticsearch 5.0. id Pipeline id CLI example:: salt myminion elasticsearch.pipeline_delete mypipeline ''' es = _get_instance(hosts, profile) try...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L840-L863
[ "def", "pipeline_delete", "(", "id", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "ret", "=", "es", ".", "ingest", ".", "delete_pipeline", "(", "id", "=",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
pipeline_create
.. versionadded:: 2017.7.0 Create Ingest pipeline by supplied definition. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/elasticsearch/reference/master/pipeline.html CLI example:: salt myminion elasti...
salt/modules/elasticsearch.py
def pipeline_create(id, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create Ingest pipeline by supplied definition. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/elasticsearch/reference/...
def pipeline_create(id, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create Ingest pipeline by supplied definition. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/elasticsearch/reference/...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L866-L888
[ "def", "pipeline_create", "(", "id", ",", "body", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "out", "=", "es", ".", "ingest", ".", "put_pipeline", "(", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
pipeline_simulate
.. versionadded:: 2017.7.0 Simulate existing Ingest pipeline on provided data. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/elasticsearch/reference/master/pipeline.html verbose Specify if the output s...
salt/modules/elasticsearch.py
def pipeline_simulate(id, body, verbose=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Simulate existing Ingest pipeline on provided data. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/el...
def pipeline_simulate(id, body, verbose=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Simulate existing Ingest pipeline on provided data. Available since Elasticsearch 5.0. id Pipeline id body Pipeline definition as specified in https://www.elastic.co/guide/en/el...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L891-L914
[ "def", "pipeline_simulate", "(", "id", ",", "body", ",", "verbose", "=", "False", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "inges...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
search_template_get
.. versionadded:: 2017.7.0 Obtain existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_get mytemplate
salt/modules/elasticsearch.py
def search_template_get(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_get mytemplate ''' es = _get_instance(hosts, profile) try: ...
def search_template_get(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_get mytemplate ''' es = _get_instance(hosts, profile) try: ...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L917-L937
[ "def", "search_template_get", "(", "id", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "get_template", "(", "id", "=", "id", ")", "exc...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
search_template_create
.. versionadded:: 2017.7.0 Create search template by supplied definition id Template ID body Search template definition CLI example:: salt myminion elasticsearch.search_template_create mytemplate '{"template":{"query":{"match":{"title":"{{query_string}}"}}}}'
salt/modules/elasticsearch.py
def search_template_create(id, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create search template by supplied definition id Template ID body Search template definition CLI example:: salt myminion elasticsearch.search_template_create mytemplate '{"t...
def search_template_create(id, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create search template by supplied definition id Template ID body Search template definition CLI example:: salt myminion elasticsearch.search_template_create mytemplate '{"t...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L940-L962
[ "def", "search_template_create", "(", "id", ",", "body", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "put_template", "(", "id", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
search_template_delete
.. versionadded:: 2017.7.0 Delete existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_delete mytemplate
salt/modules/elasticsearch.py
def search_template_delete(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_delete mytemplate ''' es = _get_instance(hosts, profile) try:...
def search_template_delete(id, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete existing search template definition. id Template ID CLI example:: salt myminion elasticsearch.search_template_delete mytemplate ''' es = _get_instance(hosts, profile) try:...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L965-L987
[ "def", "search_template_delete", "(", "id", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "delete_template", "(", "id", "=", "id", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
repository_get
.. versionadded:: 2017.7.0 Get existing repository details. name Repository name local Retrieve only local information, default is false CLI example:: salt myminion elasticsearch.repository_get testrepo
salt/modules/elasticsearch.py
def repository_get(name, local=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Get existing repository details. name Repository name local Retrieve only local information, default is false CLI example:: salt myminion elasticsearch.repository_get testr...
def repository_get(name, local=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Get existing repository details. name Repository name local Retrieve only local information, default is false CLI example:: salt myminion elasticsearch.repository_get testr...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L990-L1012
[ "def", "repository_get", "(", "name", ",", "local", "=", "False", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "snapshot", ".", "get_...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
repository_create
.. versionadded:: 2017.7.0 Create repository for storing snapshots. Note that shared repository paths have to be specified in path.repo Elasticsearch configuration option. name Repository name body Repository definition as in https://www.elastic.co/guide/en/elasticsearch/reference/current/...
salt/modules/elasticsearch.py
def repository_create(name, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create repository for storing snapshots. Note that shared repository paths have to be specified in path.repo Elasticsearch configuration option. name Repository name body Repository definiti...
def repository_create(name, body, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create repository for storing snapshots. Note that shared repository paths have to be specified in path.repo Elasticsearch configuration option. name Repository name body Repository definiti...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1015-L1037
[ "def", "repository_create", "(", "name", ",", "body", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "snapshot", ".", "create_reposi...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
repository_delete
.. versionadded:: 2017.7.0 Delete existing repository. name Repository name CLI example:: salt myminion elasticsearch.repository_delete testrepo
salt/modules/elasticsearch.py
def repository_delete(name, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete existing repository. name Repository name CLI example:: salt myminion elasticsearch.repository_delete testrepo ''' es = _get_instance(hosts, profile) try: result = es...
def repository_delete(name, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete existing repository. name Repository name CLI example:: salt myminion elasticsearch.repository_delete testrepo ''' es = _get_instance(hosts, profile) try: result = es...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1040-L1062
[ "def", "repository_delete", "(", "name", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "snapshot", ".", "delete_repository", "(", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
repository_verify
.. versionadded:: 2017.7.0 Obtain list of cluster nodes which successfully verified this repository. name Repository name CLI example:: salt myminion elasticsearch.repository_verify testrepo
salt/modules/elasticsearch.py
def repository_verify(name, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain list of cluster nodes which successfully verified this repository. name Repository name CLI example:: salt myminion elasticsearch.repository_verify testrepo ''' es = _get_instance...
def repository_verify(name, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain list of cluster nodes which successfully verified this repository. name Repository name CLI example:: salt myminion elasticsearch.repository_verify testrepo ''' es = _get_instance...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1065-L1085
[ "def", "repository_verify", "(", "name", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es", ".", "snapshot", ".", "verify_repository", "(", "reposit...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
snapshot_status
.. versionadded:: 2017.7.0 Obtain status of all currently running snapshots. repository Particular repository to look for snapshots snapshot Snapshot name ignore_unavailable Ignore unavailable snapshots CLI example:: salt myminion elasticsearch.snapshot_status ign...
salt/modules/elasticsearch.py
def snapshot_status(repository=None, snapshot=None, ignore_unavailable=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain status of all currently running snapshots. repository Particular repository to look for snapshots snapshot Snapshot name ignore_unavail...
def snapshot_status(repository=None, snapshot=None, ignore_unavailable=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain status of all currently running snapshots. repository Particular repository to look for snapshots snapshot Snapshot name ignore_unavail...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1088-L1110
[ "def", "snapshot_status", "(", "repository", "=", "None", ",", "snapshot", "=", "None", ",", "ignore_unavailable", "=", "False", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
snapshot_get
.. versionadded:: 2017.7.0 Obtain snapshot residing in specified repository. repository Repository name snapshot Snapshot name, use _all to obtain all snapshots in specified repository ignore_unavailable Ignore unavailable snapshots CLI example:: salt myminion ela...
salt/modules/elasticsearch.py
def snapshot_get(repository, snapshot, ignore_unavailable=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain snapshot residing in specified repository. repository Repository name snapshot Snapshot name, use _all to obtain all snapshots in specified repository ...
def snapshot_get(repository, snapshot, ignore_unavailable=False, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Obtain snapshot residing in specified repository. repository Repository name snapshot Snapshot name, use _all to obtain all snapshots in specified repository ...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1113-L1135
[ "def", "snapshot_get", "(", "repository", ",", "snapshot", ",", "ignore_unavailable", "=", "False", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "return", "es...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
snapshot_create
.. versionadded:: 2017.7.0 Create snapshot in specified repository by supplied definition. repository Repository name snapshot Snapshot name body Snapshot definition as in https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-snapshots.html CLI example:: ...
salt/modules/elasticsearch.py
def snapshot_create(repository, snapshot, body=None, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create snapshot in specified repository by supplied definition. repository Repository name snapshot Snapshot name body Snapshot definition as in https://www.el...
def snapshot_create(repository, snapshot, body=None, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Create snapshot in specified repository by supplied definition. repository Repository name snapshot Snapshot name body Snapshot definition as in https://www.el...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1138-L1162
[ "def", "snapshot_create", "(", "repository", ",", "snapshot", ",", "body", "=", "None", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "response", "=", "es", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
snapshot_delete
.. versionadded:: 2017.7.0 Delete snapshot from specified repository. repository Repository name snapshot Snapshot name CLI example:: salt myminion elasticsearch.snapshot_delete testrepo testsnapshot
salt/modules/elasticsearch.py
def snapshot_delete(repository, snapshot, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete snapshot from specified repository. repository Repository name snapshot Snapshot name CLI example:: salt myminion elasticsearch.snapshot_delete testrepo testsnap...
def snapshot_delete(repository, snapshot, hosts=None, profile=None): ''' .. versionadded:: 2017.7.0 Delete snapshot from specified repository. repository Repository name snapshot Snapshot name CLI example:: salt myminion elasticsearch.snapshot_delete testrepo testsnap...
[ "..", "versionadded", "::", "2017", ".", "7", ".", "0" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/elasticsearch.py#L1192-L1216
[ "def", "snapshot_delete", "(", "repository", ",", "snapshot", ",", "hosts", "=", "None", ",", "profile", "=", "None", ")", ":", "es", "=", "_get_instance", "(", "hosts", ",", "profile", ")", "try", ":", "result", "=", "es", ".", "snapshot", ".", "delet...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
installed
Ensure that the named snap package is installed name The snap package channel Optional. The channel to install the package from.
salt/states/snap.py
def installed(name, channel=None): ''' Ensure that the named snap package is installed name The snap package channel Optional. The channel to install the package from. ''' ret = {'name': name, 'changes': {}, 'pchanges': {}, 'result': None, ...
def installed(name, channel=None): ''' Ensure that the named snap package is installed name The snap package channel Optional. The channel to install the package from. ''' ret = {'name': name, 'changes': {}, 'pchanges': {}, 'result': None, ...
[ "Ensure", "that", "the", "named", "snap", "package", "is", "installed" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/snap.py#L19-L86
[ "def", "installed", "(", "name", ",", "channel", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'pchanges'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "ol...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
removed
Ensure that the named snap package is not installed name The snap package
salt/states/snap.py
def removed(name): ''' Ensure that the named snap package is not installed name The snap package ''' ret = {'name': name, 'changes': {}, 'pchanges': {}, 'result': None, 'comment': ''} old = __salt__['snap.versions_installed'](name) if no...
def removed(name): ''' Ensure that the named snap package is not installed name The snap package ''' ret = {'name': name, 'changes': {}, 'pchanges': {}, 'result': None, 'comment': ''} old = __salt__['snap.versions_installed'](name) if no...
[ "Ensure", "that", "the", "named", "snap", "package", "is", "not", "installed" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/snap.py#L89-L121
[ "def", "removed", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'pchanges'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "old", "=", "__salt__", "[", "'sna...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
_get_queue
Check the context for the notifier and construct it if not present
salt/beacons/watchdog.py
def _get_queue(config): ''' Check the context for the notifier and construct it if not present ''' if 'watchdog.observer' not in __context__: queue = collections.deque() observer = Observer() for path in config.get('directories', {}): path_params = config.get('direct...
def _get_queue(config): ''' Check the context for the notifier and construct it if not present ''' if 'watchdog.observer' not in __context__: queue = collections.deque() observer = Observer() for path in config.get('directories', {}): path_params = config.get('direct...
[ "Check", "the", "context", "for", "the", "notifier", "and", "construct", "it", "if", "not", "present" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/beacons/watchdog.py#L80-L99
[ "def", "_get_queue", "(", "config", ")", ":", "if", "'watchdog.observer'", "not", "in", "__context__", ":", "queue", "=", "collections", ".", "deque", "(", ")", "observer", "=", "Observer", "(", ")", "for", "path", "in", "config", ".", "get", "(", "'dire...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
validate
Validate the beacon configuration
salt/beacons/watchdog.py
def validate(config): ''' Validate the beacon configuration ''' try: _validate(config) return True, 'Valid beacon configuration' except ValidationError as error: return False, str(error)
def validate(config): ''' Validate the beacon configuration ''' try: _validate(config) return True, 'Valid beacon configuration' except ValidationError as error: return False, str(error)
[ "Validate", "the", "beacon", "configuration" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/beacons/watchdog.py#L106-L115
[ "def", "validate", "(", "config", ")", ":", "try", ":", "_validate", "(", "config", ")", "return", "True", ",", "'Valid beacon configuration'", "except", "ValidationError", "as", "error", ":", "return", "False", ",", "str", "(", "error", ")" ]
e8541fd6e744ab0df786c0f76102e41631f45d46
train
beacon
Watch the configured directories Example Config .. code-block:: yaml beacons: watchdog: - directories: /path/to/dir: mask: - create - modify - delete - move The...
salt/beacons/watchdog.py
def beacon(config): ''' Watch the configured directories Example Config .. code-block:: yaml beacons: watchdog: - directories: /path/to/dir: mask: - create - modify - delete ...
def beacon(config): ''' Watch the configured directories Example Config .. code-block:: yaml beacons: watchdog: - directories: /path/to/dir: mask: - create - modify - delete ...
[ "Watch", "the", "configured", "directories" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/beacons/watchdog.py#L175-L210
[ "def", "beacon", "(", "config", ")", ":", "_config", "=", "{", "}", "list", "(", "map", "(", "_config", ".", "update", ",", "config", ")", ")", "queue", "=", "_get_queue", "(", "_config", ")", "ret", "=", "[", "]", "while", "queue", ":", "ret", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
bounce_cluster
Bounce all Traffic Server nodes in the cluster. Bouncing Traffic Server shuts down and immediately restarts Traffic Server, node-by-node. .. code-block:: yaml bounce_ats_cluster: trafficserver.bounce_cluster
salt/states/trafficserver.py
def bounce_cluster(name): ''' Bounce all Traffic Server nodes in the cluster. Bouncing Traffic Server shuts down and immediately restarts Traffic Server, node-by-node. .. code-block:: yaml bounce_ats_cluster: trafficserver.bounce_cluster ''' ret = {'name': name, 'c...
def bounce_cluster(name): ''' Bounce all Traffic Server nodes in the cluster. Bouncing Traffic Server shuts down and immediately restarts Traffic Server, node-by-node. .. code-block:: yaml bounce_ats_cluster: trafficserver.bounce_cluster ''' ret = {'name': name, 'c...
[ "Bounce", "all", "Traffic", "Server", "nodes", "in", "the", "cluster", ".", "Bouncing", "Traffic", "Server", "shuts", "down", "and", "immediately", "restarts", "Traffic", "Server", "node", "-", "by", "-", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L20-L43
[ "def", "bounce_cluster", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'commen...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
bounce_local
Bounce Traffic Server on the local node. Bouncing Traffic Server shuts down and immediately restarts the Traffic Server node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number of active client connections drops to the num...
salt/states/trafficserver.py
def bounce_local(name, drain=False): ''' Bounce Traffic Server on the local node. Bouncing Traffic Server shuts down and immediately restarts the Traffic Server node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number ...
def bounce_local(name, drain=False): ''' Bounce Traffic Server on the local node. Bouncing Traffic Server shuts down and immediately restarts the Traffic Server node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number ...
[ "Bounce", "Traffic", "Server", "on", "the", "local", "node", ".", "Bouncing", "Traffic", "Server", "shuts", "down", "and", "immediately", "restarts", "the", "Traffic", "Server", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L46-L83
[ "def", "bounce_local", "(", "name", ",", "drain", "=", "False", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
clear_cluster
Clears accumulated statistics on all nodes in the cluster. .. code-block:: yaml clear_ats_cluster: trafficserver.clear_cluster
salt/states/trafficserver.py
def clear_cluster(name): ''' Clears accumulated statistics on all nodes in the cluster. .. code-block:: yaml clear_ats_cluster: trafficserver.clear_cluster ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['te...
def clear_cluster(name): ''' Clears accumulated statistics on all nodes in the cluster. .. code-block:: yaml clear_ats_cluster: trafficserver.clear_cluster ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['te...
[ "Clears", "accumulated", "statistics", "on", "all", "nodes", "in", "the", "cluster", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L86-L108
[ "def", "clear_cluster", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
clear_node
Clears accumulated statistics on the local node. .. code-block:: yaml clear_ats_node: trafficserver.clear_node
salt/states/trafficserver.py
def clear_node(name): ''' Clears accumulated statistics on the local node. .. code-block:: yaml clear_ats_node: trafficserver.clear_node ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['...
def clear_node(name): ''' Clears accumulated statistics on the local node. .. code-block:: yaml clear_ats_node: trafficserver.clear_node ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['...
[ "Clears", "accumulated", "statistics", "on", "the", "local", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L111-L133
[ "def", "clear_node", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
restart_cluster
Restart the traffic_manager process and the traffic_server process on all the nodes in a cluster. .. code-block:: bash restart_ats_cluster: trafficserver.restart_cluster
salt/states/trafficserver.py
def restart_cluster(name): ''' Restart the traffic_manager process and the traffic_server process on all the nodes in a cluster. .. code-block:: bash restart_ats_cluster: trafficserver.restart_cluster ''' ret = {'name': name, 'changes': {}, 'result': No...
def restart_cluster(name): ''' Restart the traffic_manager process and the traffic_server process on all the nodes in a cluster. .. code-block:: bash restart_ats_cluster: trafficserver.restart_cluster ''' ret = {'name': name, 'changes': {}, 'result': No...
[ "Restart", "the", "traffic_manager", "process", "and", "the", "traffic_server", "process", "on", "all", "the", "nodes", "in", "a", "cluster", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L136-L160
[ "def", "restart_cluster", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comme...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
restart_local
Restart the traffic_manager and traffic_server processes on the local node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number of active client connections drops to the number given by the proxy.config.restart.active_clien...
salt/states/trafficserver.py
def restart_local(name, drain=False): ''' Restart the traffic_manager and traffic_server processes on the local node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number of active client connections drops to the number ...
def restart_local(name, drain=False): ''' Restart the traffic_manager and traffic_server processes on the local node. This option modifies the behavior of traffic_line -b and traffic_line -L such that traffic_server is not shut down until the number of active client connections drops to the number ...
[ "Restart", "the", "traffic_manager", "and", "traffic_server", "processes", "on", "the", "local", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L163-L199
[ "def", "restart_local", "(", "name", ",", "drain", "=", "False", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]"...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
config
Set Traffic Server configuration variable values. .. code-block:: yaml proxy.config.proxy_name: trafficserver.config: - value: cdn.site.domain.tld OR traffic_server_setting: trafficserver.config: - name: proxy.config.proxy_name - va...
salt/states/trafficserver.py
def config(name, value): ''' Set Traffic Server configuration variable values. .. code-block:: yaml proxy.config.proxy_name: trafficserver.config: - value: cdn.site.domain.tld OR traffic_server_setting: trafficserver.config: - name: pro...
def config(name, value): ''' Set Traffic Server configuration variable values. .. code-block:: yaml proxy.config.proxy_name: trafficserver.config: - value: cdn.site.domain.tld OR traffic_server_setting: trafficserver.config: - name: pro...
[ "Set", "Traffic", "Server", "configuration", "variable", "values", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L202-L236
[ "def", "config", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
shutdown
Shut down Traffic Server on the local node. .. code-block:: yaml shutdown_ats: trafficserver.shutdown
salt/states/trafficserver.py
def shutdown(name): ''' Shut down Traffic Server on the local node. .. code-block:: yaml shutdown_ats: trafficserver.shutdown ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['comment'] =...
def shutdown(name): ''' Shut down Traffic Server on the local node. .. code-block:: yaml shutdown_ats: trafficserver.shutdown ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['comment'] =...
[ "Shut", "down", "Traffic", "Server", "on", "the", "local", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L239-L261
[ "def", "shutdown", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
startup
Start Traffic Server on the local node. .. code-block:: yaml startup_ats: trafficserver.startup
salt/states/trafficserver.py
def startup(name): ''' Start Traffic Server on the local node. .. code-block:: yaml startup_ats: trafficserver.startup ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['comment'] = 'Start...
def startup(name): ''' Start Traffic Server on the local node. .. code-block:: yaml startup_ats: trafficserver.startup ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: ret['comment'] = 'Start...
[ "Start", "Traffic", "Server", "on", "the", "local", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L264-L286
[ "def", "startup", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
refresh
Initiate a Traffic Server configuration file reread. Use this command to update the running configuration after any configuration file modification. The timestamp of the last reconfiguration event (in seconds since epoch) is published in the proxy.node.config.reconfigure_time metric. .. code-block:: y...
salt/states/trafficserver.py
def refresh(name): ''' Initiate a Traffic Server configuration file reread. Use this command to update the running configuration after any configuration file modification. The timestamp of the last reconfiguration event (in seconds since epoch) is published in the proxy.node.config.reconfigure_time...
def refresh(name): ''' Initiate a Traffic Server configuration file reread. Use this command to update the running configuration after any configuration file modification. The timestamp of the last reconfiguration event (in seconds since epoch) is published in the proxy.node.config.reconfigure_time...
[ "Initiate", "a", "Traffic", "Server", "configuration", "file", "reread", ".", "Use", "this", "command", "to", "update", "the", "running", "configuration", "after", "any", "configuration", "file", "modification", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L289-L315
[ "def", "refresh", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
zero_cluster
Reset performance statistics to zero across the cluster. .. code-block:: yaml zero_ats_cluster: trafficserver.zero_cluster
salt/states/trafficserver.py
def zero_cluster(name): ''' Reset performance statistics to zero across the cluster. .. code-block:: yaml zero_ats_cluster: trafficserver.zero_cluster ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']:...
def zero_cluster(name): ''' Reset performance statistics to zero across the cluster. .. code-block:: yaml zero_ats_cluster: trafficserver.zero_cluster ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']:...
[ "Reset", "performance", "statistics", "to", "zero", "across", "the", "cluster", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L318-L340
[ "def", "zero_cluster", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
zero_node
Reset performance statistics to zero on the local node. .. code-block:: yaml zero_ats_node: trafficserver.zero_node
salt/states/trafficserver.py
def zero_node(name): ''' Reset performance statistics to zero on the local node. .. code-block:: yaml zero_ats_node: trafficserver.zero_node ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: r...
def zero_node(name): ''' Reset performance statistics to zero on the local node. .. code-block:: yaml zero_ats_node: trafficserver.zero_node ''' ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''} if __opts__['test']: r...
[ "Reset", "performance", "statistics", "to", "zero", "on", "the", "local", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L343-L365
[ "def", "zero_node", "(", "name", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", "'comment'", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
offline
Mark a cache storage device as offline. The storage is identified by a path which must match exactly a path specified in storage.config. This removes the storage from the cache and redirects requests that would have used this storage to other storage. This has exactly the same effect as a disk failure f...
salt/states/trafficserver.py
def offline(name, path): ''' Mark a cache storage device as offline. The storage is identified by a path which must match exactly a path specified in storage.config. This removes the storage from the cache and redirects requests that would have used this storage to other storage. This has exactly th...
def offline(name, path): ''' Mark a cache storage device as offline. The storage is identified by a path which must match exactly a path specified in storage.config. This removes the storage from the cache and redirects requests that would have used this storage to other storage. This has exactly th...
[ "Mark", "a", "cache", "storage", "device", "as", "offline", ".", "The", "storage", "is", "identified", "by", "a", "path", "which", "must", "match", "exactly", "a", "path", "specified", "in", "storage", ".", "config", ".", "This", "removes", "the", "storage...
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/trafficserver.py#L368-L396
[ "def", "offline", "(", "name", ",", "path", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'changes'", ":", "{", "}", ",", "'result'", ":", "None", ",", "'comment'", ":", "''", "}", "if", "__opts__", "[", "'test'", "]", ":", "ret", "[", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
present
Ensure that a data source is present. name Name of the data source. type Which type of data source it is ('graphite', 'influxdb' etc.). url The URL to the data source API. user Optional - user to authenticate with the data source password Optional - passw...
salt/states/grafana_datasource.py
def present(name, type, url, access='proxy', user='', password='', database='', basic_auth=False, basic_auth_user='', basic_auth_password='', is_default=False, json_data=None, ...
def present(name, type, url, access='proxy', user='', password='', database='', basic_auth=False, basic_auth_user='', basic_auth_password='', is_default=False, json_data=None, ...
[ "Ensure", "that", "a", "data", "source", "is", "present", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/grafana_datasource.py#L39-L116
[ "def", "present", "(", "name", ",", "type", ",", "url", ",", "access", "=", "'proxy'", ",", "user", "=", "''", ",", "password", "=", "''", ",", "database", "=", "''", ",", "basic_auth", "=", "False", ",", "basic_auth_user", "=", "''", ",", "basic_aut...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
absent
Ensure that a data source is present. name Name of the data source to remove.
salt/states/grafana_datasource.py
def absent(name, profile='grafana'): ''' Ensure that a data source is present. name Name of the data source to remove. ''' if isinstance(profile, string_types): profile = __salt__['config.option'](profile) ret = {'result': None, 'comment': None, 'changes': {}} datasource = ...
def absent(name, profile='grafana'): ''' Ensure that a data source is present. name Name of the data source to remove. ''' if isinstance(profile, string_types): profile = __salt__['config.option'](profile) ret = {'result': None, 'comment': None, 'changes': {}} datasource = ...
[ "Ensure", "that", "a", "data", "source", "is", "present", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/grafana_datasource.py#L119-L146
[ "def", "absent", "(", "name", ",", "profile", "=", "'grafana'", ")", ":", "if", "isinstance", "(", "profile", ",", "string_types", ")", ":", "profile", "=", "__salt__", "[", "'config.option'", "]", "(", "profile", ")", "ret", "=", "{", "'result'", ":", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
compare_changes
Compare two dicts returning only keys that exist in the first dict and are different in the second one
salt/modules/neutronng.py
def compare_changes(obj, **kwargs): ''' Compare two dicts returning only keys that exist in the first dict and are different in the second one ''' changes = {} for key, value in obj.items(): if key in kwargs: if value != kwargs[key]: changes[key] = kwargs[key]...
def compare_changes(obj, **kwargs): ''' Compare two dicts returning only keys that exist in the first dict and are different in the second one ''' changes = {} for key, value in obj.items(): if key in kwargs: if value != kwargs[key]: changes[key] = kwargs[key]...
[ "Compare", "two", "dicts", "returning", "only", "keys", "that", "exist", "in", "the", "first", "dict", "and", "are", "different", "in", "the", "second", "one" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L51-L61
[ "def", "compare_changes", "(", "obj", ",", "*", "*", "kwargs", ")", ":", "changes", "=", "{", "}", "for", "key", ",", "value", "in", "obj", ".", "items", "(", ")", ":", "if", "key", "in", "kwargs", ":", "if", "value", "!=", "kwargs", "[", "key", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
network_create
Create a network name Name of the network being created shared : False If ``True``, set the network as shared admin_state_up : True If ``True``, Set the network administrative state to "up" external : False Control whether or not this network is externally accessible ...
salt/modules/neutronng.py
def network_create(auth=None, **kwargs): ''' Create a network name Name of the network being created shared : False If ``True``, set the network as shared admin_state_up : True If ``True``, Set the network administrative state to "up" external : False Control ...
def network_create(auth=None, **kwargs): ''' Create a network name Name of the network being created shared : False If ``True``, set the network as shared admin_state_up : True If ``True``, Set the network administrative state to "up" external : False Control ...
[ "Create", "a", "network" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L109-L147
[ "def", "network_create", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "keep_name", "=", "True", ",", "*", "*", "kwargs", ")", "return", "cloud", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
network_delete
Delete a network name_or_id Name or ID of the network being deleted CLI Example: .. code-block:: bash salt '*' neutronng.network_delete name_or_id=network1 salt '*' neutronng.network_delete name_or_id=1dcac318a83b4610b7a7f7ba01465548
salt/modules/neutronng.py
def network_delete(auth=None, **kwargs): ''' Delete a network name_or_id Name or ID of the network being deleted CLI Example: .. code-block:: bash salt '*' neutronng.network_delete name_or_id=network1 salt '*' neutronng.network_delete name_or_id=1dcac318a83b4610b7a7f7ba01...
def network_delete(auth=None, **kwargs): ''' Delete a network name_or_id Name or ID of the network being deleted CLI Example: .. code-block:: bash salt '*' neutronng.network_delete name_or_id=network1 salt '*' neutronng.network_delete name_or_id=1dcac318a83b4610b7a7f7ba01...
[ "Delete", "a", "network" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L150-L167
[ "def", "network_delete", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "delete_network", "(", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_networks
List networks filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_networks salt '*' neutronng.list_networks \ filters='{"tenant_id": "1dcac318a83b4610b7a7f7ba01465548"}'
salt/modules/neutronng.py
def list_networks(auth=None, **kwargs): ''' List networks filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_networks salt '*' neutronng.list_networks \ filters='{"tenant_id": "1dcac318a83b4610...
def list_networks(auth=None, **kwargs): ''' List networks filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_networks salt '*' neutronng.list_networks \ filters='{"tenant_id": "1dcac318a83b4610...
[ "List", "networks" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L170-L188
[ "def", "list_networks", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "list_networks", "(", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
network_get
Get a single network filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.network_get name=XLB4
salt/modules/neutronng.py
def network_get(auth=None, **kwargs): ''' Get a single network filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.network_get name=XLB4 ''' cloud = get_operator_cloud(auth) kwargs = _clean_kwargs(**kwarg...
def network_get(auth=None, **kwargs): ''' Get a single network filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.network_get name=XLB4 ''' cloud = get_operator_cloud(auth) kwargs = _clean_kwargs(**kwarg...
[ "Get", "a", "single", "network" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L191-L207
[ "def", "network_get", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "get_network", "(", "*", "*",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
subnet_create
Create a subnet network_name_or_id The unique name or ID of the attached network. If a non-unique name is supplied, an exception is raised. cidr The CIDR ip_version The IP version, which is 4 or 6. enable_dhcp : False Set to ``True`` if DHCP is enabled and ``F...
salt/modules/neutronng.py
def subnet_create(auth=None, **kwargs): ''' Create a subnet network_name_or_id The unique name or ID of the attached network. If a non-unique name is supplied, an exception is raised. cidr The CIDR ip_version The IP version, which is 4 or 6. enable_dhcp : Fals...
def subnet_create(auth=None, **kwargs): ''' Create a subnet network_name_or_id The unique name or ID of the attached network. If a non-unique name is supplied, an exception is raised. cidr The CIDR ip_version The IP version, which is 4 or 6. enable_dhcp : Fals...
[ "Create", "a", "subnet" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L210-L285
[ "def", "subnet_create", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "create_subnet", "(", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
subnet_update
Update a subnet name_or_id Name or ID of the subnet to update subnet_name The new name of the subnet enable_dhcp Set to ``True`` if DHCP is enabled and ``False`` if disabled gateway_ip The gateway IP address. When you specify both allocation_pools and gateway_...
salt/modules/neutronng.py
def subnet_update(auth=None, **kwargs): ''' Update a subnet name_or_id Name or ID of the subnet to update subnet_name The new name of the subnet enable_dhcp Set to ``True`` if DHCP is enabled and ``False`` if disabled gateway_ip The gateway IP address. When yo...
def subnet_update(auth=None, **kwargs): ''' Update a subnet name_or_id Name or ID of the subnet to update subnet_name The new name of the subnet enable_dhcp Set to ``True`` if DHCP is enabled and ``False`` if disabled gateway_ip The gateway IP address. When yo...
[ "Update", "a", "subnet" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L288-L328
[ "def", "subnet_update", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "update_subnet", "(", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
subnet_delete
Delete a subnet name Name or ID of the subnet to update CLI Example: .. code-block:: bash salt '*' neutronng.subnet_delete name=subnet1 salt '*' neutronng.subnet_delete \ name=1dcac318a83b4610b7a7f7ba01465548
salt/modules/neutronng.py
def subnet_delete(auth=None, **kwargs): ''' Delete a subnet name Name or ID of the subnet to update CLI Example: .. code-block:: bash salt '*' neutronng.subnet_delete name=subnet1 salt '*' neutronng.subnet_delete \ name=1dcac318a83b4610b7a7f7ba01465548 ''' ...
def subnet_delete(auth=None, **kwargs): ''' Delete a subnet name Name or ID of the subnet to update CLI Example: .. code-block:: bash salt '*' neutronng.subnet_delete name=subnet1 salt '*' neutronng.subnet_delete \ name=1dcac318a83b4610b7a7f7ba01465548 ''' ...
[ "Delete", "a", "subnet" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L331-L349
[ "def", "subnet_delete", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "delete_subnet", "(", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_subnets
List subnets filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_subnets salt '*' neutronng.list_subnets \ filters='{"tenant_id": "1dcac318a83b4610b7a7f7ba01465548"}'
salt/modules/neutronng.py
def list_subnets(auth=None, **kwargs): ''' List subnets filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_subnets salt '*' neutronng.list_subnets \ filters='{"tenant_id": "1dcac318a83b4610b7a7...
def list_subnets(auth=None, **kwargs): ''' List subnets filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.list_subnets salt '*' neutronng.list_subnets \ filters='{"tenant_id": "1dcac318a83b4610b7a7...
[ "List", "subnets" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L352-L370
[ "def", "list_subnets", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "list_subnets", "(", "*", "*...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
subnet_get
Get a single subnet filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.subnet_get name=subnet1
salt/modules/neutronng.py
def subnet_get(auth=None, **kwargs): ''' Get a single subnet filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.subnet_get name=subnet1 ''' cloud = get_operator_cloud(auth) kwargs = _clean_kwargs(**kwarg...
def subnet_get(auth=None, **kwargs): ''' Get a single subnet filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.subnet_get name=subnet1 ''' cloud = get_operator_cloud(auth) kwargs = _clean_kwargs(**kwarg...
[ "Get", "a", "single", "subnet" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L373-L389
[ "def", "subnet_get", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "get_subnet", "(", "*", "*", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_create
Create a security group. Use security_group_get to create default. project_id The project ID on which this security group will be created CLI Example: .. code-block:: bash salt '*' neutronng.security_group_create name=secgroup1 \ description="Very secure security group" ...
salt/modules/neutronng.py
def security_group_create(auth=None, **kwargs): ''' Create a security group. Use security_group_get to create default. project_id The project ID on which this security group will be created CLI Example: .. code-block:: bash salt '*' neutronng.security_group_create name=secgroup1 ...
def security_group_create(auth=None, **kwargs): ''' Create a security group. Use security_group_get to create default. project_id The project ID on which this security group will be created CLI Example: .. code-block:: bash salt '*' neutronng.security_group_create name=secgroup1 ...
[ "Create", "a", "security", "group", ".", "Use", "security_group_get", "to", "create", "default", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L392-L412
[ "def", "security_group_create", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "keep_name", "=", "True", ",", "*", "*", "kwargs", ")", "return", "clo...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_update
Update a security group secgroup Name, ID or Raw Object of the security group to update name New name for the security group description New description for the security group CLI Example: .. code-block:: bash salt '*' neutronng.security_group_update secgroup=se...
salt/modules/neutronng.py
def security_group_update(secgroup=None, auth=None, **kwargs): ''' Update a security group secgroup Name, ID or Raw Object of the security group to update name New name for the security group description New description for the security group CLI Example: .. code...
def security_group_update(secgroup=None, auth=None, **kwargs): ''' Update a security group secgroup Name, ID or Raw Object of the security group to update name New name for the security group description New description for the security group CLI Example: .. code...
[ "Update", "a", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L415-L441
[ "def", "security_group_update", "(", "secgroup", "=", "None", ",", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "keep_name", "=", "True", ",", "*", "*",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_delete
Delete a security group name_or_id The name or unique ID of the security group CLI Example: .. code-block:: bash salt '*' neutronng.security_group_delete name_or_id=secgroup1
salt/modules/neutronng.py
def security_group_delete(auth=None, **kwargs): ''' Delete a security group name_or_id The name or unique ID of the security group CLI Example: .. code-block:: bash salt '*' neutronng.security_group_delete name_or_id=secgroup1 ''' cloud = get_operator_cloud(auth) kwa...
def security_group_delete(auth=None, **kwargs): ''' Delete a security group name_or_id The name or unique ID of the security group CLI Example: .. code-block:: bash salt '*' neutronng.security_group_delete name_or_id=secgroup1 ''' cloud = get_operator_cloud(auth) kwa...
[ "Delete", "a", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L444-L460
[ "def", "security_group_delete", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "delete_security_group", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_get
Get a single security group. This will create a default security group if one does not exist yet for a particular project id. filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt '*' neutronng.security_group_get \ name=1dcac31...
salt/modules/neutronng.py
def security_group_get(auth=None, **kwargs): ''' Get a single security group. This will create a default security group if one does not exist yet for a particular project id. filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt ...
def security_group_get(auth=None, **kwargs): ''' Get a single security group. This will create a default security group if one does not exist yet for a particular project id. filters A Python dictionary of filter conditions to push down CLI Example: .. code-block:: bash salt ...
[ "Get", "a", "single", "security", "group", ".", "This", "will", "create", "a", "default", "security", "group", "if", "one", "does", "not", "exist", "yet", "for", "a", "particular", "project", "id", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L463-L484
[ "def", "security_group_get", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "get_security_group", "(",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_rule_create
Create a rule in a security group secgroup_name_or_id The security group name or ID to associate with this security group rule. If a non-unique group name is given, an exception is raised. port_range_min The minimum port number in the range that is matched by the security group...
salt/modules/neutronng.py
def security_group_rule_create(auth=None, **kwargs): ''' Create a rule in a security group secgroup_name_or_id The security group name or ID to associate with this security group rule. If a non-unique group name is given, an exception is raised. port_range_min The minimum port ...
def security_group_rule_create(auth=None, **kwargs): ''' Create a rule in a security group secgroup_name_or_id The security group name or ID to associate with this security group rule. If a non-unique group name is given, an exception is raised. port_range_min The minimum port ...
[ "Create", "a", "rule", "in", "a", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L487-L552
[ "def", "security_group_rule_create", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "create_security_gro...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
security_group_rule_delete
Delete a security group name_or_id The unique ID of the security group rule CLI Example: .. code-block:: bash salt '*' neutronng.security_group_rule_delete name_or_id=1dcac318a83b4610b7a7f7ba01465548
salt/modules/neutronng.py
def security_group_rule_delete(auth=None, **kwargs): ''' Delete a security group name_or_id The unique ID of the security group rule CLI Example: .. code-block:: bash salt '*' neutronng.security_group_rule_delete name_or_id=1dcac318a83b4610b7a7f7ba01465548 ''' cloud = ge...
def security_group_rule_delete(auth=None, **kwargs): ''' Delete a security group name_or_id The unique ID of the security group rule CLI Example: .. code-block:: bash salt '*' neutronng.security_group_rule_delete name_or_id=1dcac318a83b4610b7a7f7ba01465548 ''' cloud = ge...
[ "Delete", "a", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/neutronng.py#L555-L571
[ "def", "security_group_rule_delete", "(", "auth", "=", "None", ",", "*", "*", "kwargs", ")", ":", "cloud", "=", "get_operator_cloud", "(", "auth", ")", "kwargs", "=", "_clean_kwargs", "(", "*", "*", "kwargs", ")", "return", "cloud", ".", "delete_security_gro...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
avail_locations
Return a dict of all available VM locations on the cloud provider with relevant data
salt/cloud/clouds/aliyun.py
def avail_locations(call=None): ''' Return a dict of all available VM locations on the cloud provider with relevant data ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_locations function must be called with ' '-f or --function, or with the --list-locat...
def avail_locations(call=None): ''' Return a dict of all available VM locations on the cloud provider with relevant data ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_locations function must be called with ' '-f or --function, or with the --list-locat...
[ "Return", "a", "dict", "of", "all", "available", "VM", "locations", "on", "the", "cloud", "provider", "with", "relevant", "data" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L124-L144
[ "def", "avail_locations", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The avail_locations function must be called with '", "'-f or --function, or with the --list-locations option'", ")", "params", "=", "{",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
avail_images
Return a list of the images that are on the provider
salt/cloud/clouds/aliyun.py
def avail_images(kwargs=None, call=None): ''' Return a list of the images that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_images function must be called with ' '-f or --function, or with the --list-images option' ) if n...
def avail_images(kwargs=None, call=None): ''' Return a list of the images that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_images function must be called with ' '-f or --function, or with the --list-images option' ) if n...
[ "Return", "a", "list", "of", "the", "images", "that", "are", "on", "the", "provider" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L147-L179
[ "def", "avail_images", "(", "kwargs", "=", "None", ",", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The avail_images function must be called with '", "'-f or --function, or with the --list-images option'", ")"...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
avail_sizes
Return a list of the image sizes that are on the provider
salt/cloud/clouds/aliyun.py
def avail_sizes(call=None): ''' Return a list of the image sizes that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_sizes function must be called with ' '-f or --function, or with the --list-sizes option' ) params = {'Acti...
def avail_sizes(call=None): ''' Return a list of the image sizes that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The avail_sizes function must be called with ' '-f or --function, or with the --list-sizes option' ) params = {'Acti...
[ "Return", "a", "list", "of", "the", "image", "sizes", "that", "are", "on", "the", "provider" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L182-L201
[ "def", "avail_sizes", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The avail_sizes function must be called with '", "'-f or --function, or with the --list-sizes option'", ")", "params", "=", "{", "'Action'...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_availability_zones
List all availability zones in the current region
salt/cloud/clouds/aliyun.py
def list_availability_zones(call=None): ''' List all availability zones in the current region ''' ret = {} params = {'Action': 'DescribeZones', 'RegionId': get_location()} items = query(params) for zone in items['Zones']['Zone']: ret[zone['ZoneId']] = {} for i...
def list_availability_zones(call=None): ''' List all availability zones in the current region ''' ret = {} params = {'Action': 'DescribeZones', 'RegionId': get_location()} items = query(params) for zone in items['Zones']['Zone']: ret[zone['ZoneId']] = {} for i...
[ "List", "all", "availability", "zones", "in", "the", "current", "region" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L223-L238
[ "def", "list_availability_zones", "(", "call", "=", "None", ")", ":", "ret", "=", "{", "}", "params", "=", "{", "'Action'", ":", "'DescribeZones'", ",", "'RegionId'", ":", "get_location", "(", ")", "}", "items", "=", "query", "(", "params", ")", "for", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_nodes_min
Return a list of the VMs that are on the provider. Only a list of VM names, and their state, is returned. This is the minimum amount of information needed to check for existing VMs.
salt/cloud/clouds/aliyun.py
def list_nodes_min(call=None): ''' Return a list of the VMs that are on the provider. Only a list of VM names, and their state, is returned. This is the minimum amount of information needed to check for existing VMs. ''' if call == 'action': raise SaltCloudSystemExit( 'The li...
def list_nodes_min(call=None): ''' Return a list of the VMs that are on the provider. Only a list of VM names, and their state, is returned. This is the minimum amount of information needed to check for existing VMs. ''' if call == 'action': raise SaltCloudSystemExit( 'The li...
[ "Return", "a", "list", "of", "the", "VMs", "that", "are", "on", "the", "provider", ".", "Only", "a", "list", "of", "VM", "names", "and", "their", "state", "is", "returned", ".", "This", "is", "the", "minimum", "amount", "of", "information", "needed", "...
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L241-L272
[ "def", "list_nodes_min", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The list_nodes_min function must be called with -f or --function.'", ")", "ret", "=", "{", "}", "location", "=", "get_location", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_nodes
Return a list of the VMs that are on the provider
salt/cloud/clouds/aliyun.py
def list_nodes(call=None): ''' Return a list of the VMs that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes function must be called with -f or --function.' ) nodes = list_nodes_full() ret = {} for instanceId in nodes: ...
def list_nodes(call=None): ''' Return a list of the VMs that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes function must be called with -f or --function.' ) nodes = list_nodes_full() ret = {} for instanceId in nodes: ...
[ "Return", "a", "list", "of", "the", "VMs", "that", "are", "on", "the", "provider" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L275-L296
[ "def", "list_nodes", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The list_nodes function must be called with -f or --function.'", ")", "nodes", "=", "list_nodes_full", "(", ")", "ret", "=", "{", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_nodes_full
Return a list of the VMs that are on the provider
salt/cloud/clouds/aliyun.py
def list_nodes_full(call=None): ''' Return a list of the VMs that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes_full function must be called with -f ' 'or --function.' ) ret = {} location = get_location() para...
def list_nodes_full(call=None): ''' Return a list of the VMs that are on the provider ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes_full function must be called with -f ' 'or --function.' ) ret = {} location = get_location() para...
[ "Return", "a", "list", "of", "the", "VMs", "that", "are", "on", "the", "provider" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L299-L375
[ "def", "list_nodes_full", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The list_nodes_full function must be called with -f '", "'or --function.'", ")", "ret", "=", "{", "}", "location", "=", "get_loc...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_securitygroup
Return a list of security group
salt/cloud/clouds/aliyun.py
def list_securitygroup(call=None): ''' Return a list of security group ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes function must be called with -f or --function.' ) params = { 'Action': 'DescribeSecurityGroups', 'RegionId': get_loc...
def list_securitygroup(call=None): ''' Return a list of security group ''' if call == 'action': raise SaltCloudSystemExit( 'The list_nodes function must be called with -f or --function.' ) params = { 'Action': 'DescribeSecurityGroups', 'RegionId': get_loc...
[ "Return", "a", "list", "of", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L387-L412
[ "def", "list_securitygroup", "(", "call", "=", "None", ")", ":", "if", "call", "==", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The list_nodes function must be called with -f or --function.'", ")", "params", "=", "{", "'Action'", ":", "'DescribeSecurityGrou...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
get_image
Return the image object to use
salt/cloud/clouds/aliyun.py
def get_image(vm_): ''' Return the image object to use ''' images = avail_images() vm_image = six.text_type(config.get_cloud_config_value( 'image', vm_, __opts__, search_global=False )) if not vm_image: raise SaltCloudNotFound('No image specified for this VM.') if vm_im...
def get_image(vm_): ''' Return the image object to use ''' images = avail_images() vm_image = six.text_type(config.get_cloud_config_value( 'image', vm_, __opts__, search_global=False )) if not vm_image: raise SaltCloudNotFound('No image specified for this VM.') if vm_im...
[ "Return", "the", "image", "object", "to", "use" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L415-L431
[ "def", "get_image", "(", "vm_", ")", ":", "images", "=", "avail_images", "(", ")", "vm_image", "=", "six", ".", "text_type", "(", "config", ".", "get_cloud_config_value", "(", "'image'", ",", "vm_", ",", "__opts__", ",", "search_global", "=", "False", ")",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
get_securitygroup
Return the security group
salt/cloud/clouds/aliyun.py
def get_securitygroup(vm_): ''' Return the security group ''' sgs = list_securitygroup() securitygroup = config.get_cloud_config_value( 'securitygroup', vm_, __opts__, search_global=False ) if not securitygroup: raise SaltCloudNotFound('No securitygroup ID specified for this...
def get_securitygroup(vm_): ''' Return the security group ''' sgs = list_securitygroup() securitygroup = config.get_cloud_config_value( 'securitygroup', vm_, __opts__, search_global=False ) if not securitygroup: raise SaltCloudNotFound('No securitygroup ID specified for this...
[ "Return", "the", "security", "group" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L434-L451
[ "def", "get_securitygroup", "(", "vm_", ")", ":", "sgs", "=", "list_securitygroup", "(", ")", "securitygroup", "=", "config", ".", "get_cloud_config_value", "(", "'securitygroup'", ",", "vm_", ",", "__opts__", ",", "search_global", "=", "False", ")", "if", "no...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
get_size
Return the VM's size. Used by create_node().
salt/cloud/clouds/aliyun.py
def get_size(vm_): ''' Return the VM's size. Used by create_node(). ''' sizes = avail_sizes() vm_size = six.text_type(config.get_cloud_config_value( 'size', vm_, __opts__, search_global=False )) if not vm_size: raise SaltCloudNotFound('No size specified for this VM.') i...
def get_size(vm_): ''' Return the VM's size. Used by create_node(). ''' sizes = avail_sizes() vm_size = six.text_type(config.get_cloud_config_value( 'size', vm_, __opts__, search_global=False )) if not vm_size: raise SaltCloudNotFound('No size specified for this VM.') i...
[ "Return", "the", "VM", "s", "size", ".", "Used", "by", "create_node", "()", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L454-L471
[ "def", "get_size", "(", "vm_", ")", ":", "sizes", "=", "avail_sizes", "(", ")", "vm_size", "=", "six", ".", "text_type", "(", "config", ".", "get_cloud_config_value", "(", "'size'", ",", "vm_", ",", "__opts__", ",", "search_global", "=", "False", ")", ")...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
__get_location
Return the VM's location
salt/cloud/clouds/aliyun.py
def __get_location(vm_): ''' Return the VM's location ''' locations = avail_locations() vm_location = six.text_type(config.get_cloud_config_value( 'location', vm_, __opts__, search_global=False )) if not vm_location: raise SaltCloudNotFound('No location specified for this VM...
def __get_location(vm_): ''' Return the VM's location ''' locations = avail_locations() vm_location = six.text_type(config.get_cloud_config_value( 'location', vm_, __opts__, search_global=False )) if not vm_location: raise SaltCloudNotFound('No location specified for this VM...
[ "Return", "the", "VM", "s", "location" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L474-L492
[ "def", "__get_location", "(", "vm_", ")", ":", "locations", "=", "avail_locations", "(", ")", "vm_location", "=", "six", ".", "text_type", "(", "config", ".", "get_cloud_config_value", "(", "'location'", ",", "vm_", ",", "__opts__", ",", "search_global", "=", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
start
Start a node CLI Examples: .. code-block:: bash salt-cloud -a start myinstance
salt/cloud/clouds/aliyun.py
def start(name, call=None): ''' Start a node CLI Examples: .. code-block:: bash salt-cloud -a start myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or --action.' ) log.info('Starting node %s', name...
def start(name, call=None): ''' Start a node CLI Examples: .. code-block:: bash salt-cloud -a start myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or --action.' ) log.info('Starting node %s', name...
[ "Start", "a", "node" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L495-L518
[ "def", "start", "(", "name", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The stop action must be called with -a or --action.'", ")", "log", ".", "info", "(", "'Starting node %s'", ",", "name", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
stop
Stop a node CLI Examples: .. code-block:: bash salt-cloud -a stop myinstance salt-cloud -a stop myinstance force=True
salt/cloud/clouds/aliyun.py
def stop(name, force=False, call=None): ''' Stop a node CLI Examples: .. code-block:: bash salt-cloud -a stop myinstance salt-cloud -a stop myinstance force=True ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or ...
def stop(name, force=False, call=None): ''' Stop a node CLI Examples: .. code-block:: bash salt-cloud -a stop myinstance salt-cloud -a stop myinstance force=True ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or ...
[ "Stop", "a", "node" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L521-L548
[ "def", "stop", "(", "name", ",", "force", "=", "False", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The stop action must be called with -a or --action.'", ")", "log", ".", "info", "(", "'Stopp...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
reboot
Reboot a node CLI Examples: .. code-block:: bash salt-cloud -a reboot myinstance
salt/cloud/clouds/aliyun.py
def reboot(name, call=None): ''' Reboot a node CLI Examples: .. code-block:: bash salt-cloud -a reboot myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or --action.' ) log.info('Rebooting node %s', ...
def reboot(name, call=None): ''' Reboot a node CLI Examples: .. code-block:: bash salt-cloud -a reboot myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The stop action must be called with -a or --action.' ) log.info('Rebooting node %s', ...
[ "Reboot", "a", "node" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L551-L574
[ "def", "reboot", "(", "name", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The stop action must be called with -a or --action.'", ")", "log", ".", "info", "(", "'Rebooting node %s'", ",", "name", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
create_node
Convenience function to make the rest api call for node creation.
salt/cloud/clouds/aliyun.py
def create_node(kwargs): ''' Convenience function to make the rest api call for node creation. ''' if not isinstance(kwargs, dict): kwargs = {} # Required parameters params = { 'Action': 'CreateInstance', 'InstanceType': kwargs.get('size_id', ''), 'RegionId': kwa...
def create_node(kwargs): ''' Convenience function to make the rest api call for node creation. ''' if not isinstance(kwargs, dict): kwargs = {} # Required parameters params = { 'Action': 'CreateInstance', 'InstanceType': kwargs.get('size_id', ''), 'RegionId': kwa...
[ "Convenience", "function", "to", "make", "the", "rest", "api", "call", "for", "node", "creation", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L577-L608
[ "def", "create_node", "(", "kwargs", ")", ":", "if", "not", "isinstance", "(", "kwargs", ",", "dict", ")", ":", "kwargs", "=", "{", "}", "# Required parameters", "params", "=", "{", "'Action'", ":", "'CreateInstance'", ",", "'InstanceType'", ":", "kwargs", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
create
Create a single VM from a data dict
salt/cloud/clouds/aliyun.py
def create(vm_): ''' Create a single VM from a data dict ''' try: # Check for required profile parameters before sending any API calls. if vm_['profile'] and config.is_profile_configured(__opts__, __active_provider_name__ or 'ali...
def create(vm_): ''' Create a single VM from a data dict ''' try: # Check for required profile parameters before sending any API calls. if vm_['profile'] and config.is_profile_configured(__opts__, __active_provider_name__ or 'ali...
[ "Create", "a", "single", "VM", "from", "a", "data", "dict" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L611-L741
[ "def", "create", "(", "vm_", ")", ":", "try", ":", "# Check for required profile parameters before sending any API calls.", "if", "vm_", "[", "'profile'", "]", "and", "config", ".", "is_profile_configured", "(", "__opts__", ",", "__active_provider_name__", "or", "'aliyu...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
_compute_signature
Generate aliyun request signature
salt/cloud/clouds/aliyun.py
def _compute_signature(parameters, access_key_secret): ''' Generate aliyun request signature ''' def percent_encode(line): if not isinstance(line, six.string_types): return line s = line if sys.stdin.encoding is None: s = line.decode().encode('utf8') ...
def _compute_signature(parameters, access_key_secret): ''' Generate aliyun request signature ''' def percent_encode(line): if not isinstance(line, six.string_types): return line s = line if sys.stdin.encoding is None: s = line.decode().encode('utf8') ...
[ "Generate", "aliyun", "request", "signature" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L744-L776
[ "def", "_compute_signature", "(", "parameters", ",", "access_key_secret", ")", ":", "def", "percent_encode", "(", "line", ")", ":", "if", "not", "isinstance", "(", "line", ",", "six", ".", "string_types", ")", ":", "return", "line", "s", "=", "line", "if",...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
query
Make a web call to aliyun ECS REST API
salt/cloud/clouds/aliyun.py
def query(params=None): ''' Make a web call to aliyun ECS REST API ''' path = 'https://ecs-cn-hangzhou.aliyuncs.com' access_key_id = config.get_cloud_config_value( 'id', get_configured_provider(), __opts__, search_global=False ) access_key_secret = config.get_cloud_config_value( ...
def query(params=None): ''' Make a web call to aliyun ECS REST API ''' path = 'https://ecs-cn-hangzhou.aliyuncs.com' access_key_id = config.get_cloud_config_value( 'id', get_configured_provider(), __opts__, search_global=False ) access_key_secret = config.get_cloud_config_value( ...
[ "Make", "a", "web", "call", "to", "aliyun", "ECS", "REST", "API" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L779-L832
[ "def", "query", "(", "params", "=", "None", ")", ":", "path", "=", "'https://ecs-cn-hangzhou.aliyuncs.com'", "access_key_id", "=", "config", ".", "get_cloud_config_value", "(", "'id'", ",", "get_configured_provider", "(", ")", ",", "__opts__", ",", "search_global", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
show_disk
Show the disk details of the instance CLI Examples: .. code-block:: bash salt-cloud -a show_disk aliyun myinstance
salt/cloud/clouds/aliyun.py
def show_disk(name, call=None): ''' Show the disk details of the instance CLI Examples: .. code-block:: bash salt-cloud -a show_disk aliyun myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The show_disks action must be called with -a or --action.' ...
def show_disk(name, call=None): ''' Show the disk details of the instance CLI Examples: .. code-block:: bash salt-cloud -a show_disk aliyun myinstance ''' if call != 'action': raise SaltCloudSystemExit( 'The show_disks action must be called with -a or --action.' ...
[ "Show", "the", "disk", "details", "of", "the", "instance" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L850-L877
[ "def", "show_disk", "(", "name", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'action'", ":", "raise", "SaltCloudSystemExit", "(", "'The show_disks action must be called with -a or --action.'", ")", "ret", "=", "{", "}", "params", "=", "{", "'Action'...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_monitor_data
Get monitor data of the instance. If instance name is missing, will show all the instance monitor data on the region. CLI Examples: .. code-block:: bash salt-cloud -f list_monitor_data aliyun salt-cloud -f list_monitor_data aliyun name=AY14051311071990225bd
salt/cloud/clouds/aliyun.py
def list_monitor_data(kwargs=None, call=None): ''' Get monitor data of the instance. If instance name is missing, will show all the instance monitor data on the region. CLI Examples: .. code-block:: bash salt-cloud -f list_monitor_data aliyun salt-cloud -f list_monitor_data aliyun...
def list_monitor_data(kwargs=None, call=None): ''' Get monitor data of the instance. If instance name is missing, will show all the instance monitor data on the region. CLI Examples: .. code-block:: bash salt-cloud -f list_monitor_data aliyun salt-cloud -f list_monitor_data aliyun...
[ "Get", "monitor", "data", "of", "the", "instance", ".", "If", "instance", "name", "is", "missing", "will", "show", "all", "the", "instance", "monitor", "data", "on", "the", "region", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L880-L917
[ "def", "list_monitor_data", "(", "kwargs", "=", "None", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'function'", ":", "raise", "SaltCloudSystemExit", "(", "'The list_monitor_data must be called with -f or --function.'", ")", "if", "not", "isinstance", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
show_image
Show the details from aliyun image
salt/cloud/clouds/aliyun.py
def show_image(kwargs, call=None): ''' Show the details from aliyun image ''' if call != 'function': raise SaltCloudSystemExit( 'The show_images function must be called with ' '-f or --function' ) if not isinstance(kwargs, dict): kwargs = {} loca...
def show_image(kwargs, call=None): ''' Show the details from aliyun image ''' if call != 'function': raise SaltCloudSystemExit( 'The show_images function must be called with ' '-f or --function' ) if not isinstance(kwargs, dict): kwargs = {} loca...
[ "Show", "the", "details", "from", "aliyun", "image" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L950-L991
[ "def", "show_image", "(", "kwargs", ",", "call", "=", "None", ")", ":", "if", "call", "!=", "'function'", ":", "raise", "SaltCloudSystemExit", "(", "'The show_images function must be called with '", "'-f or --function'", ")", "if", "not", "isinstance", "(", "kwargs"...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
destroy
Destroy a node. CLI Example: .. code-block:: bash salt-cloud -a destroy myinstance salt-cloud -d myinstance
salt/cloud/clouds/aliyun.py
def destroy(name, call=None): ''' Destroy a node. CLI Example: .. code-block:: bash salt-cloud -a destroy myinstance salt-cloud -d myinstance ''' if call == 'function': raise SaltCloudSystemExit( 'The destroy action must be called with -d, --destroy, ' ...
def destroy(name, call=None): ''' Destroy a node. CLI Example: .. code-block:: bash salt-cloud -a destroy myinstance salt-cloud -d myinstance ''' if call == 'function': raise SaltCloudSystemExit( 'The destroy action must be called with -d, --destroy, ' ...
[ "Destroy", "a", "node", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/cloud/clouds/aliyun.py#L994-L1045
[ "def", "destroy", "(", "name", ",", "call", "=", "None", ")", ":", "if", "call", "==", "'function'", ":", "raise", "SaltCloudSystemExit", "(", "'The destroy action must be called with -d, --destroy, '", "'-a or --action.'", ")", "__utils__", "[", "'cloud.fire_event'", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
_write_adminfile
Create a temporary adminfile based on the keyword arguments passed to pkg.install.
salt/modules/solarispkg.py
def _write_adminfile(kwargs): ''' Create a temporary adminfile based on the keyword arguments passed to pkg.install. ''' # Set the adminfile default variables email = kwargs.get('email', '') instance = kwargs.get('instance', 'quit') partial = kwargs.get('partial', 'nocheck') runlevel...
def _write_adminfile(kwargs): ''' Create a temporary adminfile based on the keyword arguments passed to pkg.install. ''' # Set the adminfile default variables email = kwargs.get('email', '') instance = kwargs.get('instance', 'quit') partial = kwargs.get('partial', 'nocheck') runlevel...
[ "Create", "a", "temporary", "adminfile", "based", "on", "the", "keyword", "arguments", "passed", "to", "pkg", ".", "install", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/solarispkg.py#L42-L79
[ "def", "_write_adminfile", "(", "kwargs", ")", ":", "# Set the adminfile default variables", "email", "=", "kwargs", ".", "get", "(", "'email'", ",", "''", ")", "instance", "=", "kwargs", ".", "get", "(", "'instance'", ",", "'quit'", ")", "partial", "=", "kw...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
list_pkgs
List the packages currently installed as a dict: .. code-block:: python {'<package_name>': '<version>'} CLI Example: .. code-block:: bash salt '*' pkg.list_pkgs
salt/modules/solarispkg.py
def list_pkgs(versions_as_list=False, **kwargs): ''' List the packages currently installed as a dict: .. code-block:: python {'<package_name>': '<version>'} CLI Example: .. code-block:: bash salt '*' pkg.list_pkgs ''' versions_as_list = salt.utils.data.is_true(versions_a...
def list_pkgs(versions_as_list=False, **kwargs): ''' List the packages currently installed as a dict: .. code-block:: python {'<package_name>': '<version>'} CLI Example: .. code-block:: bash salt '*' pkg.list_pkgs ''' versions_as_list = salt.utils.data.is_true(versions_a...
[ "List", "the", "packages", "currently", "installed", "as", "a", "dict", ":" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/solarispkg.py#L82-L131
[ "def", "list_pkgs", "(", "versions_as_list", "=", "False", ",", "*", "*", "kwargs", ")", ":", "versions_as_list", "=", "salt", ".", "utils", ".", "data", ".", "is_true", "(", "versions_as_list", ")", "# not yet implemented or not applicable", "if", "any", "(", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
install
Install the passed package. Can install packages from the following sources: * Locally (package already exists on the minion * HTTP/HTTPS server * FTP server * Salt master Returns a dict containing the new package names and versions: .. code-block:: python {'<package>': {'old': '...
salt/modules/solarispkg.py
def install(name=None, sources=None, saltenv='base', **kwargs): ''' Install the passed package. Can install packages from the following sources: * Locally (package already exists on the minion * HTTP/HTTPS server * FTP server * Salt master Returns a dict containing the new package name...
def install(name=None, sources=None, saltenv='base', **kwargs): ''' Install the passed package. Can install packages from the following sources: * Locally (package already exists on the minion * HTTP/HTTPS server * FTP server * Salt master Returns a dict containing the new package name...
[ "Install", "the", "passed", "package", ".", "Can", "install", "packages", "from", "the", "following", "sources", ":" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/solarispkg.py#L201-L385
[ "def", "install", "(", "name", "=", "None", ",", "sources", "=", "None", ",", "saltenv", "=", "'base'", ",", "*", "*", "kwargs", ")", ":", "if", "salt", ".", "utils", ".", "data", ".", "is_true", "(", "kwargs", ".", "get", "(", "'refresh'", ")", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
remove
Remove packages with pkgrm name The name of the package to be deleted By default salt automatically provides an adminfile, to automate package removal, with these options set:: email= instance=quit partial=nocheck runlevel=nocheck idepend=nocheck rd...
salt/modules/solarispkg.py
def remove(name=None, pkgs=None, saltenv='base', **kwargs): ''' Remove packages with pkgrm name The name of the package to be deleted By default salt automatically provides an adminfile, to automate package removal, with these options set:: email= instance=quit par...
def remove(name=None, pkgs=None, saltenv='base', **kwargs): ''' Remove packages with pkgrm name The name of the package to be deleted By default salt automatically provides an adminfile, to automate package removal, with these options set:: email= instance=quit par...
[ "Remove", "packages", "with", "pkgrm" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/modules/solarispkg.py#L388-L488
[ "def", "remove", "(", "name", "=", "None", ",", "pkgs", "=", "None", ",", "saltenv", "=", "'base'", ",", "*", "*", "kwargs", ")", ":", "try", ":", "pkg_params", "=", "__salt__", "[", "'pkg_resource.parse_targets'", "]", "(", "name", ",", "pkgs", ")", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
present
Ensure trail exists. name The name of the state definition Name Name of the trail. S3BucketName Specifies the name of the Amazon S3 bucket designated for publishing log files. S3KeyPrefix Specifies the Amazon S3 key prefix that comes after the name of the ...
salt/states/boto_cloudtrail.py
def present(name, Name, S3BucketName, S3KeyPrefix=None, SnsTopicName=None, IncludeGlobalServiceEvents=True, IsMultiRegionTrail=None, EnableLogFileValidation=False, CloudWatchLogsLogGroupArn=None, CloudWatchLogsRoleArn=None, KmsKeyId...
def present(name, Name, S3BucketName, S3KeyPrefix=None, SnsTopicName=None, IncludeGlobalServiceEvents=True, IsMultiRegionTrail=None, EnableLogFileValidation=False, CloudWatchLogsLogGroupArn=None, CloudWatchLogsRoleArn=None, KmsKeyId...
[ "Ensure", "trail", "exists", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/boto_cloudtrail.py#L75-L315
[ "def", "present", "(", "name", ",", "Name", ",", "S3BucketName", ",", "S3KeyPrefix", "=", "None", ",", "SnsTopicName", "=", "None", ",", "IncludeGlobalServiceEvents", "=", "True", ",", "IsMultiRegionTrail", "=", "None", ",", "EnableLogFileValidation", "=", "Fals...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
absent
Ensure trail with passed properties is absent. name The name of the state definition. Name Name of the trail. region Region to connect to. key Secret key to be used. keyid Access key to be used. profile A dict with region, key and keyid, or a...
salt/states/boto_cloudtrail.py
def absent(name, Name, region=None, key=None, keyid=None, profile=None): ''' Ensure trail with passed properties is absent. name The name of the state definition. Name Name of the trail. region Region to connect to. key Secret key to be used....
def absent(name, Name, region=None, key=None, keyid=None, profile=None): ''' Ensure trail with passed properties is absent. name The name of the state definition. Name Name of the trail. region Region to connect to. key Secret key to be used....
[ "Ensure", "trail", "with", "passed", "properties", "is", "absent", "." ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/states/boto_cloudtrail.py#L318-L374
[ "def", "absent", "(", "name", ",", "Name", ",", "region", "=", "None", ",", "key", "=", "None", ",", "keyid", "=", "None", ",", "profile", "=", "None", ")", ":", "ret", "=", "{", "'name'", ":", "Name", ",", "'result'", ":", "True", ",", "'comment...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
iter_transport_opts
Yield transport, opts for all master configured transports
salt/transport/__init__.py
def iter_transport_opts(opts): ''' Yield transport, opts for all master configured transports ''' transports = set() for transport, opts_overrides in six.iteritems(opts.get('transport_opts', {})): t_opts = dict(opts) t_opts.update(opts_overrides) t_opts['transport'] = transp...
def iter_transport_opts(opts): ''' Yield transport, opts for all master configured transports ''' transports = set() for transport, opts_overrides in six.iteritems(opts.get('transport_opts', {})): t_opts = dict(opts) t_opts.update(opts_overrides) t_opts['transport'] = transp...
[ "Yield", "transport", "opts", "for", "all", "master", "configured", "transports" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/transport/__init__.py#L19-L33
[ "def", "iter_transport_opts", "(", "opts", ")", ":", "transports", "=", "set", "(", ")", "for", "transport", ",", "opts_overrides", "in", "six", ".", "iteritems", "(", "opts", ".", "get", "(", "'transport_opts'", ",", "{", "}", ")", ")", ":", "t_opts", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
gt
Only succeed if the value in the given register location is greater than the given value USAGE: .. code-block:: yaml foo: check.gt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def gt(name, value): ''' Only succeed if the value in the given register location is greater than the given value USAGE: .. code-block:: yaml foo: check.gt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
def gt(name, value): ''' Only succeed if the value in the given register location is greater than the given value USAGE: .. code-block:: yaml foo: check.gt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "greater", "than", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L17-L47
[ "def", "gt", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
gte
Only succeed if the value in the given register location is greater or equal than the given value USAGE: .. code-block:: yaml foo: check.gte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def gte(name, value): ''' Only succeed if the value in the given register location is greater or equal than the given value USAGE: .. code-block:: yaml foo: check.gte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func:...
def gte(name, value): ''' Only succeed if the value in the given register location is greater or equal than the given value USAGE: .. code-block:: yaml foo: check.gte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func:...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "greater", "or", "equal", "than", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L50-L80
[ "def", "gte", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
lt
Only succeed if the value in the given register location is less than the given value USAGE: .. code-block:: yaml foo: check.lt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def lt(name, value): ''' Only succeed if the value in the given register location is less than the given value USAGE: .. code-block:: yaml foo: check.lt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
def lt(name, value): ''' Only succeed if the value in the given register location is less than the given value USAGE: .. code-block:: yaml foo: check.lt: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "less", "than", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L83-L113
[ "def", "lt", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
lte
Only succeed if the value in the given register location is less than or equal the given value USAGE: .. code-block:: yaml foo: check.lte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def lte(name, value): ''' Only succeed if the value in the given register location is less than or equal the given value USAGE: .. code-block:: yaml foo: check.lte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: te...
def lte(name, value): ''' Only succeed if the value in the given register location is less than or equal the given value USAGE: .. code-block:: yaml foo: check.lte: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: te...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "less", "than", "or", "equal", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L116-L146
[ "def", "lte", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", ...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
eq
Only succeed if the value in the given register location is equal to the given value USAGE: .. code-block:: yaml foo: check.eq: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def eq(name, value): ''' Only succeed if the value in the given register location is equal to the given value USAGE: .. code-block:: yaml foo: check.eq: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
def eq(name, value): ''' Only succeed if the value in the given register location is equal to the given value USAGE: .. code-block:: yaml foo: check.eq: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "equal", "to", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L149-L179
[ "def", "eq", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", "...
e8541fd6e744ab0df786c0f76102e41631f45d46
train
ne
Only succeed if the value in the given register location is not equal to the given value USAGE: .. code-block:: yaml foo: check.ne: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping - require: ...
salt/thorium/check.py
def ne(name, value): ''' Only succeed if the value in the given register location is not equal to the given value USAGE: .. code-block:: yaml foo: check.ne: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
def ne(name, value): ''' Only succeed if the value in the given register location is not equal to the given value USAGE: .. code-block:: yaml foo: check.ne: - value: 42 run_remote_ex: local.cmd: - tgt: '*' - func: test.ping ...
[ "Only", "succeed", "if", "the", "value", "in", "the", "given", "register", "location", "is", "not", "equal", "to", "the", "given", "value" ]
saltstack/salt
python
https://github.com/saltstack/salt/blob/e8541fd6e744ab0df786c0f76102e41631f45d46/salt/thorium/check.py#L182-L212
[ "def", "ne", "(", "name", ",", "value", ")", ":", "ret", "=", "{", "'name'", ":", "name", ",", "'result'", ":", "False", ",", "'comment'", ":", "''", ",", "'changes'", ":", "{", "}", "}", "if", "name", "not", "in", "__reg__", ":", "ret", "[", "...
e8541fd6e744ab0df786c0f76102e41631f45d46