deploy: 90780b9cd0
|
@ -1,123 +0,0 @@
|
||||||
/* Compatability shim for jQuery and underscores.js.
|
|
||||||
*
|
|
||||||
* Copyright Sphinx contributors
|
|
||||||
* Released under the two clause BSD licence
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* small helper function to urldecode strings
|
|
||||||
*
|
|
||||||
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/decodeURIComponent#Decoding_query_parameters_from_a_URL
|
|
||||||
*/
|
|
||||||
jQuery.urldecode = function(x) {
|
|
||||||
if (!x) {
|
|
||||||
return x
|
|
||||||
}
|
|
||||||
return decodeURIComponent(x.replace(/\+/g, ' '));
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* small helper function to urlencode strings
|
|
||||||
*/
|
|
||||||
jQuery.urlencode = encodeURIComponent;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* This function returns the parsed url parameters of the
|
|
||||||
* current request. Multiple values per key are supported,
|
|
||||||
* it will always return arrays of strings for the value parts.
|
|
||||||
*/
|
|
||||||
jQuery.getQueryParameters = function(s) {
|
|
||||||
if (typeof s === 'undefined')
|
|
||||||
s = document.location.search;
|
|
||||||
var parts = s.substr(s.indexOf('?') + 1).split('&');
|
|
||||||
var result = {};
|
|
||||||
for (var i = 0; i < parts.length; i++) {
|
|
||||||
var tmp = parts[i].split('=', 2);
|
|
||||||
var key = jQuery.urldecode(tmp[0]);
|
|
||||||
var value = jQuery.urldecode(tmp[1]);
|
|
||||||
if (key in result)
|
|
||||||
result[key].push(value);
|
|
||||||
else
|
|
||||||
result[key] = [value];
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* highlight a given string on a jquery object by wrapping it in
|
|
||||||
* span elements with the given class name.
|
|
||||||
*/
|
|
||||||
jQuery.fn.highlightText = function(text, className) {
|
|
||||||
function highlight(node, addItems) {
|
|
||||||
if (node.nodeType === 3) {
|
|
||||||
var val = node.nodeValue;
|
|
||||||
var pos = val.toLowerCase().indexOf(text);
|
|
||||||
if (pos >= 0 &&
|
|
||||||
!jQuery(node.parentNode).hasClass(className) &&
|
|
||||||
!jQuery(node.parentNode).hasClass("nohighlight")) {
|
|
||||||
var span;
|
|
||||||
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
|
|
||||||
if (isInSVG) {
|
|
||||||
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
|
|
||||||
} else {
|
|
||||||
span = document.createElement("span");
|
|
||||||
span.className = className;
|
|
||||||
}
|
|
||||||
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
|
|
||||||
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
|
|
||||||
document.createTextNode(val.substr(pos + text.length)),
|
|
||||||
node.nextSibling));
|
|
||||||
node.nodeValue = val.substr(0, pos);
|
|
||||||
if (isInSVG) {
|
|
||||||
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
|
|
||||||
var bbox = node.parentElement.getBBox();
|
|
||||||
rect.x.baseVal.value = bbox.x;
|
|
||||||
rect.y.baseVal.value = bbox.y;
|
|
||||||
rect.width.baseVal.value = bbox.width;
|
|
||||||
rect.height.baseVal.value = bbox.height;
|
|
||||||
rect.setAttribute('class', className);
|
|
||||||
addItems.push({
|
|
||||||
"parent": node.parentNode,
|
|
||||||
"target": rect});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (!jQuery(node).is("button, select, textarea")) {
|
|
||||||
jQuery.each(node.childNodes, function() {
|
|
||||||
highlight(this, addItems);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
var addItems = [];
|
|
||||||
var result = this.each(function() {
|
|
||||||
highlight(this, addItems);
|
|
||||||
});
|
|
||||||
for (var i = 0; i < addItems.length; ++i) {
|
|
||||||
jQuery(addItems[i].parent).before(addItems[i].target);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
};
|
|
||||||
|
|
||||||
/*
|
|
||||||
* backward compatibility for jQuery.browser
|
|
||||||
* This will be supported until firefox bug is fixed.
|
|
||||||
*/
|
|
||||||
if (!jQuery.browser) {
|
|
||||||
jQuery.uaMatch = function(ua) {
|
|
||||||
ua = ua.toLowerCase();
|
|
||||||
|
|
||||||
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
|
|
||||||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
|
|
||||||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
|
|
||||||
/(msie) ([\w.]+)/.exec(ua) ||
|
|
||||||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
|
|
||||||
[];
|
|
||||||
|
|
||||||
return {
|
|
||||||
browser: match[ 1 ] || "",
|
|
||||||
version: match[ 2 ] || "0"
|
|
||||||
};
|
|
||||||
};
|
|
||||||
jQuery.browser = {};
|
|
||||||
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
|
|
||||||
}
|
|
|
@ -1,906 +0,0 @@
|
||||||
/*
|
|
||||||
* Sphinx stylesheet -- basic theme.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/* -- main layout ----------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.clearer {
|
|
||||||
clear: both;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.section::after {
|
|
||||||
display: block;
|
|
||||||
content: '';
|
|
||||||
clear: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- relbar ---------------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.related {
|
|
||||||
width: 100%;
|
|
||||||
font-size: 90%;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.related h3 {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.related ul {
|
|
||||||
margin: 0;
|
|
||||||
padding: 0 0 0 10px;
|
|
||||||
list-style: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.related li {
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.related li.right {
|
|
||||||
float: right;
|
|
||||||
margin-right: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- sidebar --------------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.sphinxsidebarwrapper {
|
|
||||||
padding: 10px 5px 0 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar {
|
|
||||||
float: left;
|
|
||||||
width: 230px;
|
|
||||||
margin-left: -100%;
|
|
||||||
font-size: 90%;
|
|
||||||
word-wrap: break-word;
|
|
||||||
overflow-wrap : break-word;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar ul {
|
|
||||||
list-style: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar ul ul,
|
|
||||||
div.sphinxsidebar ul.want-points {
|
|
||||||
margin-left: 20px;
|
|
||||||
list-style: square;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar ul ul {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar form {
|
|
||||||
margin-top: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar input {
|
|
||||||
border: 1px solid #98dbcc;
|
|
||||||
font-family: sans-serif;
|
|
||||||
font-size: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar #searchbox form.search {
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar #searchbox input[type="text"] {
|
|
||||||
float: left;
|
|
||||||
width: 80%;
|
|
||||||
padding: 0.25em;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar #searchbox input[type="submit"] {
|
|
||||||
float: left;
|
|
||||||
width: 20%;
|
|
||||||
border-left: none;
|
|
||||||
padding: 0.25em;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
img {
|
|
||||||
border: 0;
|
|
||||||
max-width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- search page ----------------------------------------------------------- */
|
|
||||||
|
|
||||||
ul.search {
|
|
||||||
margin-top: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul.search li {
|
|
||||||
padding: 5px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul.search li a {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul.search li p.context {
|
|
||||||
color: #888;
|
|
||||||
margin: 2px 0 0 30px;
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
ul.keywordmatches li.goodmatch a {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- index page ------------------------------------------------------------ */
|
|
||||||
|
|
||||||
table.contentstable {
|
|
||||||
width: 90%;
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.contentstable p.biglink {
|
|
||||||
line-height: 150%;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.biglink {
|
|
||||||
font-size: 1.3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.linkdescr {
|
|
||||||
font-style: italic;
|
|
||||||
padding-top: 5px;
|
|
||||||
font-size: 90%;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- general index --------------------------------------------------------- */
|
|
||||||
|
|
||||||
table.indextable {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.indextable td {
|
|
||||||
text-align: left;
|
|
||||||
vertical-align: top;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.indextable ul {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0;
|
|
||||||
list-style-type: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.indextable > tbody > tr > td > ul {
|
|
||||||
padding-left: 0em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.indextable tr.pcap {
|
|
||||||
height: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.indextable tr.cap {
|
|
||||||
margin-top: 10px;
|
|
||||||
background-color: #f2f2f2;
|
|
||||||
}
|
|
||||||
|
|
||||||
img.toggler {
|
|
||||||
margin-right: 3px;
|
|
||||||
margin-top: 3px;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.modindex-jumpbox {
|
|
||||||
border-top: 1px solid #ddd;
|
|
||||||
border-bottom: 1px solid #ddd;
|
|
||||||
margin: 1em 0 1em 0;
|
|
||||||
padding: 0.4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.genindex-jumpbox {
|
|
||||||
border-top: 1px solid #ddd;
|
|
||||||
border-bottom: 1px solid #ddd;
|
|
||||||
margin: 1em 0 1em 0;
|
|
||||||
padding: 0.4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- domain module index --------------------------------------------------- */
|
|
||||||
|
|
||||||
table.modindextable td {
|
|
||||||
padding: 2px;
|
|
||||||
border-collapse: collapse;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- general body styles --------------------------------------------------- */
|
|
||||||
|
|
||||||
div.body {
|
|
||||||
min-width: 360px;
|
|
||||||
max-width: 800px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.body p, div.body dd, div.body li, div.body blockquote {
|
|
||||||
-moz-hyphens: auto;
|
|
||||||
-ms-hyphens: auto;
|
|
||||||
-webkit-hyphens: auto;
|
|
||||||
hyphens: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.headerlink {
|
|
||||||
visibility: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:visited {
|
|
||||||
color: #551A8B;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1:hover > a.headerlink,
|
|
||||||
h2:hover > a.headerlink,
|
|
||||||
h3:hover > a.headerlink,
|
|
||||||
h4:hover > a.headerlink,
|
|
||||||
h5:hover > a.headerlink,
|
|
||||||
h6:hover > a.headerlink,
|
|
||||||
dt:hover > a.headerlink,
|
|
||||||
caption:hover > a.headerlink,
|
|
||||||
p.caption:hover > a.headerlink,
|
|
||||||
div.code-block-caption:hover > a.headerlink {
|
|
||||||
visibility: visible;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.body p.caption {
|
|
||||||
text-align: inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.body td {
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
.first {
|
|
||||||
margin-top: 0 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.rubric {
|
|
||||||
margin-top: 30px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
img.align-left, figure.align-left, .figure.align-left, object.align-left {
|
|
||||||
clear: left;
|
|
||||||
float: left;
|
|
||||||
margin-right: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
img.align-right, figure.align-right, .figure.align-right, object.align-right {
|
|
||||||
clear: right;
|
|
||||||
float: right;
|
|
||||||
margin-left: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
img.align-center, figure.align-center, .figure.align-center, object.align-center {
|
|
||||||
display: block;
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
img.align-default, figure.align-default, .figure.align-default {
|
|
||||||
display: block;
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.align-left {
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
.align-center {
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.align-default {
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.align-right {
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- sidebars -------------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.sidebar,
|
|
||||||
aside.sidebar {
|
|
||||||
margin: 0 0 0.5em 1em;
|
|
||||||
border: 1px solid #ddb;
|
|
||||||
padding: 7px;
|
|
||||||
background-color: #ffe;
|
|
||||||
width: 40%;
|
|
||||||
float: right;
|
|
||||||
clear: right;
|
|
||||||
overflow-x: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.sidebar-title {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
nav.contents,
|
|
||||||
aside.topic,
|
|
||||||
div.admonition, div.topic, blockquote {
|
|
||||||
clear: left;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- topics ---------------------------------------------------------------- */
|
|
||||||
|
|
||||||
nav.contents,
|
|
||||||
aside.topic,
|
|
||||||
div.topic {
|
|
||||||
border: 1px solid #ccc;
|
|
||||||
padding: 7px;
|
|
||||||
margin: 10px 0 10px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.topic-title {
|
|
||||||
font-size: 1.1em;
|
|
||||||
font-weight: bold;
|
|
||||||
margin-top: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- admonitions ----------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.admonition {
|
|
||||||
margin-top: 10px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
padding: 7px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.admonition dt {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
p.admonition-title {
|
|
||||||
margin: 0px 10px 5px 0px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.body p.centered {
|
|
||||||
text-align: center;
|
|
||||||
margin-top: 25px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- content of sidebars/topics/admonitions -------------------------------- */
|
|
||||||
|
|
||||||
div.sidebar > :last-child,
|
|
||||||
aside.sidebar > :last-child,
|
|
||||||
nav.contents > :last-child,
|
|
||||||
aside.topic > :last-child,
|
|
||||||
div.topic > :last-child,
|
|
||||||
div.admonition > :last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sidebar::after,
|
|
||||||
aside.sidebar::after,
|
|
||||||
nav.contents::after,
|
|
||||||
aside.topic::after,
|
|
||||||
div.topic::after,
|
|
||||||
div.admonition::after,
|
|
||||||
blockquote::after {
|
|
||||||
display: block;
|
|
||||||
content: '';
|
|
||||||
clear: both;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- tables ---------------------------------------------------------------- */
|
|
||||||
|
|
||||||
table.docutils {
|
|
||||||
margin-top: 10px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
border: 0;
|
|
||||||
border-collapse: collapse;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.align-center {
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.align-default {
|
|
||||||
margin-left: auto;
|
|
||||||
margin-right: auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
table caption span.caption-number {
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
table caption span.caption-text {
|
|
||||||
}
|
|
||||||
|
|
||||||
table.docutils td, table.docutils th {
|
|
||||||
padding: 1px 8px 1px 5px;
|
|
||||||
border-top: 0;
|
|
||||||
border-left: 0;
|
|
||||||
border-right: 0;
|
|
||||||
border-bottom: 1px solid #aaa;
|
|
||||||
}
|
|
||||||
|
|
||||||
th {
|
|
||||||
text-align: left;
|
|
||||||
padding-right: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.citation {
|
|
||||||
border-left: solid 1px gray;
|
|
||||||
margin-left: 1px;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.citation td {
|
|
||||||
border-bottom: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
th > :first-child,
|
|
||||||
td > :first-child {
|
|
||||||
margin-top: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
th > :last-child,
|
|
||||||
td > :last-child {
|
|
||||||
margin-bottom: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- figures --------------------------------------------------------------- */
|
|
||||||
|
|
||||||
div.figure, figure {
|
|
||||||
margin: 0.5em;
|
|
||||||
padding: 0.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.figure p.caption, figcaption {
|
|
||||||
padding: 0.3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.figure p.caption span.caption-number,
|
|
||||||
figcaption span.caption-number {
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.figure p.caption span.caption-text,
|
|
||||||
figcaption span.caption-text {
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- field list styles ----------------------------------------------------- */
|
|
||||||
|
|
||||||
table.field-list td, table.field-list th {
|
|
||||||
border: 0 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.field-list ul {
|
|
||||||
margin: 0;
|
|
||||||
padding-left: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.field-list p {
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.field-name {
|
|
||||||
-moz-hyphens: manual;
|
|
||||||
-ms-hyphens: manual;
|
|
||||||
-webkit-hyphens: manual;
|
|
||||||
hyphens: manual;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- hlist styles ---------------------------------------------------------- */
|
|
||||||
|
|
||||||
table.hlist {
|
|
||||||
margin: 1em 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.hlist td {
|
|
||||||
vertical-align: top;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- object description styles --------------------------------------------- */
|
|
||||||
|
|
||||||
.sig {
|
|
||||||
font-family: 'Consolas', 'Menlo', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', monospace;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig-name, code.descname {
|
|
||||||
background-color: transparent;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig-name {
|
|
||||||
font-size: 1.1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
code.descname {
|
|
||||||
font-size: 1.2em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig-prename, code.descclassname {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.optional {
|
|
||||||
font-size: 1.3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig-paren {
|
|
||||||
font-size: larger;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig-param.n {
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* C++ specific styling */
|
|
||||||
|
|
||||||
.sig-inline.c-texpr,
|
|
||||||
.sig-inline.cpp-texpr {
|
|
||||||
font-family: unset;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig.c .k, .sig.c .kt,
|
|
||||||
.sig.cpp .k, .sig.cpp .kt {
|
|
||||||
color: #0033B3;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig.c .m,
|
|
||||||
.sig.cpp .m {
|
|
||||||
color: #1750EB;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig.c .s, .sig.c .sc,
|
|
||||||
.sig.cpp .s, .sig.cpp .sc {
|
|
||||||
color: #067D17;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/* -- other body styles ----------------------------------------------------- */
|
|
||||||
|
|
||||||
ol.arabic {
|
|
||||||
list-style: decimal;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.loweralpha {
|
|
||||||
list-style: lower-alpha;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.upperalpha {
|
|
||||||
list-style: upper-alpha;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.lowerroman {
|
|
||||||
list-style: lower-roman;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.upperroman {
|
|
||||||
list-style: upper-roman;
|
|
||||||
}
|
|
||||||
|
|
||||||
:not(li) > ol > li:first-child > :first-child,
|
|
||||||
:not(li) > ul > li:first-child > :first-child {
|
|
||||||
margin-top: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
:not(li) > ol > li:last-child > :last-child,
|
|
||||||
:not(li) > ul > li:last-child > :last-child {
|
|
||||||
margin-bottom: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.simple ol p,
|
|
||||||
ol.simple ul p,
|
|
||||||
ul.simple ol p,
|
|
||||||
ul.simple ul p {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.simple > li:not(:first-child) > p,
|
|
||||||
ul.simple > li:not(:first-child) > p {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
ol.simple p,
|
|
||||||
ul.simple p {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
aside.footnote > span,
|
|
||||||
div.citation > span {
|
|
||||||
float: left;
|
|
||||||
}
|
|
||||||
aside.footnote > span:last-of-type,
|
|
||||||
div.citation > span:last-of-type {
|
|
||||||
padding-right: 0.5em;
|
|
||||||
}
|
|
||||||
aside.footnote > p {
|
|
||||||
margin-left: 2em;
|
|
||||||
}
|
|
||||||
div.citation > p {
|
|
||||||
margin-left: 4em;
|
|
||||||
}
|
|
||||||
aside.footnote > p:last-of-type,
|
|
||||||
div.citation > p:last-of-type {
|
|
||||||
margin-bottom: 0em;
|
|
||||||
}
|
|
||||||
aside.footnote > p:last-of-type:after,
|
|
||||||
div.citation > p:last-of-type:after {
|
|
||||||
content: "";
|
|
||||||
clear: both;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.field-list {
|
|
||||||
display: grid;
|
|
||||||
grid-template-columns: fit-content(30%) auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.field-list > dt {
|
|
||||||
font-weight: bold;
|
|
||||||
word-break: break-word;
|
|
||||||
padding-left: 0.5em;
|
|
||||||
padding-right: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.field-list > dd {
|
|
||||||
padding-left: 0.5em;
|
|
||||||
margin-top: 0em;
|
|
||||||
margin-left: 0em;
|
|
||||||
margin-bottom: 0em;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl {
|
|
||||||
margin-bottom: 15px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dd > :first-child {
|
|
||||||
margin-top: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dd ul, dd table {
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dd {
|
|
||||||
margin-top: 3px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
margin-left: 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig dd {
|
|
||||||
margin-top: 0px;
|
|
||||||
margin-bottom: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.sig dl {
|
|
||||||
margin-top: 0px;
|
|
||||||
margin-bottom: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl > dd:last-child,
|
|
||||||
dl > dd:last-child > :last-child {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
dt:target, span.highlighted {
|
|
||||||
background-color: #fbe54e;
|
|
||||||
}
|
|
||||||
|
|
||||||
rect.highlighted {
|
|
||||||
fill: #fbe54e;
|
|
||||||
}
|
|
||||||
|
|
||||||
dl.glossary dt {
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 1.1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.versionmodified {
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
.system-message {
|
|
||||||
background-color: #fda;
|
|
||||||
padding: 5px;
|
|
||||||
border: 3px solid red;
|
|
||||||
}
|
|
||||||
|
|
||||||
.footnote:target {
|
|
||||||
background-color: #ffa;
|
|
||||||
}
|
|
||||||
|
|
||||||
.line-block {
|
|
||||||
display: block;
|
|
||||||
margin-top: 1em;
|
|
||||||
margin-bottom: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.line-block .line-block {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0;
|
|
||||||
margin-left: 1.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.guilabel, .menuselection {
|
|
||||||
font-family: sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
.accelerator {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
.classifier {
|
|
||||||
font-style: oblique;
|
|
||||||
}
|
|
||||||
|
|
||||||
.classifier:before {
|
|
||||||
font-style: normal;
|
|
||||||
margin: 0 0.5em;
|
|
||||||
content: ":";
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
|
|
||||||
abbr, acronym {
|
|
||||||
border-bottom: dotted 1px;
|
|
||||||
cursor: help;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- code displays --------------------------------------------------------- */
|
|
||||||
|
|
||||||
pre {
|
|
||||||
overflow: auto;
|
|
||||||
overflow-y: hidden; /* fixes display issues on Chrome browsers */
|
|
||||||
}
|
|
||||||
|
|
||||||
pre, div[class*="highlight-"] {
|
|
||||||
clear: both;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.pre {
|
|
||||||
-moz-hyphens: none;
|
|
||||||
-ms-hyphens: none;
|
|
||||||
-webkit-hyphens: none;
|
|
||||||
hyphens: none;
|
|
||||||
white-space: nowrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
div[class*="highlight-"] {
|
|
||||||
margin: 1em 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
td.linenos pre {
|
|
||||||
border: 0;
|
|
||||||
background-color: transparent;
|
|
||||||
color: #aaa;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable tbody {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable tr {
|
|
||||||
display: flex;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable td {
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable td.linenos {
|
|
||||||
padding-right: 0.5em;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable td.code {
|
|
||||||
flex: 1;
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.highlight .hll {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.highlight pre,
|
|
||||||
table.highlighttable pre {
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.code-block-caption + div {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.code-block-caption {
|
|
||||||
margin-top: 1em;
|
|
||||||
padding: 2px 5px;
|
|
||||||
font-size: small;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.code-block-caption code {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
table.highlighttable td.linenos,
|
|
||||||
span.linenos,
|
|
||||||
div.highlight span.gp { /* gp: Generic.Prompt */
|
|
||||||
user-select: none;
|
|
||||||
-webkit-user-select: text; /* Safari fallback only */
|
|
||||||
-webkit-user-select: none; /* Chrome/Safari */
|
|
||||||
-moz-user-select: none; /* Firefox */
|
|
||||||
-ms-user-select: none; /* IE10+ */
|
|
||||||
}
|
|
||||||
|
|
||||||
div.code-block-caption span.caption-number {
|
|
||||||
padding: 0.1em 0.3em;
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.code-block-caption span.caption-text {
|
|
||||||
}
|
|
||||||
|
|
||||||
div.literal-block-wrapper {
|
|
||||||
margin: 1em 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
code.xref, a code {
|
|
||||||
background-color: transparent;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.viewcode-link {
|
|
||||||
float: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.viewcode-back {
|
|
||||||
float: right;
|
|
||||||
font-family: sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.viewcode-block:target {
|
|
||||||
margin: -1px -10px;
|
|
||||||
padding: 0 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- math display ---------------------------------------------------------- */
|
|
||||||
|
|
||||||
img.math {
|
|
||||||
vertical-align: middle;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.body div.math p {
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.eqno {
|
|
||||||
float: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.eqno a.headerlink {
|
|
||||||
position: absolute;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.math:hover a.headerlink {
|
|
||||||
visibility: visible;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* -- printout stylesheet --------------------------------------------------- */
|
|
||||||
|
|
||||||
@media print {
|
|
||||||
div.document,
|
|
||||||
div.documentwrapper,
|
|
||||||
div.bodywrapper {
|
|
||||||
margin: 0 !important;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.sphinxsidebar,
|
|
||||||
div.related,
|
|
||||||
div.footer,
|
|
||||||
#top-link {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,491 +0,0 @@
|
||||||
@import 'theme.css';
|
|
||||||
/*! minified with http://css-minify.online-domain-tools.com/ - all comments
|
|
||||||
* must have ! to preserve during minifying with that tool */
|
|
||||||
/*! Fix for read the docs theme:
|
|
||||||
* https://rackerlabs.github.io/docs-rackspace/tools/rtd-tables.html
|
|
||||||
*/
|
|
||||||
/*! override table width restrictions */
|
|
||||||
@media screen and (min-width: 767px) {
|
|
||||||
/*! If we ever publish to read the docs, we need to use !important for
|
|
||||||
* these two styles as read the docs itself loads their theme in a way that
|
|
||||||
* we can't otherwise override it.
|
|
||||||
*/
|
|
||||||
.wy-table-responsive table td {
|
|
||||||
white-space: normal;
|
|
||||||
}
|
|
||||||
.wy-table-responsive {
|
|
||||||
overflow: visible;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/*!
|
|
||||||
* We use the class documentation-table for attribute tables where the first
|
|
||||||
* column is the name of an attribute and the second column is the description.
|
|
||||||
*/
|
|
||||||
/*! These tables look like this:
|
|
||||||
*
|
|
||||||
* Attribute Name Description
|
|
||||||
* -------------- -----------
|
|
||||||
* **NAME** This is a multi-line description
|
|
||||||
* str/required that can span multiple lines
|
|
||||||
* added in x.y
|
|
||||||
* With multiple paragraphs
|
|
||||||
* -------------- -----------
|
|
||||||
*
|
|
||||||
* **NAME** is given the class .value-name
|
|
||||||
* str is given the class .value-type
|
|
||||||
* / is given the class .value-separator
|
|
||||||
* required is given the class .value-required
|
|
||||||
* added in x.y is given the class .value-added-in
|
|
||||||
*/
|
|
||||||
/*! The extra .rst-content is so this will override rtd theme */
|
|
||||||
.rst-content table.documentation-table td {
|
|
||||||
vertical-align: top;
|
|
||||||
}
|
|
||||||
table.documentation-table td:first-child {
|
|
||||||
white-space: nowrap;
|
|
||||||
vertical-align: top;
|
|
||||||
}
|
|
||||||
table.documentation-table td:first-child p:first-child {
|
|
||||||
font-weight: 700;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
/*! This is now redundant with above position-based styling */
|
|
||||||
/*!
|
|
||||||
table.documentation-table .value-name {
|
|
||||||
font-weight: bold;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
table.documentation-table .value-type {
|
|
||||||
font-size: x-small;
|
|
||||||
color: purple;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
table.documentation-table .value-separator {
|
|
||||||
font-size: x-small;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
table.documentation-table .value-required {
|
|
||||||
font-size: x-small;
|
|
||||||
color: red;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
.value-added-in {
|
|
||||||
font-size: x-small;
|
|
||||||
font-style: italic;
|
|
||||||
color: green;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
/*! Ansible-specific CSS pulled out of rtd theme for 2.9 */
|
|
||||||
.DocSiteProduct-header {
|
|
||||||
flex: 1;
|
|
||||||
-webkit-flex: 1;
|
|
||||||
padding: 10px 20px 20px;
|
|
||||||
display: flex;
|
|
||||||
display: -webkit-flex;
|
|
||||||
flex-direction: column;
|
|
||||||
-webkit-flex-direction: column;
|
|
||||||
align-items: center;
|
|
||||||
-webkit-align-items: center;
|
|
||||||
justify-content: flex-start;
|
|
||||||
-webkit-justify-content: flex-start;
|
|
||||||
margin-left: 20px;
|
|
||||||
margin-right: 20px;
|
|
||||||
text-decoration: none;
|
|
||||||
font-weight: 400;
|
|
||||||
font-family: "Open Sans", sans-serif;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-header:active,
|
|
||||||
.DocSiteProduct-header:focus,
|
|
||||||
.DocSiteProduct-header:visited {
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-header--core {
|
|
||||||
font-size: 25px;
|
|
||||||
background-color: #5bbdbf;
|
|
||||||
border: 2px solid #5bbdbf;
|
|
||||||
border-top-left-radius: 4px;
|
|
||||||
border-top-right-radius: 4px;
|
|
||||||
color: #fff;
|
|
||||||
padding-left: 2px;
|
|
||||||
margin-left: 2px;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-headerAlign {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-logo {
|
|
||||||
width: 60px;
|
|
||||||
height: 60px;
|
|
||||||
margin-bottom: -9px;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-logoText {
|
|
||||||
margin-top: 6px;
|
|
||||||
font-size: 25px;
|
|
||||||
text-align: left;
|
|
||||||
}
|
|
||||||
.DocSiteProduct-CheckVersionPara {
|
|
||||||
margin-left: 2px;
|
|
||||||
padding-bottom: 4px;
|
|
||||||
margin-right: 2px;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
/*! Ansible color scheme */
|
|
||||||
.wy-nav-top,
|
|
||||||
.wy-side-nav-search {
|
|
||||||
background-color: #5bbdbf;
|
|
||||||
}
|
|
||||||
.wy-menu-vertical header,
|
|
||||||
.wy-menu-vertical p.caption {
|
|
||||||
color: #5bbdbf;
|
|
||||||
}
|
|
||||||
.wy-menu-vertical a {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
.wy-menu-vertical a.reference.internal {
|
|
||||||
padding: 0.4045em 1.618em;
|
|
||||||
}
|
|
||||||
/*! Override sphinx rtd theme max-with of 800px */
|
|
||||||
.wy-nav-content {
|
|
||||||
max-width: 100%;
|
|
||||||
}
|
|
||||||
/*!
|
|
||||||
* Override sphinx_rtd_theme - keeps left-nav from overwriting
|
|
||||||
* Documentation title
|
|
||||||
**/
|
|
||||||
.wy-nav-side {
|
|
||||||
top: 45px;
|
|
||||||
}
|
|
||||||
/*!
|
|
||||||
* Ansible - changed absolute to relative to remove extraneous side scroll bar
|
|
||||||
**/
|
|
||||||
.wy-grid-for-nav {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
/*! Ansible narrow the search box */
|
|
||||||
.wy-side-nav-search input[type="text"] {
|
|
||||||
width: 90%;
|
|
||||||
padding-left: 24px;
|
|
||||||
}
|
|
||||||
/*! Ansible - remove so highlight indenting is correct */
|
|
||||||
.rst-content .highlighted {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
.DocSiteBanner {
|
|
||||||
display: flex;
|
|
||||||
display: -webkit-flex;
|
|
||||||
justify-content: center;
|
|
||||||
-webkit-justify-content: center;
|
|
||||||
flex-wrap: wrap;
|
|
||||||
-webkit-flex-wrap: wrap;
|
|
||||||
margin-bottom: 25px;
|
|
||||||
}
|
|
||||||
.DocSiteBanner-imgWrapper {
|
|
||||||
max-width: 100%;
|
|
||||||
}
|
|
||||||
td,
|
|
||||||
th {
|
|
||||||
min-width: 100px;
|
|
||||||
}
|
|
||||||
table {
|
|
||||||
overflow-x: auto;
|
|
||||||
max-width: 100%;
|
|
||||||
}
|
|
||||||
.documentation-table td,
|
|
||||||
.documentation-table th {
|
|
||||||
padding: 4px;
|
|
||||||
border-left: 1px solid #000;
|
|
||||||
border-top: 1px solid #000;
|
|
||||||
}
|
|
||||||
.documentation-table {
|
|
||||||
border-right: 1px solid #000;
|
|
||||||
border-bottom: 1px solid #000;
|
|
||||||
}
|
|
||||||
@media print {
|
|
||||||
* {
|
|
||||||
background: 0 0 !important;
|
|
||||||
color: #000 !important;
|
|
||||||
text-shadow: none !important;
|
|
||||||
filter: none !important;
|
|
||||||
-ms-filter: none !important;
|
|
||||||
}
|
|
||||||
#nav,
|
|
||||||
a,
|
|
||||||
a:visited {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
a[href]:after {
|
|
||||||
content: " (" attr(href) ")";
|
|
||||||
}
|
|
||||||
abbr[title]:after {
|
|
||||||
content: " (" attr(title) ")";
|
|
||||||
}
|
|
||||||
.ir a:after,
|
|
||||||
a[href^="javascript:"]:after,
|
|
||||||
a[href^="#"]:after {
|
|
||||||
content: "";
|
|
||||||
}
|
|
||||||
/*! Don't show links for images, or javascript/internal links */
|
|
||||||
pre,
|
|
||||||
blockquote {
|
|
||||||
border: 0 solid #999;
|
|
||||||
page-break-inside: avoid;
|
|
||||||
}
|
|
||||||
thead {
|
|
||||||
display: table-header-group;
|
|
||||||
}
|
|
||||||
/*! h5bp.com/t */
|
|
||||||
tr,
|
|
||||||
img {
|
|
||||||
page-break-inside: avoid;
|
|
||||||
}
|
|
||||||
img {
|
|
||||||
max-width: 100% !important;
|
|
||||||
}
|
|
||||||
@page {
|
|
||||||
margin: 0.5cm;
|
|
||||||
}
|
|
||||||
h2,
|
|
||||||
h3,
|
|
||||||
p {
|
|
||||||
orphans: 3;
|
|
||||||
widows: 3;
|
|
||||||
}
|
|
||||||
h2,
|
|
||||||
h3 {
|
|
||||||
page-break-after: avoid;
|
|
||||||
}
|
|
||||||
#google_image_div,
|
|
||||||
.DocSiteBanner {
|
|
||||||
display: none !important;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#sideBanner,
|
|
||||||
.DocSite-globalNav {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
.DocSite-sideNav {
|
|
||||||
display: block;
|
|
||||||
margin-bottom: 40px;
|
|
||||||
}
|
|
||||||
.DocSite-nav {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
.ansibleNav {
|
|
||||||
background: #000;
|
|
||||||
padding: 0 20px;
|
|
||||||
width: auto;
|
|
||||||
border-bottom: 1px solid #444;
|
|
||||||
font-size: 14px;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
.ansibleNav ul {
|
|
||||||
list-style: none;
|
|
||||||
padding-left: 0;
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li {
|
|
||||||
padding: 7px 0;
|
|
||||||
border-bottom: 1px solid #444;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li:last-child {
|
|
||||||
border: none;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li a {
|
|
||||||
color: #fff;
|
|
||||||
text-decoration: none;
|
|
||||||
text-transform: uppercase;
|
|
||||||
padding: 6px 0;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li a:hover {
|
|
||||||
color: #5bbdbf;
|
|
||||||
background: 0 0;
|
|
||||||
}
|
|
||||||
h4 {
|
|
||||||
font-size: 105%;
|
|
||||||
}
|
|
||||||
h5 {
|
|
||||||
font-size: 90%;
|
|
||||||
}
|
|
||||||
h6 {
|
|
||||||
font-size: 80%;
|
|
||||||
}
|
|
||||||
@media screen and (min-width: 768px) {
|
|
||||||
.DocSite-globalNav {
|
|
||||||
display: block;
|
|
||||||
position: fixed;
|
|
||||||
}
|
|
||||||
#sideBanner {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
.DocSite-sideNav {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
.DocSite-nav {
|
|
||||||
flex: initial;
|
|
||||||
-webkit-flex: initial;
|
|
||||||
display: flex;
|
|
||||||
display: -webkit-flex;
|
|
||||||
flex-direction: row;
|
|
||||||
-webkit-flex-direction: row;
|
|
||||||
justify-content: flex-start;
|
|
||||||
-webkit-justify-content: flex-start;
|
|
||||||
padding: 15px;
|
|
||||||
background-color: #000;
|
|
||||||
text-decoration: none;
|
|
||||||
font-family: "Open Sans", sans-serif;
|
|
||||||
}
|
|
||||||
.DocSiteNav-logo {
|
|
||||||
width: 28px;
|
|
||||||
height: 28px;
|
|
||||||
margin-right: 8px;
|
|
||||||
margin-top: -6px;
|
|
||||||
position: fixed;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
.DocSiteNav-title {
|
|
||||||
color: #fff;
|
|
||||||
font-size: 20px;
|
|
||||||
position: fixed;
|
|
||||||
margin-left: 40px;
|
|
||||||
margin-top: -4px;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
.ansibleNav {
|
|
||||||
height: 45px;
|
|
||||||
width: 100%;
|
|
||||||
font-size: 13px;
|
|
||||||
padding: 0 60px 0 0;
|
|
||||||
}
|
|
||||||
.ansibleNav ul {
|
|
||||||
float: right;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: nowrap;
|
|
||||||
margin-top: 13px;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li {
|
|
||||||
padding: 0;
|
|
||||||
border-bottom: none;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li a {
|
|
||||||
color: #fff;
|
|
||||||
text-decoration: none;
|
|
||||||
text-transform: uppercase;
|
|
||||||
padding: 8px 13px;
|
|
||||||
}
|
|
||||||
h4 {
|
|
||||||
font-size: 105%;
|
|
||||||
}
|
|
||||||
h5 {
|
|
||||||
font-size: 90%;
|
|
||||||
}
|
|
||||||
h6 {
|
|
||||||
font-size: 80%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@media screen and (min-width: 768px) {
|
|
||||||
#sideBanner,
|
|
||||||
.DocSite-globalNav {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
.DocSite-sideNav {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
.DocSite-nav {
|
|
||||||
flex: initial;
|
|
||||||
-webkit-flex: initial;
|
|
||||||
display: flex;
|
|
||||||
display: -webkit-flex;
|
|
||||||
flex-direction: row;
|
|
||||||
-webkit-flex-direction: row;
|
|
||||||
justify-content: flex-start;
|
|
||||||
-webkit-justify-content: flex-start;
|
|
||||||
padding: 15px;
|
|
||||||
background-color: #000;
|
|
||||||
text-decoration: none;
|
|
||||||
font-family: "Open Sans", sans-serif;
|
|
||||||
}
|
|
||||||
.DocSiteNav-logo {
|
|
||||||
width: 28px;
|
|
||||||
height: 28px;
|
|
||||||
margin-right: 8px;
|
|
||||||
margin-top: -6px;
|
|
||||||
position: fixed;
|
|
||||||
}
|
|
||||||
.DocSiteNav-title {
|
|
||||||
color: #fff;
|
|
||||||
font-size: 20px;
|
|
||||||
position: fixed;
|
|
||||||
margin-left: 40px;
|
|
||||||
margin-top: -4px;
|
|
||||||
}
|
|
||||||
.ansibleNav {
|
|
||||||
height: 45px;
|
|
||||||
font-size: 13px;
|
|
||||||
padding: 0 60px 0 0;
|
|
||||||
}
|
|
||||||
.ansibleNav ul {
|
|
||||||
float: right;
|
|
||||||
display: flex;
|
|
||||||
flex-wrap: nowrap;
|
|
||||||
margin-top: 13px;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li {
|
|
||||||
padding: 0;
|
|
||||||
border-bottom: none;
|
|
||||||
}
|
|
||||||
.ansibleNav ul li a {
|
|
||||||
color: #fff;
|
|
||||||
text-decoration: none;
|
|
||||||
text-transform: uppercase;
|
|
||||||
padding: 8px 13px;
|
|
||||||
}
|
|
||||||
h4 {
|
|
||||||
font-size: 105%;
|
|
||||||
}
|
|
||||||
h5 {
|
|
||||||
font-size: 90%;
|
|
||||||
}
|
|
||||||
h6 {
|
|
||||||
font-size: 80%;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/* ansibleOptionLink is adapted from h1 .headerlink in sphinx_rtd_theme */
|
|
||||||
/* This definition lives in the antsibull Sphinx extension; we update it here to use the icon from FontAwesome */
|
|
||||||
/* https://github.com/ansible-community/antsibull-docs/blob/main/src/sphinx_antsibull_ext/css/antsibull-minimal.scss */
|
|
||||||
tr .ansibleOptionLink::after {
|
|
||||||
content: "" !important;
|
|
||||||
font-family: FontAwesome;
|
|
||||||
}
|
|
||||||
tr .ansibleOptionLink {
|
|
||||||
font: normal normal normal 14px/1 FontAwesome;
|
|
||||||
text-rendering: auto;
|
|
||||||
-webkit-font-smoothing: antialiased;
|
|
||||||
-moz-osx-font-smoothing: grayscale;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media screen and (min-width: 767px) {
|
|
||||||
/* Move anchors a bit up so that they aren't hidden by the header bar */
|
|
||||||
section [id] {
|
|
||||||
padding-top: 45px;
|
|
||||||
margin-top: -45px;
|
|
||||||
}
|
|
||||||
/*
|
|
||||||
* Without this,
|
|
||||||
* for example most links in the page's TOC aren't usable anymore, and tables
|
|
||||||
* sometimes overlap the text above
|
|
||||||
* */
|
|
||||||
section a[id], section table[id] {
|
|
||||||
padding-top: 0;
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Assure reading examples does not require horizontal scrolling */
|
|
||||||
.rst-content div[class^="highlight"] pre {
|
|
||||||
white-space: pre-wrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
.rst-content dl dt { margin-bottom: 0; }
|
|
||||||
|
|
||||||
/*! Make sure that environment variable links are blue */
|
|
||||||
.rst-content code.xref.std-envvar { color: #2980b9; }
|
|
|
@ -1 +0,0 @@
|
||||||
.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions .rst-other-versions .rtd-current-item{font-weight:700}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}#flyout-search-form{padding:6px}
|
|
Before Width: | Height: | Size: 434 KiB |
|
@ -1,4 +0,0 @@
|
||||||
.ethical-sidebar,
|
|
||||||
.ethical-footer {
|
|
||||||
border-radius: 0 !important;
|
|
||||||
}
|
|
|
@ -1,149 +0,0 @@
|
||||||
/*
|
|
||||||
* Base JavaScript utilities for all Sphinx HTML documentation.
|
|
||||||
*/
|
|
||||||
"use strict";
|
|
||||||
|
|
||||||
const BLACKLISTED_KEY_CONTROL_ELEMENTS = new Set([
|
|
||||||
"TEXTAREA",
|
|
||||||
"INPUT",
|
|
||||||
"SELECT",
|
|
||||||
"BUTTON",
|
|
||||||
]);
|
|
||||||
|
|
||||||
const _ready = (callback) => {
|
|
||||||
if (document.readyState !== "loading") {
|
|
||||||
callback();
|
|
||||||
} else {
|
|
||||||
document.addEventListener("DOMContentLoaded", callback);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Small JavaScript module for the documentation.
|
|
||||||
*/
|
|
||||||
const Documentation = {
|
|
||||||
init: () => {
|
|
||||||
Documentation.initDomainIndexTable();
|
|
||||||
Documentation.initOnKeyListeners();
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* i18n support
|
|
||||||
*/
|
|
||||||
TRANSLATIONS: {},
|
|
||||||
PLURAL_EXPR: (n) => (n === 1 ? 0 : 1),
|
|
||||||
LOCALE: "unknown",
|
|
||||||
|
|
||||||
// gettext and ngettext don't access this so that the functions
|
|
||||||
// can safely bound to a different name (_ = Documentation.gettext)
|
|
||||||
gettext: (string) => {
|
|
||||||
const translated = Documentation.TRANSLATIONS[string];
|
|
||||||
switch (typeof translated) {
|
|
||||||
case "undefined":
|
|
||||||
return string; // no translation
|
|
||||||
case "string":
|
|
||||||
return translated; // translation exists
|
|
||||||
default:
|
|
||||||
return translated[0]; // (singular, plural) translation tuple exists
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
ngettext: (singular, plural, n) => {
|
|
||||||
const translated = Documentation.TRANSLATIONS[singular];
|
|
||||||
if (typeof translated !== "undefined")
|
|
||||||
return translated[Documentation.PLURAL_EXPR(n)];
|
|
||||||
return n === 1 ? singular : plural;
|
|
||||||
},
|
|
||||||
|
|
||||||
addTranslations: (catalog) => {
|
|
||||||
Object.assign(Documentation.TRANSLATIONS, catalog.messages);
|
|
||||||
Documentation.PLURAL_EXPR = new Function(
|
|
||||||
"n",
|
|
||||||
`return (${catalog.plural_expr})`
|
|
||||||
);
|
|
||||||
Documentation.LOCALE = catalog.locale;
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* helper function to focus on search bar
|
|
||||||
*/
|
|
||||||
focusSearchBar: () => {
|
|
||||||
document.querySelectorAll("input[name=q]")[0]?.focus();
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Initialise the domain index toggle buttons
|
|
||||||
*/
|
|
||||||
initDomainIndexTable: () => {
|
|
||||||
const toggler = (el) => {
|
|
||||||
const idNumber = el.id.substr(7);
|
|
||||||
const toggledRows = document.querySelectorAll(`tr.cg-${idNumber}`);
|
|
||||||
if (el.src.substr(-9) === "minus.png") {
|
|
||||||
el.src = `${el.src.substr(0, el.src.length - 9)}plus.png`;
|
|
||||||
toggledRows.forEach((el) => (el.style.display = "none"));
|
|
||||||
} else {
|
|
||||||
el.src = `${el.src.substr(0, el.src.length - 8)}minus.png`;
|
|
||||||
toggledRows.forEach((el) => (el.style.display = ""));
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
const togglerElements = document.querySelectorAll("img.toggler");
|
|
||||||
togglerElements.forEach((el) =>
|
|
||||||
el.addEventListener("click", (event) => toggler(event.currentTarget))
|
|
||||||
);
|
|
||||||
togglerElements.forEach((el) => (el.style.display = ""));
|
|
||||||
if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) togglerElements.forEach(toggler);
|
|
||||||
},
|
|
||||||
|
|
||||||
initOnKeyListeners: () => {
|
|
||||||
// only install a listener if it is really needed
|
|
||||||
if (
|
|
||||||
!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS &&
|
|
||||||
!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS
|
|
||||||
)
|
|
||||||
return;
|
|
||||||
|
|
||||||
document.addEventListener("keydown", (event) => {
|
|
||||||
// bail for input elements
|
|
||||||
if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return;
|
|
||||||
// bail with special keys
|
|
||||||
if (event.altKey || event.ctrlKey || event.metaKey) return;
|
|
||||||
|
|
||||||
if (!event.shiftKey) {
|
|
||||||
switch (event.key) {
|
|
||||||
case "ArrowLeft":
|
|
||||||
if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break;
|
|
||||||
|
|
||||||
const prevLink = document.querySelector('link[rel="prev"]');
|
|
||||||
if (prevLink && prevLink.href) {
|
|
||||||
window.location.href = prevLink.href;
|
|
||||||
event.preventDefault();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case "ArrowRight":
|
|
||||||
if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break;
|
|
||||||
|
|
||||||
const nextLink = document.querySelector('link[rel="next"]');
|
|
||||||
if (nextLink && nextLink.href) {
|
|
||||||
window.location.href = nextLink.href;
|
|
||||||
event.preventDefault();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// some keyboard layouts may need Shift to get /
|
|
||||||
switch (event.key) {
|
|
||||||
case "/":
|
|
||||||
if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) break;
|
|
||||||
Documentation.focusSearchBar();
|
|
||||||
event.preventDefault();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
// quick alias for translations
|
|
||||||
const _ = Documentation.gettext;
|
|
||||||
|
|
||||||
_ready(Documentation.init);
|
|
|
@ -1,13 +0,0 @@
|
||||||
const DOCUMENTATION_OPTIONS = {
|
|
||||||
VERSION: '',
|
|
||||||
LANGUAGE: 'en',
|
|
||||||
COLLAPSE_INDEX: false,
|
|
||||||
BUILDER: 'html',
|
|
||||||
FILE_SUFFIX: '.html',
|
|
||||||
LINK_SUFFIX: '.html',
|
|
||||||
HAS_SOURCE: false,
|
|
||||||
SOURCELINK_SUFFIX: '.txt',
|
|
||||||
NAVIGATION_WITH_KEYS: false,
|
|
||||||
SHOW_SEARCH_SUMMARY: true,
|
|
||||||
ENABLE_SEARCH_SHORTCUTS: true,
|
|
||||||
};
|
|
Before Width: | Height: | Size: 286 B |
Before Width: | Height: | Size: 8.5 KiB |
|
@ -1,14 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!-- Generator: Adobe Illustrator 21.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
|
||||||
<svg version="1.1" id="logo" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
|
||||||
viewBox="30 30 240 240" style="enable-background:new 0 0 300 300;" xml:space="preserve">
|
|
||||||
<style type="text/css">
|
|
||||||
.st0{fill:#FFFFFF;}
|
|
||||||
</style>
|
|
||||||
<title>Ansible-Mark-RGB</title>
|
|
||||||
<path d="M259.8,152.9c0,59-47.8,106.8-106.8,106.8c-59,0-106.8-47.8-106.8-106.8S94,46.1,153,46.1c0,0,0,0,0,0
|
|
||||||
C212,46.1,259.8,93.9,259.8,152.9C259.8,152.9,259.8,152.9,259.8,152.9"/>
|
|
||||||
<path class="st0" d="M154.8,112.9l27.6,68.2l-41.7-32.9L154.8,112.9z M203.9,196.8L161.4,94.5c-1-2.8-3.7-4.6-6.6-4.5
|
|
||||||
c-3-0.1-5.7,1.7-6.8,4.5l-46.7,112.2h16l18.5-46.3l55.1,44.5c2.2,1.8,3.8,2.6,5.9,2.6c4.2,0.1,7.7-3.2,7.8-7.4c0-0.1,0-0.1,0-0.2
|
|
||||||
C204.6,198.9,204.3,197.8,203.9,196.8"/>
|
|
||||||
</svg>
|
|
Before Width: | Height: | Size: 904 B |
Before Width: | Height: | Size: 5.1 KiB |
|
@ -1 +0,0 @@
|
||||||
<svg id="logo" xmlns="http://www.w3.org/2000/svg" viewBox="30 30 240 240"><title>Ansible-Mark-RGB</title><polygon points="140.692 148.221 182.438 181.102 154.799 112.893 140.692 148.221" fill="#fff"/><path d="M153,46.12714A106.79132,106.79132,0,1,0,259.79286,152.92,106.79751,106.79751,0,0,0,153,46.12714Zm43.82007,161.46533c-2.08093,0-3.67822-.81091-5.89673-2.60413l-55.1178-44.52991-18.46741,46.268h-15.9613L148.03346,94.51422a7.08784,7.08784,0,0,1,6.76587-4.51355,6.85643,6.85643,0,0,1,6.58521,4.51355l42.51025,102.30072a10.11133,10.11133,0,0,1,.72827,3.1488A7.62408,7.62408,0,0,1,196.82008,207.59247Z" fill="#fff"/></svg>
|
|
Before Width: | Height: | Size: 626 B |
2
pr/352/_static/jquery.js
vendored
|
@ -1 +0,0 @@
|
||||||
!function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=4)}({4:function(e,t,r){}});
|
|
|
@ -1,228 +0,0 @@
|
||||||
const themeFlyoutDisplay = "hidden";
|
|
||||||
const themeVersionSelector = true;
|
|
||||||
const themeLanguageSelector = true;
|
|
||||||
|
|
||||||
if (themeFlyoutDisplay === "attached") {
|
|
||||||
function renderLanguages(config) {
|
|
||||||
if (!config.projects.translations.length) {
|
|
||||||
return "";
|
|
||||||
}
|
|
||||||
|
|
||||||
// Insert the current language to the options on the selector
|
|
||||||
let languages = config.projects.translations.concat(config.projects.current);
|
|
||||||
languages = languages.sort((a, b) => a.language.name.localeCompare(b.language.name));
|
|
||||||
|
|
||||||
const languagesHTML = `
|
|
||||||
<dl>
|
|
||||||
<dt>Languages</dt>
|
|
||||||
${languages
|
|
||||||
.map(
|
|
||||||
(translation) => `
|
|
||||||
<dd ${translation.slug == config.projects.current.slug ? 'class="rtd-current-item"' : ""}>
|
|
||||||
<a href="${translation.urls.documentation}">${translation.language.code}</a>
|
|
||||||
</dd>
|
|
||||||
`,
|
|
||||||
)
|
|
||||||
.join("\n")}
|
|
||||||
</dl>
|
|
||||||
`;
|
|
||||||
return languagesHTML;
|
|
||||||
}
|
|
||||||
|
|
||||||
function renderVersions(config) {
|
|
||||||
if (!config.versions.active.length) {
|
|
||||||
return "";
|
|
||||||
}
|
|
||||||
const versionsHTML = `
|
|
||||||
<dl>
|
|
||||||
<dt>Versions</dt>
|
|
||||||
${config.versions.active
|
|
||||||
.map(
|
|
||||||
(version) => `
|
|
||||||
<dd ${version.slug === config.versions.current.slug ? 'class="rtd-current-item"' : ""}>
|
|
||||||
<a href="${version.urls.documentation}">${version.slug}</a>
|
|
||||||
</dd>
|
|
||||||
`,
|
|
||||||
)
|
|
||||||
.join("\n")}
|
|
||||||
</dl>
|
|
||||||
`;
|
|
||||||
return versionsHTML;
|
|
||||||
}
|
|
||||||
|
|
||||||
function renderDownloads(config) {
|
|
||||||
if (!Object.keys(config.versions.current.downloads).length) {
|
|
||||||
return "";
|
|
||||||
}
|
|
||||||
const downloadsNameDisplay = {
|
|
||||||
pdf: "PDF",
|
|
||||||
epub: "Epub",
|
|
||||||
htmlzip: "HTML",
|
|
||||||
};
|
|
||||||
|
|
||||||
const downloadsHTML = `
|
|
||||||
<dl>
|
|
||||||
<dt>Downloads</dt>
|
|
||||||
${Object.entries(config.versions.current.downloads)
|
|
||||||
.map(
|
|
||||||
([name, url]) => `
|
|
||||||
<dd>
|
|
||||||
<a href="${url}">${downloadsNameDisplay[name]}</a>
|
|
||||||
</dd>
|
|
||||||
`,
|
|
||||||
)
|
|
||||||
.join("\n")}
|
|
||||||
</dl>
|
|
||||||
`;
|
|
||||||
return downloadsHTML;
|
|
||||||
}
|
|
||||||
|
|
||||||
document.addEventListener("readthedocs-addons-data-ready", function (event) {
|
|
||||||
const config = event.detail.data();
|
|
||||||
|
|
||||||
const flyout = `
|
|
||||||
<div class="rst-versions" data-toggle="rst-versions" role="note">
|
|
||||||
<span class="rst-current-version" data-toggle="rst-current-version">
|
|
||||||
<span class="fa fa-book"> Read the Docs</span>
|
|
||||||
v: ${config.versions.current.slug}
|
|
||||||
<span class="fa fa-caret-down"></span>
|
|
||||||
</span>
|
|
||||||
<div class="rst-other-versions">
|
|
||||||
<div class="injected">
|
|
||||||
${renderLanguages(config)}
|
|
||||||
${renderVersions(config)}
|
|
||||||
${renderDownloads(config)}
|
|
||||||
<dl>
|
|
||||||
<dt>On Read the Docs</dt>
|
|
||||||
<dd>
|
|
||||||
<a href="${config.projects.current.urls.home}">Project Home</a>
|
|
||||||
</dd>
|
|
||||||
<dd>
|
|
||||||
<a href="${config.projects.current.urls.builds}">Builds</a>
|
|
||||||
</dd>
|
|
||||||
<dd>
|
|
||||||
<a href="${config.projects.current.urls.downloads}">Downloads</a>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
<dl>
|
|
||||||
<dt>Search</dt>
|
|
||||||
<dd>
|
|
||||||
<form id="flyout-search-form">
|
|
||||||
<input
|
|
||||||
class="wy-form"
|
|
||||||
type="text"
|
|
||||||
name="q"
|
|
||||||
aria-label="Search docs"
|
|
||||||
placeholder="Search docs"
|
|
||||||
/>
|
|
||||||
</form>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
<hr />
|
|
||||||
<small>
|
|
||||||
<span>Hosted by <a href="https://about.readthedocs.org/?utm_source=&utm_content=flyout">Read the Docs</a></span>
|
|
||||||
</small>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
`;
|
|
||||||
|
|
||||||
// Inject the generated flyout into the body HTML element.
|
|
||||||
document.body.insertAdjacentHTML("beforeend", flyout);
|
|
||||||
|
|
||||||
// Trigger the Read the Docs Addons Search modal when clicking on the "Search docs" input from inside the flyout.
|
|
||||||
document
|
|
||||||
.querySelector("#flyout-search-form")
|
|
||||||
.addEventListener("focusin", () => {
|
|
||||||
const event = new CustomEvent("readthedocs-search-show");
|
|
||||||
document.dispatchEvent(event);
|
|
||||||
});
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
if (themeLanguageSelector || themeVersionSelector) {
|
|
||||||
function onSelectorSwitch(event) {
|
|
||||||
const option = event.target.selectedIndex;
|
|
||||||
const item = event.target.options[option];
|
|
||||||
window.location.href = item.dataset.url;
|
|
||||||
}
|
|
||||||
|
|
||||||
document.addEventListener("readthedocs-addons-data-ready", function (event) {
|
|
||||||
const config = event.detail.data();
|
|
||||||
|
|
||||||
const versionSwitch = document.querySelector(
|
|
||||||
"div.switch-menus > div.version-switch",
|
|
||||||
);
|
|
||||||
if (themeVersionSelector) {
|
|
||||||
let versions = config.versions.active;
|
|
||||||
if (config.versions.current.hidden || config.versions.current.type === "external") {
|
|
||||||
versions.unshift(config.versions.current);
|
|
||||||
}
|
|
||||||
const versionSelect = `
|
|
||||||
<select>
|
|
||||||
${versions
|
|
||||||
.map(
|
|
||||||
(version) => `
|
|
||||||
<option
|
|
||||||
value="${version.slug}"
|
|
||||||
${config.versions.current.slug === version.slug ? 'selected="selected"' : ""}
|
|
||||||
data-url="${version.urls.documentation}">
|
|
||||||
${version.slug}
|
|
||||||
</option>`,
|
|
||||||
)
|
|
||||||
.join("\n")}
|
|
||||||
</select>
|
|
||||||
`;
|
|
||||||
|
|
||||||
versionSwitch.innerHTML = versionSelect;
|
|
||||||
versionSwitch.firstElementChild.addEventListener("change", onSelectorSwitch);
|
|
||||||
}
|
|
||||||
|
|
||||||
const languageSwitch = document.querySelector(
|
|
||||||
"div.switch-menus > div.language-switch",
|
|
||||||
);
|
|
||||||
|
|
||||||
if (themeLanguageSelector) {
|
|
||||||
if (config.projects.translations.length) {
|
|
||||||
// Add the current language to the options on the selector
|
|
||||||
let languages = config.projects.translations.concat(
|
|
||||||
config.projects.current,
|
|
||||||
);
|
|
||||||
languages = languages.sort((a, b) =>
|
|
||||||
a.language.name.localeCompare(b.language.name),
|
|
||||||
);
|
|
||||||
|
|
||||||
const languageSelect = `
|
|
||||||
<select>
|
|
||||||
${languages
|
|
||||||
.map(
|
|
||||||
(language) => `
|
|
||||||
<option
|
|
||||||
value="${language.language.code}"
|
|
||||||
${config.projects.current.slug === language.slug ? 'selected="selected"' : ""}
|
|
||||||
data-url="${language.urls.documentation}">
|
|
||||||
${language.language.name}
|
|
||||||
</option>`,
|
|
||||||
)
|
|
||||||
.join("\n")}
|
|
||||||
</select>
|
|
||||||
`;
|
|
||||||
|
|
||||||
languageSwitch.innerHTML = languageSelect;
|
|
||||||
languageSwitch.firstElementChild.addEventListener("change", onSelectorSwitch);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
languageSwitch.remove();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
document.addEventListener("readthedocs-addons-data-ready", function (event) {
|
|
||||||
// Trigger the Read the Docs Addons Search modal when clicking on "Search docs" input from the topnav.
|
|
||||||
document
|
|
||||||
.querySelector("[role='search'] input")
|
|
||||||
.addEventListener("focusin", () => {
|
|
||||||
const event = new CustomEvent("readthedocs-search-show");
|
|
||||||
document.dispatchEvent(event);
|
|
||||||
});
|
|
||||||
});
|
|
|
@ -1,192 +0,0 @@
|
||||||
/*
|
|
||||||
* This script contains the language-specific data used by searchtools.js,
|
|
||||||
* namely the list of stopwords, stemmer, scorer and splitter.
|
|
||||||
*/
|
|
||||||
|
|
||||||
var stopwords = ["a", "and", "are", "as", "at", "be", "but", "by", "for", "if", "in", "into", "is", "it", "near", "no", "not", "of", "on", "or", "such", "that", "the", "their", "then", "there", "these", "they", "this", "to", "was", "will", "with"];
|
|
||||||
|
|
||||||
|
|
||||||
/* Non-minified version is copied as a separate JS file, if available */
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Porter Stemmer
|
|
||||||
*/
|
|
||||||
var Stemmer = function() {
|
|
||||||
|
|
||||||
var step2list = {
|
|
||||||
ational: 'ate',
|
|
||||||
tional: 'tion',
|
|
||||||
enci: 'ence',
|
|
||||||
anci: 'ance',
|
|
||||||
izer: 'ize',
|
|
||||||
bli: 'ble',
|
|
||||||
alli: 'al',
|
|
||||||
entli: 'ent',
|
|
||||||
eli: 'e',
|
|
||||||
ousli: 'ous',
|
|
||||||
ization: 'ize',
|
|
||||||
ation: 'ate',
|
|
||||||
ator: 'ate',
|
|
||||||
alism: 'al',
|
|
||||||
iveness: 'ive',
|
|
||||||
fulness: 'ful',
|
|
||||||
ousness: 'ous',
|
|
||||||
aliti: 'al',
|
|
||||||
iviti: 'ive',
|
|
||||||
biliti: 'ble',
|
|
||||||
logi: 'log'
|
|
||||||
};
|
|
||||||
|
|
||||||
var step3list = {
|
|
||||||
icate: 'ic',
|
|
||||||
ative: '',
|
|
||||||
alize: 'al',
|
|
||||||
iciti: 'ic',
|
|
||||||
ical: 'ic',
|
|
||||||
ful: '',
|
|
||||||
ness: ''
|
|
||||||
};
|
|
||||||
|
|
||||||
var c = "[^aeiou]"; // consonant
|
|
||||||
var v = "[aeiouy]"; // vowel
|
|
||||||
var C = c + "[^aeiouy]*"; // consonant sequence
|
|
||||||
var V = v + "[aeiou]*"; // vowel sequence
|
|
||||||
|
|
||||||
var mgr0 = "^(" + C + ")?" + V + C; // [C]VC... is m>0
|
|
||||||
var meq1 = "^(" + C + ")?" + V + C + "(" + V + ")?$"; // [C]VC[V] is m=1
|
|
||||||
var mgr1 = "^(" + C + ")?" + V + C + V + C; // [C]VCVC... is m>1
|
|
||||||
var s_v = "^(" + C + ")?" + v; // vowel in stem
|
|
||||||
|
|
||||||
this.stemWord = function (w) {
|
|
||||||
var stem;
|
|
||||||
var suffix;
|
|
||||||
var firstch;
|
|
||||||
var origword = w;
|
|
||||||
|
|
||||||
if (w.length < 3)
|
|
||||||
return w;
|
|
||||||
|
|
||||||
var re;
|
|
||||||
var re2;
|
|
||||||
var re3;
|
|
||||||
var re4;
|
|
||||||
|
|
||||||
firstch = w.substr(0,1);
|
|
||||||
if (firstch == "y")
|
|
||||||
w = firstch.toUpperCase() + w.substr(1);
|
|
||||||
|
|
||||||
// Step 1a
|
|
||||||
re = /^(.+?)(ss|i)es$/;
|
|
||||||
re2 = /^(.+?)([^s])s$/;
|
|
||||||
|
|
||||||
if (re.test(w))
|
|
||||||
w = w.replace(re,"$1$2");
|
|
||||||
else if (re2.test(w))
|
|
||||||
w = w.replace(re2,"$1$2");
|
|
||||||
|
|
||||||
// Step 1b
|
|
||||||
re = /^(.+?)eed$/;
|
|
||||||
re2 = /^(.+?)(ed|ing)$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
re = new RegExp(mgr0);
|
|
||||||
if (re.test(fp[1])) {
|
|
||||||
re = /.$/;
|
|
||||||
w = w.replace(re,"");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (re2.test(w)) {
|
|
||||||
var fp = re2.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
re2 = new RegExp(s_v);
|
|
||||||
if (re2.test(stem)) {
|
|
||||||
w = stem;
|
|
||||||
re2 = /(at|bl|iz)$/;
|
|
||||||
re3 = new RegExp("([^aeiouylsz])\\1$");
|
|
||||||
re4 = new RegExp("^" + C + v + "[^aeiouwxy]$");
|
|
||||||
if (re2.test(w))
|
|
||||||
w = w + "e";
|
|
||||||
else if (re3.test(w)) {
|
|
||||||
re = /.$/;
|
|
||||||
w = w.replace(re,"");
|
|
||||||
}
|
|
||||||
else if (re4.test(w))
|
|
||||||
w = w + "e";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 1c
|
|
||||||
re = /^(.+?)y$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
re = new RegExp(s_v);
|
|
||||||
if (re.test(stem))
|
|
||||||
w = stem + "i";
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 2
|
|
||||||
re = /^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
suffix = fp[2];
|
|
||||||
re = new RegExp(mgr0);
|
|
||||||
if (re.test(stem))
|
|
||||||
w = stem + step2list[suffix];
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 3
|
|
||||||
re = /^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
suffix = fp[2];
|
|
||||||
re = new RegExp(mgr0);
|
|
||||||
if (re.test(stem))
|
|
||||||
w = stem + step3list[suffix];
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 4
|
|
||||||
re = /^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/;
|
|
||||||
re2 = /^(.+?)(s|t)(ion)$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
re = new RegExp(mgr1);
|
|
||||||
if (re.test(stem))
|
|
||||||
w = stem;
|
|
||||||
}
|
|
||||||
else if (re2.test(w)) {
|
|
||||||
var fp = re2.exec(w);
|
|
||||||
stem = fp[1] + fp[2];
|
|
||||||
re2 = new RegExp(mgr1);
|
|
||||||
if (re2.test(stem))
|
|
||||||
w = stem;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 5
|
|
||||||
re = /^(.+?)e$/;
|
|
||||||
if (re.test(w)) {
|
|
||||||
var fp = re.exec(w);
|
|
||||||
stem = fp[1];
|
|
||||||
re = new RegExp(mgr1);
|
|
||||||
re2 = new RegExp(meq1);
|
|
||||||
re3 = new RegExp("^" + C + v + "[^aeiouwxy]$");
|
|
||||||
if (re.test(stem) || (re2.test(stem) && !(re3.test(stem))))
|
|
||||||
w = stem;
|
|
||||||
}
|
|
||||||
re = /ll$/;
|
|
||||||
re2 = new RegExp(mgr1);
|
|
||||||
if (re.test(w) && re2.test(w)) {
|
|
||||||
re = /.$/;
|
|
||||||
w = w.replace(re,"");
|
|
||||||
}
|
|
||||||
|
|
||||||
// and turn initial Y back to y
|
|
||||||
if (firstch == "y")
|
|
||||||
w = firstch.toLowerCase() + w.substr(1);
|
|
||||||
return w;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
Before Width: | Height: | Size: 90 B |
Before Width: | Height: | Size: 90 B |
|
@ -1,81 +0,0 @@
|
||||||
pre { line-height: 125%; }
|
|
||||||
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
|
|
||||||
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
|
|
||||||
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
|
|
||||||
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
|
|
||||||
.highlight .hll { background-color: #ffffcc; border: 1px solid #edff00; padding-top: 2px; border-radius: 3px; display: block }
|
|
||||||
.highlight { background: #f8f8f8; }
|
|
||||||
.highlight .c { color: #6A737D; font-style: italic } /* Comment */
|
|
||||||
.highlight .err { color: #A61717; background-color: #E3D2D2; border: 1px solid #F00 } /* Error */
|
|
||||||
.highlight .k { color: #007020; font-weight: bold } /* Keyword */
|
|
||||||
.highlight .l { color: #032F62 } /* Literal */
|
|
||||||
.highlight .n { color: #333 } /* Name */
|
|
||||||
.highlight .o { color: #666; font-weight: bold } /* Operator */
|
|
||||||
.highlight .p { font-weight: bold } /* Punctuation */
|
|
||||||
.highlight .ch { color: #6A737D; font-style: italic } /* Comment.Hashbang */
|
|
||||||
.highlight .cm { color: #6A737D; font-style: italic } /* Comment.Multiline */
|
|
||||||
.highlight .cp { color: #007020 } /* Comment.Preproc */
|
|
||||||
.highlight .cpf { color: #6A737D; font-style: italic } /* Comment.PreprocFile */
|
|
||||||
.highlight .c1 { color: #6A737D; font-style: italic } /* Comment.Single */
|
|
||||||
.highlight .cs { color: #999; font-weight: bold; font-style: italic; background-color: #FFF0F0 } /* Comment.Special */
|
|
||||||
.highlight .gd { color: #A00000; background-color: #FDD } /* Generic.Deleted */
|
|
||||||
.highlight .ge { font-style: italic } /* Generic.Emph */
|
|
||||||
.highlight .gr { color: #A00 } /* Generic.Error */
|
|
||||||
.highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */
|
|
||||||
.highlight .gi { color: #00A000; background-color: #DFD } /* Generic.Inserted */
|
|
||||||
.highlight .go { color: #333 } /* Generic.Output */
|
|
||||||
.highlight .gp { color: #C65D09; font-weight: bold } /* Generic.Prompt */
|
|
||||||
.highlight .gs { font-weight: bold } /* Generic.Strong */
|
|
||||||
.highlight .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
|
|
||||||
.highlight .gt { color: #0040D0 } /* Generic.Traceback */
|
|
||||||
.highlight .kc { color: #007020; font-weight: bold } /* Keyword.Constant */
|
|
||||||
.highlight .kd { color: #007020; font-weight: bold } /* Keyword.Declaration */
|
|
||||||
.highlight .kn { color: #007020; font-weight: bold } /* Keyword.Namespace */
|
|
||||||
.highlight .kp { color: #007020; font-weight: bold } /* Keyword.Pseudo */
|
|
||||||
.highlight .kr { color: #007020; font-weight: bold } /* Keyword.Reserved */
|
|
||||||
.highlight .kt { color: #902000; font-weight: bold } /* Keyword.Type */
|
|
||||||
.highlight .ld { color: #032F62 } /* Literal.Date */
|
|
||||||
.highlight .m { color: #208050 } /* Literal.Number */
|
|
||||||
.highlight .s { color: #4070A0 } /* Literal.String */
|
|
||||||
.highlight .na { color: #008080 } /* Name.Attribute */
|
|
||||||
.highlight .nb { color: #0086B3 } /* Name.Builtin */
|
|
||||||
.highlight .nc { color: #458; font-weight: bold } /* Name.Class */
|
|
||||||
.highlight .no { color: #008080 } /* Name.Constant */
|
|
||||||
.highlight .nd { color: #555; font-weight: bold } /* Name.Decorator */
|
|
||||||
.highlight .ni { color: #800080; font-weight: bold } /* Name.Entity */
|
|
||||||
.highlight .ne { color: #900; font-weight: bold } /* Name.Exception */
|
|
||||||
.highlight .nf { color: #900; font-weight: bold } /* Name.Function */
|
|
||||||
.highlight .nl { color: #002070; font-weight: bold } /* Name.Label */
|
|
||||||
.highlight .nn { color: #555; font-weight: bold } /* Name.Namespace */
|
|
||||||
.highlight .nx { color: #333 } /* Name.Other */
|
|
||||||
.highlight .py { color: #333 } /* Name.Property */
|
|
||||||
.highlight .nt { color: #22863A; font-weight: bold } /* Name.Tag */
|
|
||||||
.highlight .nv { color: #9960B5; font-weight: bold } /* Name.Variable */
|
|
||||||
.highlight .ow { color: #007020; font-weight: bold } /* Operator.Word */
|
|
||||||
.highlight .pm { font-weight: bold } /* Punctuation.Marker */
|
|
||||||
.highlight .w { color: #BBB } /* Text.Whitespace */
|
|
||||||
.highlight .mb { color: #099 } /* Literal.Number.Bin */
|
|
||||||
.highlight .mf { color: #099 } /* Literal.Number.Float */
|
|
||||||
.highlight .mh { color: #099 } /* Literal.Number.Hex */
|
|
||||||
.highlight .mi { color: #099 } /* Literal.Number.Integer */
|
|
||||||
.highlight .mo { color: #099 } /* Literal.Number.Oct */
|
|
||||||
.highlight .sa { color: #D14 } /* Literal.String.Affix */
|
|
||||||
.highlight .sb { color: #D14 } /* Literal.String.Backtick */
|
|
||||||
.highlight .sc { color: #D14 } /* Literal.String.Char */
|
|
||||||
.highlight .dl { color: #D14 } /* Literal.String.Delimiter */
|
|
||||||
.highlight .sd { color: #D14; font-style: italic } /* Literal.String.Doc */
|
|
||||||
.highlight .s2 { color: #D14 } /* Literal.String.Double */
|
|
||||||
.highlight .se { color: #D14; font-weight: bold } /* Literal.String.Escape */
|
|
||||||
.highlight .sh { color: #D14 } /* Literal.String.Heredoc */
|
|
||||||
.highlight .si { color: #D14; font-style: italic } /* Literal.String.Interpol */
|
|
||||||
.highlight .sx { color: #D14 } /* Literal.String.Other */
|
|
||||||
.highlight .sr { color: #009926 } /* Literal.String.Regex */
|
|
||||||
.highlight .s1 { color: #D14 } /* Literal.String.Single */
|
|
||||||
.highlight .ss { color: #990073 } /* Literal.String.Symbol */
|
|
||||||
.highlight .bp { color: #999 } /* Name.Builtin.Pseudo */
|
|
||||||
.highlight .fm { color: #06287E; font-weight: bold } /* Name.Function.Magic */
|
|
||||||
.highlight .vc { color: #008080; font-weight: bold } /* Name.Variable.Class */
|
|
||||||
.highlight .vg { color: #008080; font-weight: bold } /* Name.Variable.Global */
|
|
||||||
.highlight .vi { color: #008080; font-weight: bold } /* Name.Variable.Instance */
|
|
||||||
.highlight .vm { color: #BB60D5; font-weight: bold } /* Name.Variable.Magic */
|
|
||||||
.highlight .il { color: #099 } /* Literal.Number.Integer.Long */
|
|
|
@ -1,635 +0,0 @@
|
||||||
/*
|
|
||||||
* Sphinx JavaScript utilities for the full-text search.
|
|
||||||
*/
|
|
||||||
"use strict";
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Simple result scoring code.
|
|
||||||
*/
|
|
||||||
if (typeof Scorer === "undefined") {
|
|
||||||
var Scorer = {
|
|
||||||
// Implement the following function to further tweak the score for each result
|
|
||||||
// The function takes a result array [docname, title, anchor, descr, score, filename]
|
|
||||||
// and returns the new score.
|
|
||||||
/*
|
|
||||||
score: result => {
|
|
||||||
const [docname, title, anchor, descr, score, filename, kind] = result
|
|
||||||
return score
|
|
||||||
},
|
|
||||||
*/
|
|
||||||
|
|
||||||
// query matches the full name of an object
|
|
||||||
objNameMatch: 11,
|
|
||||||
// or matches in the last dotted part of the object name
|
|
||||||
objPartialMatch: 6,
|
|
||||||
// Additive scores depending on the priority of the object
|
|
||||||
objPrio: {
|
|
||||||
0: 15, // used to be importantResults
|
|
||||||
1: 5, // used to be objectResults
|
|
||||||
2: -5, // used to be unimportantResults
|
|
||||||
},
|
|
||||||
// Used when the priority is not in the mapping.
|
|
||||||
objPrioDefault: 0,
|
|
||||||
|
|
||||||
// query found in title
|
|
||||||
title: 15,
|
|
||||||
partialTitle: 7,
|
|
||||||
// query found in terms
|
|
||||||
term: 5,
|
|
||||||
partialTerm: 2,
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
// Global search result kind enum, used by themes to style search results.
|
|
||||||
class SearchResultKind {
|
|
||||||
static get index() { return "index"; }
|
|
||||||
static get object() { return "object"; }
|
|
||||||
static get text() { return "text"; }
|
|
||||||
static get title() { return "title"; }
|
|
||||||
}
|
|
||||||
|
|
||||||
const _removeChildren = (element) => {
|
|
||||||
while (element && element.lastChild) element.removeChild(element.lastChild);
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions#escaping
|
|
||||||
*/
|
|
||||||
const _escapeRegExp = (string) =>
|
|
||||||
string.replace(/[.*+\-?^${}()|[\]\\]/g, "\\$&"); // $& means the whole matched string
|
|
||||||
|
|
||||||
const _displayItem = (item, searchTerms, highlightTerms) => {
|
|
||||||
const docBuilder = DOCUMENTATION_OPTIONS.BUILDER;
|
|
||||||
const docFileSuffix = DOCUMENTATION_OPTIONS.FILE_SUFFIX;
|
|
||||||
const docLinkSuffix = DOCUMENTATION_OPTIONS.LINK_SUFFIX;
|
|
||||||
const showSearchSummary = DOCUMENTATION_OPTIONS.SHOW_SEARCH_SUMMARY;
|
|
||||||
const contentRoot = document.documentElement.dataset.content_root;
|
|
||||||
|
|
||||||
const [docName, title, anchor, descr, score, _filename, kind] = item;
|
|
||||||
|
|
||||||
let listItem = document.createElement("li");
|
|
||||||
// Add a class representing the item's type:
|
|
||||||
// can be used by a theme's CSS selector for styling
|
|
||||||
// See SearchResultKind for the class names.
|
|
||||||
listItem.classList.add(`kind-${kind}`);
|
|
||||||
let requestUrl;
|
|
||||||
let linkUrl;
|
|
||||||
if (docBuilder === "dirhtml") {
|
|
||||||
// dirhtml builder
|
|
||||||
let dirname = docName + "/";
|
|
||||||
if (dirname.match(/\/index\/$/))
|
|
||||||
dirname = dirname.substring(0, dirname.length - 6);
|
|
||||||
else if (dirname === "index/") dirname = "";
|
|
||||||
requestUrl = contentRoot + dirname;
|
|
||||||
linkUrl = requestUrl;
|
|
||||||
} else {
|
|
||||||
// normal html builders
|
|
||||||
requestUrl = contentRoot + docName + docFileSuffix;
|
|
||||||
linkUrl = docName + docLinkSuffix;
|
|
||||||
}
|
|
||||||
let linkEl = listItem.appendChild(document.createElement("a"));
|
|
||||||
linkEl.href = linkUrl + anchor;
|
|
||||||
linkEl.dataset.score = score;
|
|
||||||
linkEl.innerHTML = title;
|
|
||||||
if (descr) {
|
|
||||||
listItem.appendChild(document.createElement("span")).innerHTML =
|
|
||||||
" (" + descr + ")";
|
|
||||||
// highlight search terms in the description
|
|
||||||
if (SPHINX_HIGHLIGHT_ENABLED) // set in sphinx_highlight.js
|
|
||||||
highlightTerms.forEach((term) => _highlightText(listItem, term, "highlighted"));
|
|
||||||
}
|
|
||||||
else if (showSearchSummary)
|
|
||||||
fetch(requestUrl)
|
|
||||||
.then((responseData) => responseData.text())
|
|
||||||
.then((data) => {
|
|
||||||
if (data)
|
|
||||||
listItem.appendChild(
|
|
||||||
Search.makeSearchSummary(data, searchTerms, anchor)
|
|
||||||
);
|
|
||||||
// highlight search terms in the summary
|
|
||||||
if (SPHINX_HIGHLIGHT_ENABLED) // set in sphinx_highlight.js
|
|
||||||
highlightTerms.forEach((term) => _highlightText(listItem, term, "highlighted"));
|
|
||||||
});
|
|
||||||
Search.output.appendChild(listItem);
|
|
||||||
};
|
|
||||||
const _finishSearch = (resultCount) => {
|
|
||||||
Search.stopPulse();
|
|
||||||
Search.title.innerText = _("Search Results");
|
|
||||||
if (!resultCount)
|
|
||||||
Search.status.innerText = Documentation.gettext(
|
|
||||||
"Your search did not match any documents. Please make sure that all words are spelled correctly and that you've selected enough categories."
|
|
||||||
);
|
|
||||||
else
|
|
||||||
Search.status.innerText = Documentation.ngettext(
|
|
||||||
"Search finished, found one page matching the search query.",
|
|
||||||
"Search finished, found ${resultCount} pages matching the search query.",
|
|
||||||
resultCount,
|
|
||||||
).replace('${resultCount}', resultCount);
|
|
||||||
};
|
|
||||||
const _displayNextItem = (
|
|
||||||
results,
|
|
||||||
resultCount,
|
|
||||||
searchTerms,
|
|
||||||
highlightTerms,
|
|
||||||
) => {
|
|
||||||
// results left, load the summary and display it
|
|
||||||
// this is intended to be dynamic (don't sub resultsCount)
|
|
||||||
if (results.length) {
|
|
||||||
_displayItem(results.pop(), searchTerms, highlightTerms);
|
|
||||||
setTimeout(
|
|
||||||
() => _displayNextItem(results, resultCount, searchTerms, highlightTerms),
|
|
||||||
5
|
|
||||||
);
|
|
||||||
}
|
|
||||||
// search finished, update title and status message
|
|
||||||
else _finishSearch(resultCount);
|
|
||||||
};
|
|
||||||
// Helper function used by query() to order search results.
|
|
||||||
// Each input is an array of [docname, title, anchor, descr, score, filename, kind].
|
|
||||||
// Order the results by score (in opposite order of appearance, since the
|
|
||||||
// `_displayNextItem` function uses pop() to retrieve items) and then alphabetically.
|
|
||||||
const _orderResultsByScoreThenName = (a, b) => {
|
|
||||||
const leftScore = a[4];
|
|
||||||
const rightScore = b[4];
|
|
||||||
if (leftScore === rightScore) {
|
|
||||||
// same score: sort alphabetically
|
|
||||||
const leftTitle = a[1].toLowerCase();
|
|
||||||
const rightTitle = b[1].toLowerCase();
|
|
||||||
if (leftTitle === rightTitle) return 0;
|
|
||||||
return leftTitle > rightTitle ? -1 : 1; // inverted is intentional
|
|
||||||
}
|
|
||||||
return leftScore > rightScore ? 1 : -1;
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Default splitQuery function. Can be overridden in ``sphinx.search`` with a
|
|
||||||
* custom function per language.
|
|
||||||
*
|
|
||||||
* The regular expression works by splitting the string on consecutive characters
|
|
||||||
* that are not Unicode letters, numbers, underscores, or emoji characters.
|
|
||||||
* This is the same as ``\W+`` in Python, preserving the surrogate pair area.
|
|
||||||
*/
|
|
||||||
if (typeof splitQuery === "undefined") {
|
|
||||||
var splitQuery = (query) => query
|
|
||||||
.split(/[^\p{Letter}\p{Number}_\p{Emoji_Presentation}]+/gu)
|
|
||||||
.filter(term => term) // remove remaining empty strings
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Search Module
|
|
||||||
*/
|
|
||||||
const Search = {
|
|
||||||
_index: null,
|
|
||||||
_queued_query: null,
|
|
||||||
_pulse_status: -1,
|
|
||||||
|
|
||||||
htmlToText: (htmlString, anchor) => {
|
|
||||||
const htmlElement = new DOMParser().parseFromString(htmlString, 'text/html');
|
|
||||||
for (const removalQuery of [".headerlink", "script", "style"]) {
|
|
||||||
htmlElement.querySelectorAll(removalQuery).forEach((el) => { el.remove() });
|
|
||||||
}
|
|
||||||
if (anchor) {
|
|
||||||
const anchorContent = htmlElement.querySelector(`[role="main"] ${anchor}`);
|
|
||||||
if (anchorContent) return anchorContent.textContent;
|
|
||||||
|
|
||||||
console.warn(
|
|
||||||
`Anchored content block not found. Sphinx search tries to obtain it via DOM query '[role=main] ${anchor}'. Check your theme or template.`
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
// if anchor not specified or not found, fall back to main content
|
|
||||||
const docContent = htmlElement.querySelector('[role="main"]');
|
|
||||||
if (docContent) return docContent.textContent;
|
|
||||||
|
|
||||||
console.warn(
|
|
||||||
"Content block not found. Sphinx search tries to obtain it via DOM query '[role=main]'. Check your theme or template."
|
|
||||||
);
|
|
||||||
return "";
|
|
||||||
},
|
|
||||||
|
|
||||||
init: () => {
|
|
||||||
const query = new URLSearchParams(window.location.search).get("q");
|
|
||||||
document
|
|
||||||
.querySelectorAll('input[name="q"]')
|
|
||||||
.forEach((el) => (el.value = query));
|
|
||||||
if (query) Search.performSearch(query);
|
|
||||||
},
|
|
||||||
|
|
||||||
loadIndex: (url) =>
|
|
||||||
(document.body.appendChild(document.createElement("script")).src = url),
|
|
||||||
|
|
||||||
setIndex: (index) => {
|
|
||||||
Search._index = index;
|
|
||||||
if (Search._queued_query !== null) {
|
|
||||||
const query = Search._queued_query;
|
|
||||||
Search._queued_query = null;
|
|
||||||
Search.query(query);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
hasIndex: () => Search._index !== null,
|
|
||||||
|
|
||||||
deferQuery: (query) => (Search._queued_query = query),
|
|
||||||
|
|
||||||
stopPulse: () => (Search._pulse_status = -1),
|
|
||||||
|
|
||||||
startPulse: () => {
|
|
||||||
if (Search._pulse_status >= 0) return;
|
|
||||||
|
|
||||||
const pulse = () => {
|
|
||||||
Search._pulse_status = (Search._pulse_status + 1) % 4;
|
|
||||||
Search.dots.innerText = ".".repeat(Search._pulse_status);
|
|
||||||
if (Search._pulse_status >= 0) window.setTimeout(pulse, 500);
|
|
||||||
};
|
|
||||||
pulse();
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* perform a search for something (or wait until index is loaded)
|
|
||||||
*/
|
|
||||||
performSearch: (query) => {
|
|
||||||
// create the required interface elements
|
|
||||||
const searchText = document.createElement("h2");
|
|
||||||
searchText.textContent = _("Searching");
|
|
||||||
const searchSummary = document.createElement("p");
|
|
||||||
searchSummary.classList.add("search-summary");
|
|
||||||
searchSummary.innerText = "";
|
|
||||||
const searchList = document.createElement("ul");
|
|
||||||
searchList.setAttribute("role", "list");
|
|
||||||
searchList.classList.add("search");
|
|
||||||
|
|
||||||
const out = document.getElementById("search-results");
|
|
||||||
Search.title = out.appendChild(searchText);
|
|
||||||
Search.dots = Search.title.appendChild(document.createElement("span"));
|
|
||||||
Search.status = out.appendChild(searchSummary);
|
|
||||||
Search.output = out.appendChild(searchList);
|
|
||||||
|
|
||||||
const searchProgress = document.getElementById("search-progress");
|
|
||||||
// Some themes don't use the search progress node
|
|
||||||
if (searchProgress) {
|
|
||||||
searchProgress.innerText = _("Preparing search...");
|
|
||||||
}
|
|
||||||
Search.startPulse();
|
|
||||||
|
|
||||||
// index already loaded, the browser was quick!
|
|
||||||
if (Search.hasIndex()) Search.query(query);
|
|
||||||
else Search.deferQuery(query);
|
|
||||||
},
|
|
||||||
|
|
||||||
_parseQuery: (query) => {
|
|
||||||
// stem the search terms and add them to the correct list
|
|
||||||
const stemmer = new Stemmer();
|
|
||||||
const searchTerms = new Set();
|
|
||||||
const excludedTerms = new Set();
|
|
||||||
const highlightTerms = new Set();
|
|
||||||
const objectTerms = new Set(splitQuery(query.toLowerCase().trim()));
|
|
||||||
splitQuery(query.trim()).forEach((queryTerm) => {
|
|
||||||
const queryTermLower = queryTerm.toLowerCase();
|
|
||||||
|
|
||||||
// maybe skip this "word"
|
|
||||||
// stopwords array is from language_data.js
|
|
||||||
if (
|
|
||||||
stopwords.indexOf(queryTermLower) !== -1 ||
|
|
||||||
queryTerm.match(/^\d+$/)
|
|
||||||
)
|
|
||||||
return;
|
|
||||||
|
|
||||||
// stem the word
|
|
||||||
let word = stemmer.stemWord(queryTermLower);
|
|
||||||
// select the correct list
|
|
||||||
if (word[0] === "-") excludedTerms.add(word.substr(1));
|
|
||||||
else {
|
|
||||||
searchTerms.add(word);
|
|
||||||
highlightTerms.add(queryTermLower);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
if (SPHINX_HIGHLIGHT_ENABLED) { // set in sphinx_highlight.js
|
|
||||||
localStorage.setItem("sphinx_highlight_terms", [...highlightTerms].join(" "))
|
|
||||||
}
|
|
||||||
|
|
||||||
// console.debug("SEARCH: searching for:");
|
|
||||||
// console.info("required: ", [...searchTerms]);
|
|
||||||
// console.info("excluded: ", [...excludedTerms]);
|
|
||||||
|
|
||||||
return [query, searchTerms, excludedTerms, highlightTerms, objectTerms];
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* execute search (requires search index to be loaded)
|
|
||||||
*/
|
|
||||||
_performSearch: (query, searchTerms, excludedTerms, highlightTerms, objectTerms) => {
|
|
||||||
const filenames = Search._index.filenames;
|
|
||||||
const docNames = Search._index.docnames;
|
|
||||||
const titles = Search._index.titles;
|
|
||||||
const allTitles = Search._index.alltitles;
|
|
||||||
const indexEntries = Search._index.indexentries;
|
|
||||||
|
|
||||||
// Collect multiple result groups to be sorted separately and then ordered.
|
|
||||||
// Each is an array of [docname, title, anchor, descr, score, filename, kind].
|
|
||||||
const normalResults = [];
|
|
||||||
const nonMainIndexResults = [];
|
|
||||||
|
|
||||||
_removeChildren(document.getElementById("search-progress"));
|
|
||||||
|
|
||||||
const queryLower = query.toLowerCase().trim();
|
|
||||||
for (const [title, foundTitles] of Object.entries(allTitles)) {
|
|
||||||
if (title.toLowerCase().trim().includes(queryLower) && (queryLower.length >= title.length/2)) {
|
|
||||||
for (const [file, id] of foundTitles) {
|
|
||||||
const score = Math.round(Scorer.title * queryLower.length / title.length);
|
|
||||||
const boost = titles[file] === title ? 1 : 0; // add a boost for document titles
|
|
||||||
normalResults.push([
|
|
||||||
docNames[file],
|
|
||||||
titles[file] !== title ? `${titles[file]} > ${title}` : title,
|
|
||||||
id !== null ? "#" + id : "",
|
|
||||||
null,
|
|
||||||
score + boost,
|
|
||||||
filenames[file],
|
|
||||||
SearchResultKind.title,
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// search for explicit entries in index directives
|
|
||||||
for (const [entry, foundEntries] of Object.entries(indexEntries)) {
|
|
||||||
if (entry.includes(queryLower) && (queryLower.length >= entry.length/2)) {
|
|
||||||
for (const [file, id, isMain] of foundEntries) {
|
|
||||||
const score = Math.round(100 * queryLower.length / entry.length);
|
|
||||||
const result = [
|
|
||||||
docNames[file],
|
|
||||||
titles[file],
|
|
||||||
id ? "#" + id : "",
|
|
||||||
null,
|
|
||||||
score,
|
|
||||||
filenames[file],
|
|
||||||
SearchResultKind.index,
|
|
||||||
];
|
|
||||||
if (isMain) {
|
|
||||||
normalResults.push(result);
|
|
||||||
} else {
|
|
||||||
nonMainIndexResults.push(result);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// lookup as object
|
|
||||||
objectTerms.forEach((term) =>
|
|
||||||
normalResults.push(...Search.performObjectSearch(term, objectTerms))
|
|
||||||
);
|
|
||||||
|
|
||||||
// lookup as search terms in fulltext
|
|
||||||
normalResults.push(...Search.performTermsSearch(searchTerms, excludedTerms));
|
|
||||||
|
|
||||||
// let the scorer override scores with a custom scoring function
|
|
||||||
if (Scorer.score) {
|
|
||||||
normalResults.forEach((item) => (item[4] = Scorer.score(item)));
|
|
||||||
nonMainIndexResults.forEach((item) => (item[4] = Scorer.score(item)));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Sort each group of results by score and then alphabetically by name.
|
|
||||||
normalResults.sort(_orderResultsByScoreThenName);
|
|
||||||
nonMainIndexResults.sort(_orderResultsByScoreThenName);
|
|
||||||
|
|
||||||
// Combine the result groups in (reverse) order.
|
|
||||||
// Non-main index entries are typically arbitrary cross-references,
|
|
||||||
// so display them after other results.
|
|
||||||
let results = [...nonMainIndexResults, ...normalResults];
|
|
||||||
|
|
||||||
// remove duplicate search results
|
|
||||||
// note the reversing of results, so that in the case of duplicates, the highest-scoring entry is kept
|
|
||||||
let seen = new Set();
|
|
||||||
results = results.reverse().reduce((acc, result) => {
|
|
||||||
let resultStr = result.slice(0, 4).concat([result[5]]).map(v => String(v)).join(',');
|
|
||||||
if (!seen.has(resultStr)) {
|
|
||||||
acc.push(result);
|
|
||||||
seen.add(resultStr);
|
|
||||||
}
|
|
||||||
return acc;
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
return results.reverse();
|
|
||||||
},
|
|
||||||
|
|
||||||
query: (query) => {
|
|
||||||
const [searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms] = Search._parseQuery(query);
|
|
||||||
const results = Search._performSearch(searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms);
|
|
||||||
|
|
||||||
// for debugging
|
|
||||||
//Search.lastresults = results.slice(); // a copy
|
|
||||||
// console.info("search results:", Search.lastresults);
|
|
||||||
|
|
||||||
// print the results
|
|
||||||
_displayNextItem(results, results.length, searchTerms, highlightTerms);
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* search for object names
|
|
||||||
*/
|
|
||||||
performObjectSearch: (object, objectTerms) => {
|
|
||||||
const filenames = Search._index.filenames;
|
|
||||||
const docNames = Search._index.docnames;
|
|
||||||
const objects = Search._index.objects;
|
|
||||||
const objNames = Search._index.objnames;
|
|
||||||
const titles = Search._index.titles;
|
|
||||||
|
|
||||||
const results = [];
|
|
||||||
|
|
||||||
const objectSearchCallback = (prefix, match) => {
|
|
||||||
const name = match[4]
|
|
||||||
const fullname = (prefix ? prefix + "." : "") + name;
|
|
||||||
const fullnameLower = fullname.toLowerCase();
|
|
||||||
if (fullnameLower.indexOf(object) < 0) return;
|
|
||||||
|
|
||||||
let score = 0;
|
|
||||||
const parts = fullnameLower.split(".");
|
|
||||||
|
|
||||||
// check for different match types: exact matches of full name or
|
|
||||||
// "last name" (i.e. last dotted part)
|
|
||||||
if (fullnameLower === object || parts.slice(-1)[0] === object)
|
|
||||||
score += Scorer.objNameMatch;
|
|
||||||
else if (parts.slice(-1)[0].indexOf(object) > -1)
|
|
||||||
score += Scorer.objPartialMatch; // matches in last name
|
|
||||||
|
|
||||||
const objName = objNames[match[1]][2];
|
|
||||||
const title = titles[match[0]];
|
|
||||||
|
|
||||||
// If more than one term searched for, we require other words to be
|
|
||||||
// found in the name/title/description
|
|
||||||
const otherTerms = new Set(objectTerms);
|
|
||||||
otherTerms.delete(object);
|
|
||||||
if (otherTerms.size > 0) {
|
|
||||||
const haystack = `${prefix} ${name} ${objName} ${title}`.toLowerCase();
|
|
||||||
if (
|
|
||||||
[...otherTerms].some((otherTerm) => haystack.indexOf(otherTerm) < 0)
|
|
||||||
)
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
let anchor = match[3];
|
|
||||||
if (anchor === "") anchor = fullname;
|
|
||||||
else if (anchor === "-") anchor = objNames[match[1]][1] + "-" + fullname;
|
|
||||||
|
|
||||||
const descr = objName + _(", in ") + title;
|
|
||||||
|
|
||||||
// add custom score for some objects according to scorer
|
|
||||||
if (Scorer.objPrio.hasOwnProperty(match[2]))
|
|
||||||
score += Scorer.objPrio[match[2]];
|
|
||||||
else score += Scorer.objPrioDefault;
|
|
||||||
|
|
||||||
results.push([
|
|
||||||
docNames[match[0]],
|
|
||||||
fullname,
|
|
||||||
"#" + anchor,
|
|
||||||
descr,
|
|
||||||
score,
|
|
||||||
filenames[match[0]],
|
|
||||||
SearchResultKind.object,
|
|
||||||
]);
|
|
||||||
};
|
|
||||||
Object.keys(objects).forEach((prefix) =>
|
|
||||||
objects[prefix].forEach((array) =>
|
|
||||||
objectSearchCallback(prefix, array)
|
|
||||||
)
|
|
||||||
);
|
|
||||||
return results;
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* search for full-text terms in the index
|
|
||||||
*/
|
|
||||||
performTermsSearch: (searchTerms, excludedTerms) => {
|
|
||||||
// prepare search
|
|
||||||
const terms = Search._index.terms;
|
|
||||||
const titleTerms = Search._index.titleterms;
|
|
||||||
const filenames = Search._index.filenames;
|
|
||||||
const docNames = Search._index.docnames;
|
|
||||||
const titles = Search._index.titles;
|
|
||||||
|
|
||||||
const scoreMap = new Map();
|
|
||||||
const fileMap = new Map();
|
|
||||||
|
|
||||||
// perform the search on the required terms
|
|
||||||
searchTerms.forEach((word) => {
|
|
||||||
const files = [];
|
|
||||||
// find documents, if any, containing the query word in their text/title term indices
|
|
||||||
// use Object.hasOwnProperty to avoid mismatching against prototype properties
|
|
||||||
const arr = [
|
|
||||||
{ files: terms.hasOwnProperty(word) ? terms[word] : undefined, score: Scorer.term },
|
|
||||||
{ files: titleTerms.hasOwnProperty(word) ? titleTerms[word] : undefined, score: Scorer.title },
|
|
||||||
];
|
|
||||||
// add support for partial matches
|
|
||||||
if (word.length > 2) {
|
|
||||||
const escapedWord = _escapeRegExp(word);
|
|
||||||
if (!terms.hasOwnProperty(word)) {
|
|
||||||
Object.keys(terms).forEach((term) => {
|
|
||||||
if (term.match(escapedWord))
|
|
||||||
arr.push({ files: terms[term], score: Scorer.partialTerm });
|
|
||||||
});
|
|
||||||
}
|
|
||||||
if (!titleTerms.hasOwnProperty(word)) {
|
|
||||||
Object.keys(titleTerms).forEach((term) => {
|
|
||||||
if (term.match(escapedWord))
|
|
||||||
arr.push({ files: titleTerms[term], score: Scorer.partialTitle });
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// no match but word was a required one
|
|
||||||
if (arr.every((record) => record.files === undefined)) return;
|
|
||||||
|
|
||||||
// found search word in contents
|
|
||||||
arr.forEach((record) => {
|
|
||||||
if (record.files === undefined) return;
|
|
||||||
|
|
||||||
let recordFiles = record.files;
|
|
||||||
if (recordFiles.length === undefined) recordFiles = [recordFiles];
|
|
||||||
files.push(...recordFiles);
|
|
||||||
|
|
||||||
// set score for the word in each file
|
|
||||||
recordFiles.forEach((file) => {
|
|
||||||
if (!scoreMap.has(file)) scoreMap.set(file, new Map());
|
|
||||||
const fileScores = scoreMap.get(file);
|
|
||||||
fileScores.set(word, record.score);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
// create the mapping
|
|
||||||
files.forEach((file) => {
|
|
||||||
if (!fileMap.has(file)) fileMap.set(file, [word]);
|
|
||||||
else if (fileMap.get(file).indexOf(word) === -1) fileMap.get(file).push(word);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
// now check if the files don't contain excluded terms
|
|
||||||
const results = [];
|
|
||||||
for (const [file, wordList] of fileMap) {
|
|
||||||
// check if all requirements are matched
|
|
||||||
|
|
||||||
// as search terms with length < 3 are discarded
|
|
||||||
const filteredTermCount = [...searchTerms].filter(
|
|
||||||
(term) => term.length > 2
|
|
||||||
).length;
|
|
||||||
if (
|
|
||||||
wordList.length !== searchTerms.size &&
|
|
||||||
wordList.length !== filteredTermCount
|
|
||||||
)
|
|
||||||
continue;
|
|
||||||
|
|
||||||
// ensure that none of the excluded terms is in the search result
|
|
||||||
if (
|
|
||||||
[...excludedTerms].some(
|
|
||||||
(term) =>
|
|
||||||
terms[term] === file ||
|
|
||||||
titleTerms[term] === file ||
|
|
||||||
(terms[term] || []).includes(file) ||
|
|
||||||
(titleTerms[term] || []).includes(file)
|
|
||||||
)
|
|
||||||
)
|
|
||||||
break;
|
|
||||||
|
|
||||||
// select one (max) score for the file.
|
|
||||||
const score = Math.max(...wordList.map((w) => scoreMap.get(file).get(w)));
|
|
||||||
// add result to the result list
|
|
||||||
results.push([
|
|
||||||
docNames[file],
|
|
||||||
titles[file],
|
|
||||||
"",
|
|
||||||
null,
|
|
||||||
score,
|
|
||||||
filenames[file],
|
|
||||||
SearchResultKind.text,
|
|
||||||
]);
|
|
||||||
}
|
|
||||||
return results;
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* helper function to return a node containing the
|
|
||||||
* search summary for a given text. keywords is a list
|
|
||||||
* of stemmed words.
|
|
||||||
*/
|
|
||||||
makeSearchSummary: (htmlText, keywords, anchor) => {
|
|
||||||
const text = Search.htmlToText(htmlText, anchor);
|
|
||||||
if (text === "") return null;
|
|
||||||
|
|
||||||
const textLower = text.toLowerCase();
|
|
||||||
const actualStartPosition = [...keywords]
|
|
||||||
.map((k) => textLower.indexOf(k.toLowerCase()))
|
|
||||||
.filter((i) => i > -1)
|
|
||||||
.slice(-1)[0];
|
|
||||||
const startWithContext = Math.max(actualStartPosition - 120, 0);
|
|
||||||
|
|
||||||
const top = startWithContext === 0 ? "" : "...";
|
|
||||||
const tail = startWithContext + 240 < text.length ? "..." : "";
|
|
||||||
|
|
||||||
let summary = document.createElement("p");
|
|
||||||
summary.classList.add("context");
|
|
||||||
summary.textContent = top + text.substr(startWithContext, 240).trim() + tail;
|
|
||||||
|
|
||||||
return summary;
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
_ready(Search.init);
|
|
|
@ -1,154 +0,0 @@
|
||||||
/* Highlighting utilities for Sphinx HTML documentation. */
|
|
||||||
"use strict";
|
|
||||||
|
|
||||||
const SPHINX_HIGHLIGHT_ENABLED = true
|
|
||||||
|
|
||||||
/**
|
|
||||||
* highlight a given string on a node by wrapping it in
|
|
||||||
* span elements with the given class name.
|
|
||||||
*/
|
|
||||||
const _highlight = (node, addItems, text, className) => {
|
|
||||||
if (node.nodeType === Node.TEXT_NODE) {
|
|
||||||
const val = node.nodeValue;
|
|
||||||
const parent = node.parentNode;
|
|
||||||
const pos = val.toLowerCase().indexOf(text);
|
|
||||||
if (
|
|
||||||
pos >= 0 &&
|
|
||||||
!parent.classList.contains(className) &&
|
|
||||||
!parent.classList.contains("nohighlight")
|
|
||||||
) {
|
|
||||||
let span;
|
|
||||||
|
|
||||||
const closestNode = parent.closest("body, svg, foreignObject");
|
|
||||||
const isInSVG = closestNode && closestNode.matches("svg");
|
|
||||||
if (isInSVG) {
|
|
||||||
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
|
|
||||||
} else {
|
|
||||||
span = document.createElement("span");
|
|
||||||
span.classList.add(className);
|
|
||||||
}
|
|
||||||
|
|
||||||
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
|
|
||||||
const rest = document.createTextNode(val.substr(pos + text.length));
|
|
||||||
parent.insertBefore(
|
|
||||||
span,
|
|
||||||
parent.insertBefore(
|
|
||||||
rest,
|
|
||||||
node.nextSibling
|
|
||||||
)
|
|
||||||
);
|
|
||||||
node.nodeValue = val.substr(0, pos);
|
|
||||||
/* There may be more occurrences of search term in this node. So call this
|
|
||||||
* function recursively on the remaining fragment.
|
|
||||||
*/
|
|
||||||
_highlight(rest, addItems, text, className);
|
|
||||||
|
|
||||||
if (isInSVG) {
|
|
||||||
const rect = document.createElementNS(
|
|
||||||
"http://www.w3.org/2000/svg",
|
|
||||||
"rect"
|
|
||||||
);
|
|
||||||
const bbox = parent.getBBox();
|
|
||||||
rect.x.baseVal.value = bbox.x;
|
|
||||||
rect.y.baseVal.value = bbox.y;
|
|
||||||
rect.width.baseVal.value = bbox.width;
|
|
||||||
rect.height.baseVal.value = bbox.height;
|
|
||||||
rect.setAttribute("class", className);
|
|
||||||
addItems.push({ parent: parent, target: rect });
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (node.matches && !node.matches("button, select, textarea")) {
|
|
||||||
node.childNodes.forEach((el) => _highlight(el, addItems, text, className));
|
|
||||||
}
|
|
||||||
};
|
|
||||||
const _highlightText = (thisNode, text, className) => {
|
|
||||||
let addItems = [];
|
|
||||||
_highlight(thisNode, addItems, text, className);
|
|
||||||
addItems.forEach((obj) =>
|
|
||||||
obj.parent.insertAdjacentElement("beforebegin", obj.target)
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Small JavaScript module for the documentation.
|
|
||||||
*/
|
|
||||||
const SphinxHighlight = {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* highlight the search words provided in localstorage in the text
|
|
||||||
*/
|
|
||||||
highlightSearchWords: () => {
|
|
||||||
if (!SPHINX_HIGHLIGHT_ENABLED) return; // bail if no highlight
|
|
||||||
|
|
||||||
// get and clear terms from localstorage
|
|
||||||
const url = new URL(window.location);
|
|
||||||
const highlight =
|
|
||||||
localStorage.getItem("sphinx_highlight_terms")
|
|
||||||
|| url.searchParams.get("highlight")
|
|
||||||
|| "";
|
|
||||||
localStorage.removeItem("sphinx_highlight_terms")
|
|
||||||
url.searchParams.delete("highlight");
|
|
||||||
window.history.replaceState({}, "", url);
|
|
||||||
|
|
||||||
// get individual terms from highlight string
|
|
||||||
const terms = highlight.toLowerCase().split(/\s+/).filter(x => x);
|
|
||||||
if (terms.length === 0) return; // nothing to do
|
|
||||||
|
|
||||||
// There should never be more than one element matching "div.body"
|
|
||||||
const divBody = document.querySelectorAll("div.body");
|
|
||||||
const body = divBody.length ? divBody[0] : document.querySelector("body");
|
|
||||||
window.setTimeout(() => {
|
|
||||||
terms.forEach((term) => _highlightText(body, term, "highlighted"));
|
|
||||||
}, 10);
|
|
||||||
|
|
||||||
const searchBox = document.getElementById("searchbox");
|
|
||||||
if (searchBox === null) return;
|
|
||||||
searchBox.appendChild(
|
|
||||||
document
|
|
||||||
.createRange()
|
|
||||||
.createContextualFragment(
|
|
||||||
'<p class="highlight-link">' +
|
|
||||||
'<a href="javascript:SphinxHighlight.hideSearchWords()">' +
|
|
||||||
_("Hide Search Matches") +
|
|
||||||
"</a></p>"
|
|
||||||
)
|
|
||||||
);
|
|
||||||
},
|
|
||||||
|
|
||||||
/**
|
|
||||||
* helper function to hide the search marks again
|
|
||||||
*/
|
|
||||||
hideSearchWords: () => {
|
|
||||||
document
|
|
||||||
.querySelectorAll("#searchbox .highlight-link")
|
|
||||||
.forEach((el) => el.remove());
|
|
||||||
document
|
|
||||||
.querySelectorAll("span.highlighted")
|
|
||||||
.forEach((el) => el.classList.remove("highlighted"));
|
|
||||||
localStorage.removeItem("sphinx_highlight_terms")
|
|
||||||
},
|
|
||||||
|
|
||||||
initEscapeListener: () => {
|
|
||||||
// only install a listener if it is really needed
|
|
||||||
if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) return;
|
|
||||||
|
|
||||||
document.addEventListener("keydown", (event) => {
|
|
||||||
// bail for input elements
|
|
||||||
if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return;
|
|
||||||
// bail with special keys
|
|
||||||
if (event.shiftKey || event.altKey || event.ctrlKey || event.metaKey) return;
|
|
||||||
if (DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS && (event.key === "Escape")) {
|
|
||||||
SphinxHighlight.hideSearchWords();
|
|
||||||
event.preventDefault();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
_ready(() => {
|
|
||||||
/* Do not call highlightSearchWords() when we are on the search page.
|
|
||||||
* It will highlight words from the *previous* search query.
|
|
||||||
*/
|
|
||||||
if (typeof Search === "undefined") SphinxHighlight.highlightSearchWords();
|
|
||||||
SphinxHighlight.initEscapeListener();
|
|
||||||
});
|
|
|
@ -1,655 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.api_find_and_modify module – Find and modify information using the API" href="api_find_and_modify_module.html" />
|
|
||||||
<link rel="prev" title="community.routeros.api module – Ansible module for RouterOS API" href="api_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#requirements">Requirements</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#returned-facts">Returned Facts</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/api_facts.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-api-facts-module"></span><section id="community-routeros-api-facts-module-collect-facts-from-remote-devices-running-mikrotik-routeros-using-the-api">
|
|
||||||
<h1>community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API<a class="headerlink" href="#community-routeros-api-facts-module-collect-facts-from-remote-devices-running-mikrotik-routeros-using-the-api" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.
|
|
||||||
You need further requirements to be able to use this module,
|
|
||||||
see <a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-requirements"><span class="std std-ref">Requirements</span></a> for details.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.api_facts</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.1.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#requirements" id="id2">Requirements</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id3">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id4">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id5">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id6">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#returned-facts" id="id7">Returned Facts</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Collects a base set of device facts from a remote device that is running RouterOS. This module prepends all of the base network fact keys with <code class="docutils literal notranslate"><span class="pre">ansible_net_<fact></span></code>. The facts module will always collect a base set of facts from the device and can enable or disable collection of additional facts.</p></li>
|
|
||||||
<li><p>As opposed to the <a class="reference internal" href="facts_module.html#ansible-collections-community-routeros-facts-module"><span class="std std-ref">community.routeros.facts</span></a> module, it uses the RouterOS API, similar to the <a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api</span></a> module.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="requirements">
|
|
||||||
<span id="ansible-collections-community-routeros-api-facts-module-requirements"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Requirements</a><a class="headerlink" href="#requirements" title="Link to this heading"></a></h2>
|
|
||||||
<p>The below requirements are needed on the host that executes this module.</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>librouteros</p></li>
|
|
||||||
<li><p>Python >= 3.6 (for librouteros)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ca_path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-ca-path"><strong>ca_path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ca_path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">path</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>PEM formatted file that contains a CA certificate to be used for certificate validation.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-encoding"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-encoding"><strong>encoding</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-encoding" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use the specified encoding when communicating with the RouterOS device.</p>
|
|
||||||
<p>Default is <code class="ansible-value docutils literal notranslate"><span class="pre">ASCII</span></code>. Note that <code class="ansible-value docutils literal notranslate"><span class="pre">UTF-8</span></code> requires librouteros 3.2.1 or newer.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">"ASCII"</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-force_no_cert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-force-no-cert"><strong>force_no_cert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-force_no_cert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to connect without a certificate when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>.</p>
|
|
||||||
<p><strong>Note:</strong> this forces the use of anonymous Diffie-Hellman (ADH) ciphers. The protocol is susceptible to Man-in-the-Middle attacks, because the keys used in the exchange are not authenticated. Instead of simply connecting without a certificate to “make things work” have a look at <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-gather_subset"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><strong>gather_subset</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-gather_subset" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>When supplied, this argument will restrict the facts collected to a given subset. Possible values for this argument include <code class="ansible-value docutils literal notranslate"><span class="pre">all</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code>, and <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code>.</p>
|
|
||||||
<p>Can specify a list of values to include a larger subset. Values can also be used with an initial <code class="ansible-value docutils literal notranslate"><span class="pre">!</span></code> to specify that a specific subset should not be collected.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">["all"]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-hostname"><strong>hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS hostname API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-password"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-password"><strong>password</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-password" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS user password.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-port"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-port"><strong>port</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-port" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS api port. If <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-tls"><span class="std std-ref"><span class="pre">tls</span></span></a></strong></code> is set, port will apply to TLS/SSL connection.</p>
|
|
||||||
<p>Defaults are <code class="ansible-value docutils literal notranslate"><span class="pre">8728</span></code> for the HTTP API, and <code class="ansible-value docutils literal notranslate"><span class="pre">8729</span></code> for the HTTPS API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-timeout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-timeout"><strong>timeout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-timeout" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.3.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Timeout for the request.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-tls"></div>
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ssl"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-tls"><span id="ansible-collections-community-routeros-api-facts-module-parameter-ssl"></span><strong>tls</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-tls" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-aliases">aliases: ssl</span></p>
|
|
||||||
<p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>If is set TLS will be used for RouterOS API connection.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-username"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-username"><strong>username</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-username" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS login user.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_cert_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-validate-cert-hostname"><strong>validate_cert_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_cert_hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to validate hostnames in certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_certs"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-parameter-validate-certs"><strong>validate_certs</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_certs" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> to skip validation of TLS certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p><strong>Note:</strong> instead of simply deactivating certificate validations to “make things work”, please consider creating your own CA certificate and using it to sign certificates used for your router. You can tell the module about your CA certificate with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code> option.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-action_group"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-attribute-action-group"><strong>action_group</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-action_group" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Action group:</strong> <strong class="ansible-attribute-support-full">community.routeros.api</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use <code class="docutils literal notranslate"><span class="pre">group/community.routeros.api</span></code> in <code class="docutils literal notranslate"><span class="pre">module_defaults</span></code> to set defaults for this module.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong> <span class="ansible-attribute-support-na">N/A</span></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-facts"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-attribute-facts"><strong>facts</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-facts" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Action returns an <code class="docutils literal notranslate"><span class="pre">ansible_facts</span></code> dictionary that will update existing host facts.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="facts_module.html#ansible-collections-community-routeros-facts-module"><span class="std std-ref">community.routeros.facts</span></a></dt><dd><p>Collect facts from remote devices running MikroTik RouterOS.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api</span></a></dt><dd><p>Ansible module for RouterOS API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a></dt><dd><p>Find and modify information using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a></dt><dd><p>Retrieve information from API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a></dt><dd><p>Modify data at paths with API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/api-guide.html#ansible-collections-community-routeros-docsite-api-guide"><span class="std std-ref">How to connect to RouterOS devices with the RouterOS API</span></a></dt><dd><p>How to connect to RouterOS devices with the RouterOS API</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Collect all facts from the device</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_facts</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.88.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">admin</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">password</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_subset</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">all</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Do not collect hardware facts</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_facts</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.88.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">admin</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">password</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_subset</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="s">"!hardware"</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="returned-facts">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Returned Facts</a><a class="headerlink" href="#returned-facts" title="Link to this heading"></a></h2>
|
|
||||||
<p>Facts returned by this module are added/updated in the <code class="docutils literal notranslate"><span class="pre">hostvars</span></code> host facts and can be referenced by name just like any other host fact. They do not need to be registered in order to use them.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_all_ipv4_addresses"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-all-ipv4-addresses"><strong>ansible_net_all_ipv4_addresses</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_all_ipv4_addresses" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>All IPv4 addresses configured on the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_all_ipv6_addresses"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-all-ipv6-addresses"><strong>ansible_net_all_ipv6_addresses</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_all_ipv6_addresses" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>All IPv6 addresses configured on the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_arch"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-arch"><strong>ansible_net_arch</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_arch" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The CPU architecture of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_instance"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-bgp-instance"><strong>ansible_net_bgp_instance</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_instance" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP instance information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_peer"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-bgp-peer"><strong>ansible_net_bgp_peer</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_peer" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP peer information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_vpnv4_route"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-bgp-vpnv4-route"><strong>ansible_net_bgp_vpnv4_route</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_vpnv4_route" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP vpnv4 route information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_cpu_load"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-cpu-load"><strong>ansible_net_cpu_load</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_cpu_load" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Current CPU load.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_gather_subset"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-gather-subset"><strong>ansible_net_gather_subset</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_gather_subset" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of fact subsets collected from the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-hostname"><strong>ansible_net_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_hostname" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The configured hostname of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_interfaces"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-interfaces"><strong>ansible_net_interfaces</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_interfaces" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A hash of all interfaces running on the system.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_memfree_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-memfree-mb"><strong>ansible_net_memfree_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_memfree_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The available free memory on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_memtotal_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-memtotal-mb"><strong>ansible_net_memtotal_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_memtotal_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The total memory on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_model"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-model"><strong>ansible_net_model</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_model" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The model name returned from the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_neighbors"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-neighbors"><strong>ansible_net_neighbors</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_neighbors" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of neighbors from the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_ospf_instance"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-ospf-instance"><strong>ansible_net_ospf_instance</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_ospf_instance" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with OSPF instances.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_ospf_neighbor"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-ospf-neighbor"><strong>ansible_net_ospf_neighbor</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_ospf_neighbor" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with OSPF neighbors.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_route"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-route"><strong>ansible_net_route</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_route" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary for routes in all routing tables.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_serialnum"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-serialnum"><strong>ansible_net_serialnum</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_serialnum" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The serial number of the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_spacefree_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-spacefree-mb"><strong>ansible_net_spacefree_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_spacefree_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The available disk space on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_spacetotal_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-spacetotal-mb"><strong>ansible_net_spacetotal_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_spacetotal_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The total disk space on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_uptime"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-uptime"><strong>ansible_net_uptime</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_uptime" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The uptime of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_version"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-facts-module-return-ansible-facts-ansible-net-version"><strong>ansible_net_version</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_version" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The operating system version running on the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Egor Zaitsev (@heuels)</p></li>
|
|
||||||
<li><p>Nikolay Dachev (@NikolayDachev)</p></li>
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api_module.html" class="btn btn-neutral float-left" title="community.routeros.api module – Ansible module for RouterOS API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="api_find_and_modify_module.html" class="btn btn-neutral float-right" title="community.routeros.api_find_and_modify module – Find and modify information using the API" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,572 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.api_find_and_modify module – Find and modify information using the API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.api_info module – Retrieve information from API" href="api_info_module.html" />
|
|
||||||
<link rel="prev" title="community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API" href="api_facts_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.api_find_and_modify module – Find and modify information using the API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#requirements">Requirements</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#notes">Notes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-values">Return Values</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.api_find_and_modify module – Find and modify information using the API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/api_find_and_modify.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-api-find-and-modify-module"></span><section id="community-routeros-api-find-and-modify-module-find-and-modify-information-using-the-api">
|
|
||||||
<h1>community.routeros.api_find_and_modify module – Find and modify information using the API<a class="headerlink" href="#community-routeros-api-find-and-modify-module-find-and-modify-information-using-the-api" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.
|
|
||||||
You need further requirements to be able to use this module,
|
|
||||||
see <a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-requirements"><span class="std std-ref">Requirements</span></a> for details.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.api_find_and_modify</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.1.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#requirements" id="id2">Requirements</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id3">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id4">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#notes" id="id5">Notes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id6">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id7">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-values" id="id8">Return Values</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Allows to find entries for a path by conditions and modify the values of these entries.</p></li>
|
|
||||||
<li><p>Use the <a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a> module to set all entries of a path to specific values, or change multiple entries in different ways in one step.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="requirements">
|
|
||||||
<span id="ansible-collections-community-routeros-api-find-and-modify-module-requirements"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Requirements</a><a class="headerlink" href="#requirements" title="Link to this heading"></a></h2>
|
|
||||||
<p>The below requirements are needed on the host that executes this module.</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>librouteros</p></li>
|
|
||||||
<li><p>Python >= 3.6 (for librouteros)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-allow_no_matches"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-allow-no-matches"><strong>allow_no_matches</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-allow_no_matches" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to allow that no match is found.</p>
|
|
||||||
<p>If not specified, this value is induced from whether <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-require-matches-min"><span class="std std-ref"><span class="pre">require_matches_min</span></span></a></strong></code> is 0 or larger.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ca_path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-ca-path"><strong>ca_path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ca_path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">path</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>PEM formatted file that contains a CA certificate to be used for certificate validation.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-encoding"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-encoding"><strong>encoding</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-encoding" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use the specified encoding when communicating with the RouterOS device.</p>
|
|
||||||
<p>Default is <code class="ansible-value docutils literal notranslate"><span class="pre">ASCII</span></code>. Note that <code class="ansible-value docutils literal notranslate"><span class="pre">UTF-8</span></code> requires librouteros 3.2.1 or newer.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">"ASCII"</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-find"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-find"><strong>find</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-find" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Fields to search for.</p>
|
|
||||||
<p>The module will only consider entries in the given <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-path"><span class="std std-ref"><span class="pre">path</span></span></a></strong></code> that match all fields provided here.</p>
|
|
||||||
<p>Use YAML <code class="ansible-value docutils literal notranslate"><span class="pre">~</span></code>, or prepend keys with <code class="ansible-value docutils literal notranslate"><span class="pre">!</span></code>, to specify an unset value.</p>
|
|
||||||
<p>Note that if the dictionary specified here is empty, every entry in the path will be matched.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-force_no_cert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-force-no-cert"><strong>force_no_cert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-force_no_cert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to connect without a certificate when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>.</p>
|
|
||||||
<p><strong>Note:</strong> this forces the use of anonymous Diffie-Hellman (ADH) ciphers. The protocol is susceptible to Man-in-the-Middle attacks, because the keys used in the exchange are not authenticated. Instead of simply connecting without a certificate to “make things work” have a look at <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-hostname"><strong>hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS hostname API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-password"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-password"><strong>password</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-password" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS user password.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-path"><strong>path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Path to query.</p>
|
|
||||||
<p>An example value is <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code>. This is equivalent to running <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span></code> in the RouterOS CLI.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-port"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-port"><strong>port</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-port" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS api port. If <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls</span></span></a></strong></code> is set, port will apply to TLS/SSL connection.</p>
|
|
||||||
<p>Defaults are <code class="ansible-value docutils literal notranslate"><span class="pre">8728</span></code> for the HTTP API, and <code class="ansible-value docutils literal notranslate"><span class="pre">8729</span></code> for the HTTPS API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-require_matches_max"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-require-matches-max"><strong>require_matches_max</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-require_matches_max" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Make sure that there are no more matches than this number.</p>
|
|
||||||
<p>If there are more matches, fail instead of modifying anything.</p>
|
|
||||||
<p>If not specified, there is no upper limit.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-require_matches_min"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-require-matches-min"><strong>require_matches_min</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-require_matches_min" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Make sure that there are no less matches than this number.</p>
|
|
||||||
<p>If there are less matches, fail instead of modifying anything.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">0</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-timeout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-timeout"><strong>timeout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-timeout" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.3.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Timeout for the request.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-tls"></div>
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ssl"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-ssl"></span><strong>tls</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-tls" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-aliases">aliases: ssl</span></p>
|
|
||||||
<p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>If is set TLS will be used for RouterOS API connection.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-username"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-username"><strong>username</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-username" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS login user.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_cert_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-cert-hostname"><strong>validate_cert_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_cert_hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to validate hostnames in certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_certs"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-certs"><strong>validate_certs</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_certs" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> to skip validation of TLS certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p><strong>Note:</strong> instead of simply deactivating certificate validations to “make things work”, please consider creating your own CA certificate and using it to sign certificates used for your router. You can tell the module about your CA certificate with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code> option.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-values"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-parameter-values"><strong>values</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-values" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>On all entries matching the conditions in <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-find"><span class="std std-ref"><span class="pre">find</span></span></a></strong></code>, set the keys of this option to the values specified here.</p>
|
|
||||||
<p>Use YAML <code class="ansible-value docutils literal notranslate"><span class="pre">~</span></code>, or prepend keys with <code class="ansible-value docutils literal notranslate"><span class="pre">!</span></code>, to specify to unset a value.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-action_group"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-attribute-action-group"><strong>action_group</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-action_group" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Action group:</strong> <strong class="ansible-attribute-support-full">community.routeros.api</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use <code class="docutils literal notranslate"><span class="pre">group/community.routeros.api</span></code> in <code class="docutils literal notranslate"><span class="pre">module_defaults</span></code> to set defaults for this module.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="notes">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Notes</a><a class="headerlink" href="#notes" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>If you want to change values based on their old values (like change all comments ‘foo’ to ‘bar’) and make sure that there are at least N such values, you can use <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-require-matches-min"><span class="std std-ref"><span class="pre">require_matches_min=N</span></span></a></code> together with <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-allow-no-matches"><span class="std std-ref"><span class="pre">allow_no_matches=true</span></span></a></code>. This will make the module fail if there are less than N such entries, but not if there is no match. The latter case is needed for idempotency of the task: once the values have been changed, there should be no further match.</p></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api</span></a></dt><dd><p>Ansible module for RouterOS API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">community.routeros.api_facts</span></a></dt><dd><p>Collect facts from remote devices running MikroTik RouterOS using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a></dt><dd><p>Modify data at paths with API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a></dt><dd><p>Retrieve information from API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/api-guide.html#ansible-collections-community-routeros-docsite-api-guide"><span class="std std-ref">How to connect to RouterOS devices with the RouterOS API</span></a></dt><dd><p>How to connect to RouterOS devices with the RouterOS API</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Rename bridge from 'bridge' to 'my-bridge'</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_find_and_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">interface bridge</span>
|
|
||||||
<span class="w"> </span><span class="nt">find</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">bridge</span>
|
|
||||||
<span class="w"> </span><span class="nt">values</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">my-bridge</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Change IP address to 192.168.1.1 for interface bridge - assuming there is only one</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_find_and_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip address</span>
|
|
||||||
<span class="w"> </span><span class="nt">find</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">interface</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">bridge</span>
|
|
||||||
<span class="w"> </span><span class="nt">values</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">address</span><span class="p">:</span><span class="w"> </span><span class="s">"192.168.1.1/24"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># If there are zero entries, or more than one: fail! We expected that</span>
|
|
||||||
<span class="w"> </span><span class="c1"># exactly one is configured.</span>
|
|
||||||
<span class="w"> </span><span class="nt">require_matches_min</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">1</span>
|
|
||||||
<span class="w"> </span><span class="nt">require_matches_max</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">1</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-values">
|
|
||||||
<h2><a class="toc-backref" href="#id8" role="doc-backlink">Return Values</a><a class="headerlink" href="#return-values" title="Link to this heading"></a></h2>
|
|
||||||
<p>Common return values are documented <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/common_return_values.html#common-return-values" title="(in Ansible vdevel)"><span class="xref std std-ref">here</span></a>, the following are the fields unique to this module:</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-match_count"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-return-match-count"><strong>match_count</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-match_count" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The number of entries that matched the criteria in <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-find-and-modify-module-parameter-find"><span class="std std-ref"><span class="pre">find</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">1</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-modify__count"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-return-modify-count"><strong>modify__count</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-modify__count" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The number of entries that were modified.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">1</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-new_data"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-return-new-data"><strong>new_data</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-new_data" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of all elements for the current path after a change was made.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{".id":</span> <span class="pre">"*1",</span> <span class="pre">"actual-interface":</span> <span class="pre">"bridge",</span> <span class="pre">"address":</span> <span class="pre">"192.168.1.1/24",</span> <span class="pre">"comment":</span> <span class="pre">"awesome",</span> <span class="pre">"disabled":</span> <span class="pre">false,</span> <span class="pre">"dynamic":</span> <span class="pre">false,</span> <span class="pre">"interface":</span> <span class="pre">"bridge",</span> <span class="pre">"invalid":</span> <span class="pre">false,</span> <span class="pre">"network":</span> <span class="pre">"192.168.1.0"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-old_data"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-find-and-modify-module-return-old-data"><strong>old_data</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-old_data" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of all elements for the current path before a change was made.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{".id":</span> <span class="pre">"*1",</span> <span class="pre">"actual-interface":</span> <span class="pre">"bridge",</span> <span class="pre">"address":</span> <span class="pre">"192.168.88.1/24",</span> <span class="pre">"comment":</span> <span class="pre">"defconf",</span> <span class="pre">"disabled":</span> <span class="pre">false,</span> <span class="pre">"dynamic":</span> <span class="pre">false,</span> <span class="pre">"interface":</span> <span class="pre">"bridge",</span> <span class="pre">"invalid":</span> <span class="pre">false,</span> <span class="pre">"network":</span> <span class="pre">"192.168.88.0"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api_facts_module.html" class="btn btn-neutral float-left" title="community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="api_info_module.html" class="btn btn-neutral float-right" title="community.routeros.api_info module – Retrieve information from API" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,848 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.api_info module – Retrieve information from API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.api_modify module – Modify data at paths with API" href="api_modify_module.html" />
|
|
||||||
<link rel="prev" title="community.routeros.api_find_and_modify module – Find and modify information using the API" href="api_find_and_modify_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.api_info module – Retrieve information from API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#requirements">Requirements</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-values">Return Values</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.api_info module – Retrieve information from API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/api_info.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-api-info-module"></span><section id="community-routeros-api-info-module-retrieve-information-from-api">
|
|
||||||
<h1>community.routeros.api_info module – Retrieve information from API<a class="headerlink" href="#community-routeros-api-info-module-retrieve-information-from-api" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.
|
|
||||||
You need further requirements to be able to use this module,
|
|
||||||
see <a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-requirements"><span class="std std-ref">Requirements</span></a> for details.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.api_info</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.2.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#requirements" id="id2">Requirements</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id3">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id4">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id5">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id6">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-values" id="id7">Return Values</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Allows to retrieve information for a path using the API.</p></li>
|
|
||||||
<li><p>This can be used to backup a path to restore it with the <a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a> module.</p></li>
|
|
||||||
<li><p>Entries are normalized, dynamic and builtin entries are not returned. Use the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-handle-disabled"><span class="std std-ref"><span class="pre">handle_disabled</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-hide-defaults"><span class="std std-ref"><span class="pre">hide_defaults</span></span></a></strong></code> options to control normalization, the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-include-dynamic"><span class="std std-ref"><span class="pre">include_dynamic</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-include-builtin"><span class="std std-ref"><span class="pre">include_builtin</span></span></a></strong></code> options to also return dynamic resp. builtin entries, and use <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-unfiltered"><span class="std std-ref"><span class="pre">unfiltered</span></span></a></strong></code> to return all fields including counters.</p></li>
|
|
||||||
<li><p><strong>Note</strong> that this module is still heavily in development, and only supports <strong>some</strong> paths. If you want to support new paths, or think you found problems with existing paths, please first <a class="reference external" href="https://github.com/ansible-collections/community.routeros/issues/">create an issue in the community.routeros Issue Tracker</a>.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="requirements">
|
|
||||||
<span id="ansible-collections-community-routeros-api-info-module-requirements"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Requirements</a><a class="headerlink" href="#requirements" title="Link to this heading"></a></h2>
|
|
||||||
<p>The below requirements are needed on the host that executes this module.</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>librouteros</p></li>
|
|
||||||
<li><p>Python >= 3.6 (for librouteros)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ca_path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-ca-path"><strong>ca_path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ca_path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">path</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>PEM formatted file that contains a CA certificate to be used for certificate validation.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-encoding"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-encoding"><strong>encoding</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-encoding" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use the specified encoding when communicating with the RouterOS device.</p>
|
|
||||||
<p>Default is <code class="ansible-value docutils literal notranslate"><span class="pre">ASCII</span></code>. Note that <code class="ansible-value docutils literal notranslate"><span class="pre">UTF-8</span></code> requires librouteros 3.2.1 or newer.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">"ASCII"</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-force_no_cert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-force-no-cert"><strong>force_no_cert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-force_no_cert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to connect without a certificate when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>.</p>
|
|
||||||
<p><strong>Note:</strong> this forces the use of anonymous Diffie-Hellman (ADH) ciphers. The protocol is susceptible to Man-in-the-Middle attacks, because the keys used in the exchange are not authenticated. Instead of simply connecting without a certificate to “make things work” have a look at <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-handle_disabled"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-handle-disabled"><strong>handle_disabled</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-handle_disabled" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>How to handle unset values.</p>
|
|
||||||
<p><code class="ansible-value docutils literal notranslate"><span class="pre">exclamation</span></code> prepends the keys with <code class="ansible-value docutils literal notranslate"><span class="pre">!</span></code> in the output with value <code class="ansible-value docutils literal notranslate"><span class="pre">null</span></code>.</p>
|
|
||||||
<p><code class="ansible-value docutils literal notranslate"><span class="pre">null-value</span></code> uses the regular key with value <code class="ansible-value docutils literal notranslate"><span class="pre">null</span></code>.</p>
|
|
||||||
<p><code class="ansible-value docutils literal notranslate"><span class="pre">omit</span></code> omits these values from the result.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"exclamation"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"null-value"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"omit"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hide_defaults"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-hide-defaults"><strong>hide_defaults</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hide_defaults" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to hide default values.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-hostname"><strong>hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS hostname API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-include_builtin"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-include-builtin"><strong>include_builtin</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-include_builtin" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to include builtin values.</p>
|
|
||||||
<p>By default, they are not returned, and the <code class="docutils literal notranslate"><span class="pre">builtin</span></code> keys are omitted.</p>
|
|
||||||
<p>If set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>, they are returned as well, and the <code class="docutils literal notranslate"><span class="pre">builtin</span></code> keys are returned as well.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-include_dynamic"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-include-dynamic"><strong>include_dynamic</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-include_dynamic" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to include dynamic values.</p>
|
|
||||||
<p>By default, they are not returned, and the <code class="docutils literal notranslate"><span class="pre">dynamic</span></code> keys are omitted.</p>
|
|
||||||
<p>If set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>, they are returned as well, and the <code class="docutils literal notranslate"><span class="pre">dynamic</span></code> keys are returned as well.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-include_read_only"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-include-read-only"><strong>include_read_only</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-include_read_only" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.10.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to include read-only fields.</p>
|
|
||||||
<p>By default, they are not returned.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-password"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-password"><strong>password</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-password" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS user password.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-path"><strong>path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Path to query.</p>
|
|
||||||
<p>An example value is <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code>. This is equivalent to running <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">print</span></code> in the RouterOS CLI.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">manager"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">manager</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"certificate</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bonding"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">mlag"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port-controller"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port-extender"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">vlan"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">detect-internet"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">eoip"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">poe"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">switch"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">switch</span> <span class="pre">port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">gre"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">gre6"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">l2tp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">l2tp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">list</span> <span class="pre">member"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ovpn-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ovpn-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ppp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pppoe-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pppoe-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pptp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">sstp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">vlan"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">vrrp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">capsman"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">interworking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">steering"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">capsman"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">interworking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">steering"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireguard"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireguard</span> <span class="pre">peers"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">align"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">security-profiles"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">sniffer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">snooper"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"iot</span> <span class="pre">modbus"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">accounting"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">accounting</span> <span class="pre">web-access"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">address"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">arp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">cloud"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">cloud</span> <span class="pre">advanced"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-client</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-relay"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">config"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">lease"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">matcher"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">network"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">option</span> <span class="pre">sets"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns</span> <span class="pre">adlist"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns</span> <span class="pre">static"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">address-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">connection</span> <span class="pre">tracking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">layer7-protocol"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">mangle"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">nat"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">raw"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">service-port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">hotspot</span> <span class="pre">service-port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">identity"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">peer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">policy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">profile"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">proposal"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">neighbor</span> <span class="pre">discovery-settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">pool"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">proxy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route</span> <span class="pre">vrf"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">service"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">smb"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">socks"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ssh"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">tftp</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow</span> <span class="pre">ipfix"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow</span> <span class="pre">target"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">upnp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">upnp</span> <span class="pre">interfaces"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">vrf"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">address"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-server</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">address-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">mangle"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">nat"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">raw"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd</span> <span class="pre">prefix"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd</span> <span class="pre">prefix</span> <span class="pre">default"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">route"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">accept-filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">advertise-filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"port</span> <span class="pre">firmware"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"port</span> <span class="pre">remote-access"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">profile"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">secret"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">simple"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">tree"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">type"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"radius"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"radius</span> <span class="pre">incoming"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">aggregate"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">connection"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">network"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">peer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">num-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">select-rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">id"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">igmp-proxy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">igmp-proxy</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">mme"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">area"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">area</span> <span class="pre">range"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">interface-template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">static-neighbor"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">pimsm</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">pimsm</span> <span class="pre">interface-template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">rip"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ripng"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">table"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"snmp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"snmp</span> <span class="pre">community"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">clock"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">clock</span> <span class="pre">manual"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">health</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">identity"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">leds</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">logging"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">logging</span> <span class="pre">action"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">note"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">client</span> <span class="pre">servers"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">package</span> <span class="pre">update"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">resource</span> <span class="pre">irq</span> <span class="pre">rps"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">routerboard</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">scheduler"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">script"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">upgrade</span> <span class="pre">mirror"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ups"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">watchdog"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">bandwidth-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">e-mail"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing</span> <span class="pre">resource"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server</span> <span class="pre">mac-winbox"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server</span> <span class="pre">ping"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">netwatch"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">romon"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">sms"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">sniffer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">traffic-generator"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">group"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-port"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-port"><strong>port</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-port" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS api port. If <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-tls"><span class="std std-ref"><span class="pre">tls</span></span></a></strong></code> is set, port will apply to TLS/SSL connection.</p>
|
|
||||||
<p>Defaults are <code class="ansible-value docutils literal notranslate"><span class="pre">8728</span></code> for the HTTP API, and <code class="ansible-value docutils literal notranslate"><span class="pre">8729</span></code> for the HTTPS API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict"><strong>restrict</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.18.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Restrict output to entries matching the following criteria.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/field"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict-field"><strong>field</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/field" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The field whose values to restrict.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/invert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict-invert"><strong>invert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/invert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>Invert the condition. This affects <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-restrict-match-disabled"><span class="std std-ref"><span class="pre">restrict[].match_disabled</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-restrict-values"><span class="std std-ref"><span class="pre">restrict[].values</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-restrict-regex"><span class="std std-ref"><span class="pre">restrict[].regex</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/match_disabled"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict-match-disabled"><strong>match_disabled</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/match_disabled" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>Whether disabled or not provided values should match.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/regex"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict-regex"><strong>regex</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/regex" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>A regular expression matching values of the field to limit to.</p>
|
|
||||||
<p>Note that all values will be converted to strings before matching.</p>
|
|
||||||
<p>It is not possible to match disabled values with regular expressions. Set <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-restrict-match-disabled"><span class="std std-ref"><span class="pre">restrict[].match_disabled=true</span></span></a></code> if you also want to match disabled values.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/values"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-restrict-values"><strong>values</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/values" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=any</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The values of the field to limit to.</p>
|
|
||||||
<p>Note that the types of the values are important. If you provide a string <code class="ansible-value docutils literal notranslate"><span class="pre">"0"</span></code>, and librouteros converts the value returned by the API to the integer <code class="ansible-value docutils literal notranslate"><span class="pre">0</span></code>, then this will not match. If you are not sure, better include both variants: both the string and the integer.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-timeout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-timeout"><strong>timeout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-timeout" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.3.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Timeout for the request.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-tls"></div>
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ssl"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-tls"><span id="ansible-collections-community-routeros-api-info-module-parameter-ssl"></span><strong>tls</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-tls" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-aliases">aliases: ssl</span></p>
|
|
||||||
<p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>If is set TLS will be used for RouterOS API connection.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-unfiltered"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-unfiltered"><strong>unfiltered</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-unfiltered" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to output all fields, and not just the ones supported as input for <a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a>.</p>
|
|
||||||
<p>Unfiltered output can contain counters and other state information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-username"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-username"><strong>username</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-username" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS login user.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_cert_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-validate-cert-hostname"><strong>validate_cert_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_cert_hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to validate hostnames in certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_certs"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-parameter-validate-certs"><strong>validate_certs</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_certs" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> to skip validation of TLS certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p><strong>Note:</strong> instead of simply deactivating certificate validations to “make things work”, please consider creating your own CA certificate and using it to sign certificates used for your router. You can tell the module about your CA certificate with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-info-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code> option.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-action_group"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-attribute-action-group"><strong>action_group</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-action_group" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Action group:</strong> <strong class="ansible-attribute-support-full">community.routeros.api</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use <code class="docutils literal notranslate"><span class="pre">group/community.routeros.api</span></code> in <code class="docutils literal notranslate"><span class="pre">module_defaults</span></code> to set defaults for this module.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong> <span class="ansible-attribute-support-na">N/A</span></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api</span></a></dt><dd><p>Ansible module for RouterOS API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">community.routeros.api_facts</span></a></dt><dd><p>Collect facts from remote devices running MikroTik RouterOS using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a></dt><dd><p>Find and modify information using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a></dt><dd><p>Modify data at paths with API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/api-guide.html#ansible-collections-community-routeros-docsite-api-guide"><span class="std std-ref">How to connect to RouterOS devices with the RouterOS API</span></a></dt><dd><p>How to connect to RouterOS devices with the RouterOS API</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Get IP addresses</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_info</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip address</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip_addresses</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Print data for IP addresses</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">var</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip_addresses.result</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Get IP addresses</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_info</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip address</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip_addresses</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Print data for IP addresses</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">var</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip_addresses.result</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-values">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Return Values</a><a class="headerlink" href="#return-values" title="Link to this heading"></a></h2>
|
|
||||||
<p>Common return values are documented <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/common_return_values.html#common-return-values" title="(in Ansible vdevel)"><span class="xref std std-ref">here</span></a>, the following are the fields unique to this module:</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-result"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-info-module-return-result"><strong>result</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-result" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of all elements for the current path.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{".id":</span> <span class="pre">"*1",</span> <span class="pre">"actual-interface":</span> <span class="pre">"bridge",</span> <span class="pre">"address":</span> <span class="pre">"192.168.88.1/24",</span> <span class="pre">"comment":</span> <span class="pre">"defconf",</span> <span class="pre">"disabled":</span> <span class="pre">false,</span> <span class="pre">"dynamic":</span> <span class="pre">false,</span> <span class="pre">"interface":</span> <span class="pre">"bridge",</span> <span class="pre">"invalid":</span> <span class="pre">false,</span> <span class="pre">"network":</span> <span class="pre">"192.168.88.0"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api_find_and_modify_module.html" class="btn btn-neutral float-left" title="community.routeros.api_find_and_modify module – Find and modify information using the API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="api_modify_module.html" class="btn btn-neutral float-right" title="community.routeros.api_modify module – Modify data at paths with API" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,903 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.api_modify module – Modify data at paths with API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.command module – Run commands on remote devices running MikroTik RouterOS" href="command_module.html" />
|
|
||||||
<link rel="prev" title="community.routeros.api_info module – Retrieve information from API" href="api_info_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.api_modify module – Modify data at paths with API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#requirements">Requirements</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#notes">Notes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-values">Return Values</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.api_modify module – Modify data at paths with API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/api_modify.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-api-modify-module"></span><section id="community-routeros-api-modify-module-modify-data-at-paths-with-api">
|
|
||||||
<h1>community.routeros.api_modify module – Modify data at paths with API<a class="headerlink" href="#community-routeros-api-modify-module-modify-data-at-paths-with-api" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.
|
|
||||||
You need further requirements to be able to use this module,
|
|
||||||
see <a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-requirements"><span class="std std-ref">Requirements</span></a> for details.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.api_modify</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.2.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#requirements" id="id2">Requirements</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id3">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id4">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#notes" id="id5">Notes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id6">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id7">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-values" id="id8">Return Values</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Allows to modify information for a path using the API.</p></li>
|
|
||||||
<li><p>Use the <a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a> module to modify one or multiple entries in a controlled way depending on some search conditions.</p></li>
|
|
||||||
<li><p>To make a backup of a path that can be restored with this module, use the <a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a> module.</p></li>
|
|
||||||
<li><p>The module ignores dynamic and builtin entries.</p></li>
|
|
||||||
<li><p><strong>Note</strong> that this module is still heavily in development, and only supports <strong>some</strong> paths. If you want to support new paths, or think you found problems with existing paths, please first <a class="reference external" href="https://github.com/ansible-collections/community.routeros/issues/">create an issue in the community.routeros Issue Tracker</a>.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="requirements">
|
|
||||||
<span id="ansible-collections-community-routeros-api-modify-module-requirements"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Requirements</a><a class="headerlink" href="#requirements" title="Link to this heading"></a></h2>
|
|
||||||
<p>The below requirements are needed on the host that executes this module.</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Needs <a class="reference external" href="https://pypi.org/project/ordereddict">ordereddict</a> for Python 2.6</p></li>
|
|
||||||
<li><p>Python >= 3.6 (for librouteros)</p></li>
|
|
||||||
<li><p>librouteros</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ca_path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-ca-path"><strong>ca_path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ca_path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">path</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>PEM formatted file that contains a CA certificate to be used for certificate validation.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-data"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-data"><strong>data</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-data" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Data to ensure that is present for this path.</p>
|
|
||||||
<p>Fields not provided will not be modified.</p>
|
|
||||||
<p>If <code class="docutils literal notranslate"><span class="pre">.id</span></code> appears in an entry, it will be ignored.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-encoding"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-encoding"><strong>encoding</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-encoding" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use the specified encoding when communicating with the RouterOS device.</p>
|
|
||||||
<p>Default is <code class="ansible-value docutils literal notranslate"><span class="pre">ASCII</span></code>. Note that <code class="ansible-value docutils literal notranslate"><span class="pre">UTF-8</span></code> requires librouteros 3.2.1 or newer.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">"ASCII"</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ensure_order"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-ensure-order"><strong>ensure_order</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ensure_order" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Whether to ensure the same order of the config as present in <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-data"><span class="std std-ref"><span class="pre">data</span></span></a></strong></code>.</p>
|
|
||||||
<p>Requires <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-handle-absent-entries"><span class="std std-ref"><span class="pre">handle_absent_entries=remove</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-force_no_cert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-force-no-cert"><strong>force_no_cert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-force_no_cert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to connect without a certificate when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>.</p>
|
|
||||||
<p><strong>Note:</strong> this forces the use of anonymous Diffie-Hellman (ADH) ciphers. The protocol is susceptible to Man-in-the-Middle attacks, because the keys used in the exchange are not authenticated. Instead of simply connecting without a certificate to “make things work” have a look at <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-handle_absent_entries"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-handle-absent-entries"><strong>handle_absent_entries</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-handle_absent_entries" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>How to handle entries that are present in the current config, but not in <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-data"><span class="std std-ref"><span class="pre">data</span></span></a></strong></code>.</p>
|
|
||||||
<p><code class="ansible-value docutils literal notranslate"><span class="pre">ignore</span></code> ignores them.</p>
|
|
||||||
<p><code class="ansible-value docutils literal notranslate"><span class="pre">remove</span></code> removes them.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"ignore"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"remove"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-handle_entries_content"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-handle-entries-content"><strong>handle_entries_content</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-handle_entries_content" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>For a single entry in <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-data"><span class="std std-ref"><span class="pre">data</span></span></a></strong></code>, this describes how to handle fields that are not mentioned in that entry, but appear in the actual config.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">ignore</span></code>, they are not modified.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">remove</span></code>, they are removed. If at least one cannot be removed, the module will fail.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">remove_as_much_as_possible</span></code>, all that can be removed will be removed. The ones that cannot be removed will be kept.</p>
|
|
||||||
<p>Note that <code class="ansible-value docutils literal notranslate"><span class="pre">remove</span></code> and <code class="ansible-value docutils literal notranslate"><span class="pre">remove_as_much_as_possible</span></code> do not apply to write-only fields.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"ignore"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"remove"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"remove_as_much_as_possible"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-handle_read_only"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-handle-read-only"><strong>handle_read_only</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-handle_read_only" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.10.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>How to handle values passed in for read-only fields.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">ignore</span></code>, they are not passed to the API.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">validate</span></code>, the values are not passed for creation, and for updating they are compared to the value returned for the object. If they differ, the module fails.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">error</span></code>, the module will fail if read-only fields are provided.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ignore"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"validate"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"error"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-handle_write_only"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-handle-write-only"><strong>handle_write_only</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-handle_write_only" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.10.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>How to handle values passed in for write-only fields.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">create_only</span></code>, they are passed on creation, and ignored for updating.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">always_update</span></code>, they are always passed to the API. This means that if such a value is present, the module will always result in <code class="docutils literal notranslate"><span class="pre">changed</span></code> since there is no way to validate whether the value actually changed.</p>
|
|
||||||
<p>If <code class="ansible-value docutils literal notranslate"><span class="pre">error</span></code>, the module will fail if write-only fields are provided.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"create_only"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"always_update"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"error"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-hostname"><strong>hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS hostname API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-password"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-password"><strong>password</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-password" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS user password.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-path"><strong>path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Path to query.</p>
|
|
||||||
<p>An example value is <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code>. This is equivalent to running modification commands in <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span></code> in the RouterOS CLI.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">manager"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">manager</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"caps-man</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"certificate</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bonding"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">mlag"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port-controller"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">port-extender"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">bridge</span> <span class="pre">vlan"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">detect-internet"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">eoip"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">poe"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">switch"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ethernet</span> <span class="pre">switch</span> <span class="pre">port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">gre"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">gre6"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">l2tp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">l2tp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">list</span> <span class="pre">member"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ovpn-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ovpn-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">ppp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pppoe-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pppoe-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">pptp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">sstp-server</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">vlan"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">vrrp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">capsman"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">interworking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifi</span> <span class="pre">steering"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">access-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">capsman"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">channel"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">configuration"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">datapath"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">interworking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">provisioning"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">security"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wifiwave2</span> <span class="pre">steering"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireguard"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireguard</span> <span class="pre">peers"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">align"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">cap"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">security-profiles"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">sniffer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"interface</span> <span class="pre">wireless</span> <span class="pre">snooper"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"iot</span> <span class="pre">modbus"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">accounting"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">accounting</span> <span class="pre">web-access"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">address"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">arp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">cloud"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">cloud</span> <span class="pre">advanced"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-client</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-relay"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">config"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">lease"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">matcher"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">network"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dhcp-server</span> <span class="pre">option</span> <span class="pre">sets"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns</span> <span class="pre">adlist"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">dns</span> <span class="pre">static"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">address-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">connection</span> <span class="pre">tracking"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">layer7-protocol"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">mangle"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">nat"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">raw"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">firewall</span> <span class="pre">service-port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">hotspot</span> <span class="pre">service-port"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">identity"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">peer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">policy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">profile"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">proposal"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ipsec</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">neighbor</span> <span class="pre">discovery-settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">pool"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">proxy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">route</span> <span class="pre">vrf"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">service"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">smb"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">socks"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">ssh"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">tftp</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow</span> <span class="pre">ipfix"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">traffic-flow</span> <span class="pre">target"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">upnp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">upnp</span> <span class="pre">interfaces"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ip</span> <span class="pre">vrf"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">address"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">dhcp-server</span> <span class="pre">option"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">address-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">mangle"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">nat"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">firewall</span> <span class="pre">raw"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd</span> <span class="pre">prefix"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">nd</span> <span class="pre">prefix</span> <span class="pre">default"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">route"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ipv6</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">accept-filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">advertise-filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"mpls</span> <span class="pre">ldp</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"port</span> <span class="pre">firmware"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"port</span> <span class="pre">remote-access"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">profile"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"ppp</span> <span class="pre">secret"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">simple"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">tree"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"queue</span> <span class="pre">type"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"radius"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"radius</span> <span class="pre">incoming"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">aggregate"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">connection"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">network"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">peer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">bgp</span> <span class="pre">template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">num-list"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">filter</span> <span class="pre">select-rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">id"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">igmp-proxy"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">igmp-proxy</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">mme"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">area"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">area</span> <span class="pre">range"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">interface-template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ospf</span> <span class="pre">static-neighbor"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">pimsm</span> <span class="pre">instance"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">pimsm</span> <span class="pre">interface-template"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">rip"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">ripng"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">rule"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"routing</span> <span class="pre">table"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"snmp"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"snmp</span> <span class="pre">community"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">clock"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">clock</span> <span class="pre">manual"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">health</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">identity"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">leds</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">logging"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">logging</span> <span class="pre">action"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">note"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">client"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">client</span> <span class="pre">servers"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ntp</span> <span class="pre">server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">package</span> <span class="pre">update"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">resource</span> <span class="pre">irq</span> <span class="pre">rps"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">routerboard</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">scheduler"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">script"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">upgrade</span> <span class="pre">mirror"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">ups"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"system</span> <span class="pre">watchdog"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">bandwidth-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">e-mail"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing</span> <span class="pre">interface"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">graphing</span> <span class="pre">resource"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server</span> <span class="pre">mac-winbox"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">mac-server</span> <span class="pre">ping"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">netwatch"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">romon"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">sms"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">sniffer"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"tool</span> <span class="pre">traffic-generator"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">aaa"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">group"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"user</span> <span class="pre">settings"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-port"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-port"><strong>port</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-port" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS api port. If <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls</span></span></a></strong></code> is set, port will apply to TLS/SSL connection.</p>
|
|
||||||
<p>Defaults are <code class="ansible-value docutils literal notranslate"><span class="pre">8728</span></code> for the HTTP API, and <code class="ansible-value docutils literal notranslate"><span class="pre">8729</span></code> for the HTTPS API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict"><strong>restrict</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.18.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Restrict operation to entries matching the following criteria.</p>
|
|
||||||
<p>This can be useful together with <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-handle-absent-entries"><span class="std std-ref"><span class="pre">handle_absent_entries=remove</span></span></a></code> to operate on a subset of the values.</p>
|
|
||||||
<p>For example, for <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-path"><span class="std std-ref"><span class="pre">path=ip</span> <span class="pre">firewall</span> <span class="pre">filter</span></span></a></code>, you can set <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-field"><span class="std std-ref"><span class="pre">restrict[].field=chain</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-values"><span class="std std-ref"><span class="pre">restrict[].values=input</span></span></a></code> to restrict operation to the input chain, and ignore the forward and output chains.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/field"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict-field"><strong>field</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/field" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The field whose values to restrict.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/invert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict-invert"><strong>invert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/invert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>Invert the condition. This affects <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-match-disabled"><span class="std std-ref"><span class="pre">restrict[].match_disabled</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-values"><span class="std std-ref"><span class="pre">restrict[].values</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-regex"><span class="std std-ref"><span class="pre">restrict[].regex</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/match_disabled"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict-match-disabled"><strong>match_disabled</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/match_disabled" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>Whether disabled or not provided values should match.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/regex"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict-regex"><strong>regex</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/regex" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>A regular expression matching values of the field to limit to.</p>
|
|
||||||
<p>Note that all values will be converted to strings before matching.</p>
|
|
||||||
<p>It is not possible to match disabled values with regular expressions. Set <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-restrict-match-disabled"><span class="std std-ref"><span class="pre">restrict[].match_disabled=true</span></span></a></code> if you also want to match disabled values.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-restrict/values"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-restrict-values"><strong>values</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-restrict/values" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=any</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The values of the field to limit to.</p>
|
|
||||||
<p>Note that the types of the values are important. If you provide a string <code class="ansible-value docutils literal notranslate"><span class="pre">"0"</span></code>, and librouteros converts the value returned by the API to the integer <code class="ansible-value docutils literal notranslate"><span class="pre">0</span></code>, then this will not match. If you are not sure, better include both variants: both the string and the integer.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-timeout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-timeout"><strong>timeout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-timeout" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.3.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Timeout for the request.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-tls"></div>
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ssl"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-tls"><span id="ansible-collections-community-routeros-api-modify-module-parameter-ssl"></span><strong>tls</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-tls" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-aliases">aliases: ssl</span></p>
|
|
||||||
<p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>If is set TLS will be used for RouterOS API connection.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-username"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-username"><strong>username</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-username" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS login user.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_cert_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-validate-cert-hostname"><strong>validate_cert_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_cert_hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to validate hostnames in certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_certs"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-parameter-validate-certs"><strong>validate_certs</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_certs" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> to skip validation of TLS certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p><strong>Note:</strong> instead of simply deactivating certificate validations to “make things work”, please consider creating your own CA certificate and using it to sign certificates used for your router. You can tell the module about your CA certificate with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code> option.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-action_group"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-attribute-action-group"><strong>action_group</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-action_group" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Action group:</strong> <strong class="ansible-attribute-support-full">community.routeros.api</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use <code class="docutils literal notranslate"><span class="pre">group/community.routeros.api</span></code> in <code class="docutils literal notranslate"><span class="pre">module_defaults</span></code> to set defaults for this module.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="notes">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Notes</a><a class="headerlink" href="#notes" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>If write-only fields are present in the path, the module is <strong>not idempotent</strong> in a strict sense, since it is not able to verify the current value of these fields. The behavior the module should assume can be controlled with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-modify-module-parameter-handle-write-only"><span class="std std-ref"><span class="pre">handle_write_only</span></span></a></strong></code> option.</p></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api</span></a></dt><dd><p>Ansible module for RouterOS API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">community.routeros.api_facts</span></a></dt><dd><p>Collect facts from remote devices running MikroTik RouterOS using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a></dt><dd><p>Find and modify information using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a></dt><dd><p>Retrieve information from API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/api-guide.html#ansible-collections-community-routeros-docsite-api-guide"><span class="std std-ref">How to connect to RouterOS devices with the RouterOS API</span></a></dt><dd><p>How to connect to RouterOS devices with the RouterOS API</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Setup DHCP server networks</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Ensures that we have exactly two DHCP server networks (in the specified order)</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip dhcp-server network</span>
|
|
||||||
<span class="w"> </span><span class="nt">handle_absent_entries</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">remove</span>
|
|
||||||
<span class="w"> </span><span class="nt">handle_entries_content</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">remove_as_much_as_possible</span>
|
|
||||||
<span class="w"> </span><span class="nt">ensure_order</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">data</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">address</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.88.0/24</span>
|
|
||||||
<span class="w"> </span><span class="nt">comment</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">admin network</span>
|
|
||||||
<span class="w"> </span><span class="nt">dns-server</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.88.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">gateway</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.88.1</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">address</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.1.0/24</span>
|
|
||||||
<span class="w"> </span><span class="nt">comment</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">customer network 1</span>
|
|
||||||
<span class="w"> </span><span class="nt">dns-server</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.1.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">gateway</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.1.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">netmask</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">24</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Adjust NAT</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip firewall nat</span>
|
|
||||||
<span class="w"> </span><span class="nt">data</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">action</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">masquerade</span>
|
|
||||||
<span class="w"> </span><span class="nt">chain</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">srcnat</span>
|
|
||||||
<span class="w"> </span><span class="nt">comment</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">NAT to WAN</span>
|
|
||||||
<span class="w"> </span><span class="nt">out-interface-list</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">WAN</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Three ways to unset values:</span>
|
|
||||||
<span class="w"> </span><span class="c1"># - nothing after `:`</span>
|
|
||||||
<span class="w"> </span><span class="c1"># - "empty" value (null/~/None)</span>
|
|
||||||
<span class="w"> </span><span class="c1"># - prepend '!'</span>
|
|
||||||
<span class="w"> </span><span class="nt">out-interface</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">to-addresses</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">~</span>
|
|
||||||
<span class="w"> </span><span class="s">'!to-ports'</span><span class="p p-Indicator">:</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Block all incoming connections</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip firewall filter</span>
|
|
||||||
<span class="w"> </span><span class="nt">handle_absent_entries</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">remove</span>
|
|
||||||
<span class="w"> </span><span class="nt">handle_entries_content</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">remove_as_much_as_possible</span>
|
|
||||||
<span class="w"> </span><span class="nt">restrict</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Do not touch any chain except the input chain</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">field</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">chain</span>
|
|
||||||
<span class="w"> </span><span class="nt">values</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">input</span>
|
|
||||||
<span class="w"> </span><span class="nt">data</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">action</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">drop</span>
|
|
||||||
<span class="w"> </span><span class="nt">chain</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">input</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-values">
|
|
||||||
<h2><a class="toc-backref" href="#id8" role="doc-backlink">Return Values</a><a class="headerlink" href="#return-values" title="Link to this heading"></a></h2>
|
|
||||||
<p>Common return values are documented <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/common_return_values.html#common-return-values" title="(in Ansible vdevel)"><span class="xref std std-ref">here</span></a>, the following are the fields unique to this module:</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-new_data"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-return-new-data"><strong>new_data</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-new_data" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of all elements for the current path after a change was made.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{".id":</span> <span class="pre">"*1",</span> <span class="pre">"actual-interface":</span> <span class="pre">"bridge",</span> <span class="pre">"address":</span> <span class="pre">"192.168.1.1/24",</span> <span class="pre">"comment":</span> <span class="pre">"awesome",</span> <span class="pre">"disabled":</span> <span class="pre">false,</span> <span class="pre">"dynamic":</span> <span class="pre">false,</span> <span class="pre">"interface":</span> <span class="pre">"bridge",</span> <span class="pre">"invalid":</span> <span class="pre">false,</span> <span class="pre">"network":</span> <span class="pre">"192.168.1.0"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-old_data"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-modify-module-return-old-data"><strong>old_data</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-old_data" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of all elements for the current path before a change was made.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{".id":</span> <span class="pre">"*1",</span> <span class="pre">"actual-interface":</span> <span class="pre">"bridge",</span> <span class="pre">"address":</span> <span class="pre">"192.168.88.1/24",</span> <span class="pre">"comment":</span> <span class="pre">"defconf",</span> <span class="pre">"disabled":</span> <span class="pre">false,</span> <span class="pre">"dynamic":</span> <span class="pre">false,</span> <span class="pre">"interface":</span> <span class="pre">"bridge",</span> <span class="pre">"invalid":</span> <span class="pre">false,</span> <span class="pre">"network":</span> <span class="pre">"192.168.88.0"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api_info_module.html" class="btn btn-neutral float-left" title="community.routeros.api_info module – Retrieve information from API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="command_module.html" class="btn btn-neutral float-right" title="community.routeros.command module – Run commands on remote devices running MikroTik RouterOS" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,727 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.api module – Ansible module for RouterOS API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API" href="api_facts_module.html" />
|
|
||||||
<link rel="prev" title="How to quote and unquote commands and arguments" href="docsite/quoting.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.api module – Ansible module for RouterOS API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#requirements">Requirements</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#notes">Notes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-values">Return Values</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.api module – Ansible module for RouterOS API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/api.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-api-module"></span><section id="community-routeros-api-module-ansible-module-for-routeros-api">
|
|
||||||
<h1>community.routeros.api module – Ansible module for RouterOS API<a class="headerlink" href="#community-routeros-api-module-ansible-module-for-routeros-api" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.
|
|
||||||
You need further requirements to be able to use this module,
|
|
||||||
see <a class="reference internal" href="#ansible-collections-community-routeros-api-module-requirements"><span class="std std-ref">Requirements</span></a> for details.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.api</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#requirements" id="id2">Requirements</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id3">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id4">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#notes" id="id5">Notes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id6">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id7">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-values" id="id8">Return Values</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Ansible module for RouterOS API with the Python <code class="docutils literal notranslate"><span class="pre">librouteros</span></code> library.</p></li>
|
|
||||||
<li><p>This module can add, remove, update, query and execute arbitrary command in RouterOS via API.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="requirements">
|
|
||||||
<span id="ansible-collections-community-routeros-api-module-requirements"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Requirements</a><a class="headerlink" href="#requirements" title="Link to this heading"></a></h2>
|
|
||||||
<p>The below requirements are needed on the host that executes this module.</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>librouteros</p></li>
|
|
||||||
<li><p>Python >= 3.6 (for librouteros)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-add"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-add"><strong>add</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-add" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will add selected arguments in selected path to RouterOS config.</p>
|
|
||||||
<p>Example <code class="ansible-value docutils literal notranslate"><span class="pre">address=1.1.1.1/32</span> <span class="pre">interface=ether1</span></code>.</p>
|
|
||||||
<p>Equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">add</span> <span class="pre">address=1.1.1.1/32</span> <span class="pre">interface=ether1</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ca_path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-ca-path"><strong>ca_path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-ca_path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">path</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>PEM formatted file that contains a CA certificate to be used for certificate validation.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-cmd"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-cmd"><strong>cmd</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-cmd" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Execute any/arbitrary command in selected path, after the command we can add <code class="docutils literal notranslate"><span class="pre">.id</span></code>.</p>
|
|
||||||
<p>Example path <code class="ansible-value docutils literal notranslate"><span class="pre">system</span> <span class="pre">script</span></code> and cmd <code class="ansible-value docutils literal notranslate"><span class="pre">run</span> <span class="pre">.id=*03</span></code> is equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/system</span> <span class="pre">script</span> <span class="pre">run</span> <span class="pre">number=0</span></code>.</p>
|
|
||||||
<p>Example path <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> and cmd <code class="ansible-value docutils literal notranslate"><span class="pre">print</span></code> is equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">print</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-encoding"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-encoding"><strong>encoding</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-encoding" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use the specified encoding when communicating with the RouterOS device.</p>
|
|
||||||
<p>Default is <code class="ansible-value docutils literal notranslate"><span class="pre">ASCII</span></code>. Note that <code class="ansible-value docutils literal notranslate"><span class="pre">UTF-8</span></code> requires librouteros 3.2.1 or newer.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">"ASCII"</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query"><strong>extended_query</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Extended query given path for selected query attributes from RouterOS API.</p>
|
|
||||||
<p>Extended query allow conjunctive input. If there is no matching entry, an empty list will be returned.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/attributes"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-attributes"><strong>attributes</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/attributes" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The list of attributes to return.</p>
|
|
||||||
<p>Every attribute used in a <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where"><span class="std std-ref"><span class="pre">extended_query.where[]</span></span></a></strong></code> clause need to be listed here.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where"><strong>where</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>Allows to restrict the objects returned.</p>
|
|
||||||
<p>The conditions here must all match. An <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><span class="std std-ref"><span class="pre">extended_query.where[].or</span></span></a></strong></code> condition needs at least one of its conditions to match.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/attribute"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-attribute"><strong>attribute</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/attribute" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The attribute to match. Must be part of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-attributes"><span class="std std-ref"><span class="pre">extended_query.attributes</span></span></a></strong></code>.</p>
|
|
||||||
<p>Either <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><span class="std std-ref"><span class="pre">extended_query.where[].or</span></span></a></strong></code> or all of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-attribute"><span class="std std-ref"><span class="pre">extended_query.where[].attribute</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><span class="std std-ref"><span class="pre">extended_query.where[].is</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><span class="std std-ref"><span class="pre">extended_query.where[].value</span></span></a></strong></code> have to be specified.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/is"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><strong>is</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/is" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The operator to use for matching.</p>
|
|
||||||
<p>For equality use <code class="ansible-value docutils literal notranslate"><span class="pre">==</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">eq</span></code>. For less use <code class="ansible-value docutils literal notranslate"><span class="pre"><</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">less</span></code>. For more use <code class="ansible-value docutils literal notranslate"><span class="pre">></span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">more</span></code>.</p>
|
|
||||||
<p>Use <code class="ansible-value docutils literal notranslate"><span class="pre">in</span></code> to check whether the value is part of a list. In that case, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><span class="std std-ref"><span class="pre">extended_query.where[].value</span></span></a></strong></code> must be a list.</p>
|
|
||||||
<p>Either <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><span class="std std-ref"><span class="pre">extended_query.where[].or</span></span></a></strong></code> or all of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-attribute"><span class="std std-ref"><span class="pre">extended_query.where[].attribute</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><span class="std std-ref"><span class="pre">extended_query.where[].is</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><span class="std std-ref"><span class="pre">extended_query.where[].value</span></span></a></strong></code> have to be specified.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"=="</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"!="</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">">"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"<"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"in"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"eq"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"not"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"more"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"less"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/or"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><strong>or</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/or" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>A list of conditions so that at least one of them has to match.</p>
|
|
||||||
<p>Either <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><span class="std std-ref"><span class="pre">extended_query.where[].or</span></span></a></strong></code> or all of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-attribute"><span class="std std-ref"><span class="pre">extended_query.where[].attribute</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><span class="std std-ref"><span class="pre">extended_query.where[].is</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><span class="std std-ref"><span class="pre">extended_query.where[].value</span></span></a></strong></code> have to be specified.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/or/attribute"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-or-attribute"><strong>attribute</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/or/attribute" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The attribute to match. Must be part of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-attributes"><span class="std std-ref"><span class="pre">extended_query.attributes</span></span></a></strong></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/or/is"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-or-is"><strong>is</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/or/is" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The operator to use for matching.</p>
|
|
||||||
<p>For equality use <code class="ansible-value docutils literal notranslate"><span class="pre">==</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">eq</span></code>. For less use <code class="ansible-value docutils literal notranslate"><span class="pre"><</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">less</span></code>. For more use <code class="ansible-value docutils literal notranslate"><span class="pre">></span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">more</span></code>.</p>
|
|
||||||
<p>Use <code class="ansible-value docutils literal notranslate"><span class="pre">in</span></code> to check whether the value is part of a list. In that case, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or-value"><span class="std std-ref"><span class="pre">extended_query.where[].or[].value</span></span></a></strong></code> must be a list.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"=="</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"!="</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">">"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"<"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"in"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"eq"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"not"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"more"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"less"</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/or/value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-or-value"><strong>value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/or/value" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">any</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The value to compare to. Must be a list for <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or-is"><span class="std std-ref"><span class="pre">extended_query.where[].or[].is=in</span></span></a></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-indent"></div><div class="ansible-option-indent"></div><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-extended_query/where/value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><strong>value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-extended_query/where/value" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">any</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-indent-desc"></div><div class="ansible-option-indent-desc"></div><div class="ansible-option-cell"><p>The value to compare to. Must be a list for <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><span class="std std-ref"><span class="pre">extended_query.where[].is=in</span></span></a></code>.</p>
|
|
||||||
<p>Either <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-or"><span class="std std-ref"><span class="pre">extended_query.where[].or</span></span></a></strong></code> or all of <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-attribute"><span class="std std-ref"><span class="pre">extended_query.where[].attribute</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-is"><span class="std std-ref"><span class="pre">extended_query.where[].is</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-extended-query-where-value"><span class="std std-ref"><span class="pre">extended_query.where[].value</span></span></a></strong></code> have to be specified.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-force_no_cert"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-force-no-cert"><strong>force_no_cert</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-force_no_cert" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.4.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to connect without a certificate when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>.</p>
|
|
||||||
<p><strong>Note:</strong> this forces the use of anonymous Diffie-Hellman (ADH) ciphers. The protocol is susceptible to Man-in-the-Middle attacks, because the keys used in the exchange are not authenticated. Instead of simply connecting without a certificate to “make things work” have a look at <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code> and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-hostname"><strong>hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS hostname API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-password"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-password"><strong>password</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-password" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS user password.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-path"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-path"><strong>path</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-path" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Main path for all other arguments.</p>
|
|
||||||
<p>If other arguments are not set, api will return all items in selected path.</p>
|
|
||||||
<p>Example <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code>. Equivalent of RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">print</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-port"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-port"><strong>port</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-port" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS api port. If <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-tls"><span class="std std-ref"><span class="pre">tls</span></span></a></strong></code> is set, port will apply to TLS/SSL connection.</p>
|
|
||||||
<p>Defaults are <code class="ansible-value docutils literal notranslate"><span class="pre">8728</span></code> for the HTTP API, and <code class="ansible-value docutils literal notranslate"><span class="pre">8729</span></code> for the HTTPS API.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-query"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-query"><strong>query</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-query" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Query given path for selected query attributes from RouterOS API.</p>
|
|
||||||
<p>WHERE is key word which extend query. WHERE format is key operator value - with spaces.</p>
|
|
||||||
<p>WHERE valid operators are <code class="ansible-value docutils literal notranslate"><span class="pre">==</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">eq</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">!=</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">not</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">></span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">more</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre"><</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">less</span></code>.</p>
|
|
||||||
<p>Example path <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> and query <code class="ansible-value docutils literal notranslate"><span class="pre">.id</span> <span class="pre">address</span></code> will return only <code class="docutils literal notranslate"><span class="pre">.id</span></code> and <code class="docutils literal notranslate"><span class="pre">address</span></code> for all items in <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> path.</p>
|
|
||||||
<p>Example path <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> and query <code class="ansible-value docutils literal notranslate"><span class="pre">.id</span> <span class="pre">address</span> <span class="pre">WHERE</span> <span class="pre">address</span> <span class="pre">==</span> <span class="pre">1.1.1.3/32</span></code>. will return only <code class="docutils literal notranslate"><span class="pre">.id</span></code> and <code class="docutils literal notranslate"><span class="pre">address</span></code> for items in <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> path, where address is eq to 1.1.1.3/32.</p>
|
|
||||||
<p>Example path <code class="ansible-value docutils literal notranslate"><span class="pre">interface</span></code> and query <code class="ansible-value docutils literal notranslate"><span class="pre">mtu</span> <span class="pre">name</span> <span class="pre">WHERE</span> <span class="pre">mut</span> <span class="pre">></span> <span class="pre">1400</span></code> will return only interfaces <code class="docutils literal notranslate"><span class="pre">mtu,name</span></code> where mtu is bigger than 1400.</p>
|
|
||||||
<p>Equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/interface</span> <span class="pre">print</span> <span class="pre">where</span> <span class="pre">mtu</span> <span class="pre">></span> <span class="pre">1400</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-remove"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-remove"><strong>remove</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-remove" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Remove config/value from RouterOS by ‘.id’.</p>
|
|
||||||
<p>Example <code class="ansible-value docutils literal notranslate"><span class="pre">*03</span></code> will remove config/value with <code class="docutils literal notranslate"><span class="pre">id=*03</span></code> in selected path.</p>
|
|
||||||
<p>Equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">remove</span> <span class="pre">numbers=1</span></code>.</p>
|
|
||||||
<p>Note <code class="docutils literal notranslate"><span class="pre">number</span></code> in RouterOS CLI is different from <code class="docutils literal notranslate"><span class="pre">.id</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-timeout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-timeout"><strong>timeout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-timeout" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.3.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Timeout for the request.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-tls"></div>
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-ssl"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-tls"><span id="ansible-collections-community-routeros-api-module-parameter-ssl"></span><strong>tls</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-tls" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-aliases">aliases: ssl</span></p>
|
|
||||||
<p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>If is set TLS will be used for RouterOS API connection.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-update"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-update"><strong>update</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-update" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Update config/value in RouterOS by ‘.id’ in selected path.</p>
|
|
||||||
<p>Example <code class="ansible-value docutils literal notranslate"><span class="pre">.id=*03</span> <span class="pre">address=1.1.1.3/32</span></code> and path <code class="ansible-value docutils literal notranslate"><span class="pre">ip</span> <span class="pre">address</span></code> will replace existing ip address with <code class="docutils literal notranslate"><span class="pre">.id=*03</span></code>.</p>
|
|
||||||
<p>Equivalent in RouterOS CLI <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">set</span> <span class="pre">address=1.1.1.3/32</span> <span class="pre">numbers=1</span></code>.</p>
|
|
||||||
<p>Note <code class="docutils literal notranslate"><span class="pre">number</span></code> in RouterOS CLI is different from <code class="docutils literal notranslate"><span class="pre">.id</span></code>.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-username"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-username"><strong>username</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-username" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>RouterOS login user.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_cert_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-validate-cert-hostname"><strong>validate_cert_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_cert_hostname" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> to validate hostnames in certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code> and <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-certs"><span class="std std-ref"><span class="pre">validate_certs=true</span></span></a></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-validate_certs"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-parameter-validate-certs"><strong>validate_certs</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-validate_certs" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> to skip validation of TLS certificates.</p>
|
|
||||||
<p>See also <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-validate-cert-hostname"><span class="std std-ref"><span class="pre">validate_cert_hostname</span></span></a></strong></code>. Only used when <code class="ansible-option-value docutils literal notranslate"><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-tls"><span class="std std-ref"><span class="pre">tls=true</span></span></a></code>.</p>
|
|
||||||
<p><strong>Note:</strong> instead of simply deactivating certificate validations to “make things work”, please consider creating your own CA certificate and using it to sign certificates used for your router. You can tell the module about your CA certificate with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-ca-path"><span class="std std-ref"><span class="pre">ca_path</span></span></a></strong></code> option.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-action_group"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-attribute-action-group"><strong>action_group</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-action_group" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Action group:</strong> <strong class="ansible-attribute-support-full">community.routeros.api</strong></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 2.1.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Use <code class="docutils literal notranslate"><span class="pre">group/community.routeros.api</span></code> in <code class="docutils literal notranslate"><span class="pre">module_defaults</span></code> to set defaults for this module.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-none">none</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-none">none</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="notes">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Notes</a><a class="headerlink" href="#notes" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-add"><span class="std std-ref"><span class="pre">add</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-remove"><span class="std std-ref"><span class="pre">remove</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-update"><span class="std std-ref"><span class="pre">update</span></span></a></strong></code>, <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-cmd"><span class="std std-ref"><span class="pre">cmd</span></span></a></strong></code>, and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-api-module-parameter-query"><span class="std std-ref"><span class="pre">query</span></span></a></strong></code> are mutually exclusive.</p></li>
|
|
||||||
<li><p>Use the <a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a> and <a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a> modules for more specific modifications, and the <a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a> module for a more controlled way of returning all entries for a path.</p></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="docsite/quoting.html#ansible-collections-community-routeros-docsite-quoting"><span class="std std-ref">How to quote and unquote commands and arguments</span></a></dt><dd><p>How to quote and unquote commands and arguments</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">community.routeros.api_facts</span></a></dt><dd><p>Collect facts from remote devices running MikroTik RouterOS using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a></dt><dd><p>Find and modify information using the API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info</span></a></dt><dd><p>Retrieve information from API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a></dt><dd><p>Modify data at paths with API.</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/api-guide.html#ansible-collections-community-routeros-docsite-api-guide"><span class="std std-ref">How to connect to RouterOS devices with the RouterOS API</span></a></dt><dd><p>How to connect to RouterOS devices with the RouterOS API</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Get example - ip address print</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ipaddrd_printout</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Dump "Get example" output</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">ipaddrd_printout</span> <span class="cp">}}</span><span class="s">'</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Add example - ip address</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">add</span><span class="p">:</span><span class="w"> </span><span class="s">"address=192.168.255.10/24</span><span class="nv"> </span><span class="s">interface=ether2"</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Query example - ".id, address" in "ip address WHERE address == 192.168.255.10/24"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">query</span><span class="p">:</span><span class="w"> </span><span class="s">".id</span><span class="nv"> </span><span class="s">address</span><span class="nv"> </span><span class="s">WHERE</span><span class="nv"> </span><span class="s">address</span><span class="nv"> </span><span class="s">==</span><span class="nv"> </span><span class="cp">{{</span> <span class="nv">ip2</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">queryout</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Dump "Query example" output</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">queryout</span> <span class="cp">}}</span><span class="s">'</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Extended query example - ".id,address,network" where address is not 192.168.255.10/24 or is 10.20.36.20/24</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">extended_query</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">attributes</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">network</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">address</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">.id</span>
|
|
||||||
<span class="w"> </span><span class="nt">where</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">attribute</span><span class="p">:</span><span class="w"> </span><span class="s">"network"</span>
|
|
||||||
<span class="w"> </span><span class="nt">is</span><span class="p">:</span><span class="w"> </span><span class="s">"=="</span>
|
|
||||||
<span class="w"> </span><span class="nt">value</span><span class="p">:</span><span class="w"> </span><span class="s">"192.168.255.0"</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">or</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">attribute</span><span class="p">:</span><span class="w"> </span><span class="s">"address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">is</span><span class="p">:</span><span class="w"> </span><span class="s">"!="</span>
|
|
||||||
<span class="w"> </span><span class="nt">value</span><span class="p">:</span><span class="w"> </span><span class="s">"192.168.255.10/24"</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">attribute</span><span class="p">:</span><span class="w"> </span><span class="s">"address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">is</span><span class="p">:</span><span class="w"> </span><span class="s">"eq"</span>
|
|
||||||
<span class="w"> </span><span class="nt">value</span><span class="p">:</span><span class="w"> </span><span class="s">"10.20.36.20/24"</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">attribute</span><span class="p">:</span><span class="w"> </span><span class="s">"network"</span>
|
|
||||||
<span class="w"> </span><span class="nt">is</span><span class="p">:</span><span class="w"> </span><span class="s">"in"</span>
|
|
||||||
<span class="w"> </span><span class="nt">value</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="s">"10.20.36.0"</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="s">"192.168.255.0"</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">extended_queryout</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Dump "Extended query example" output</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">extended_queryout</span> <span class="cp">}}</span><span class="s">'</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Update example - ether2 ip address with ".id = *14"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">update</span><span class="p">:</span><span class="w"> </span><span class="p p-Indicator">>-</span>
|
|
||||||
<span class="w"> </span><span class="no">.id=*14</span>
|
|
||||||
<span class="w"> </span><span class="no">address=192.168.255.20/24</span>
|
|
||||||
<span class="w"> </span><span class="no">comment=</span><span class="cp">{{</span> <span class="s1">'Update 192.168.255.10/24 to 192.168.255.20/24 on ether2'</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.quote_argument_value</span> <span class="cp">}}</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Remove example - ether2 ip 192.168.255.20/24 with ".id = *14"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="nt">remove</span><span class="p">:</span><span class="w"> </span><span class="s">"*14"</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Arbitrary command example "/system identity print"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"system</span><span class="nv"> </span><span class="s">identity"</span>
|
|
||||||
<span class="w"> </span><span class="nt">cmd</span><span class="p">:</span><span class="w"> </span><span class="s">"print"</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">arbitraryout</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Dump "Arbitrary command example" output</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">arbitraryout</span> <span class="cp">}}</span><span class="s">'</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-values">
|
|
||||||
<h2><a class="toc-backref" href="#id8" role="doc-backlink">Return Values</a><a class="headerlink" href="#return-values" title="Link to this heading"></a></h2>
|
|
||||||
<p>Common return values are documented <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/common_return_values.html#common-return-values" title="(in Ansible vdevel)"><span class="xref std std-ref">here</span></a>, the following are the fields unique to this module:</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-message"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-api-module-return-message"><strong>message</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-message" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>All outputs are in list with dictionary elements returned from RouterOS api.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[{"address":</span> <span class="pre">"1.2.3.4"},</span> <span class="pre">{"address":</span> <span class="pre">"2.3.4.5"}]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Nikolay Dachev (@NikolayDachev)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="docsite/quoting.html" class="btn btn-neutral float-left" title="How to quote and unquote commands and arguments" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="api_facts_module.html" class="btn btn-neutral float-right" title="community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,404 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.command module – Run commands on remote devices running MikroTik RouterOS — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS" href="facts_module.html" />
|
|
||||||
<link rel="prev" title="community.routeros.api_modify module – Modify data at paths with API" href="api_modify_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#notes">Notes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-values">Return Values</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/command.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-command-module"></span><section id="community-routeros-command-module-run-commands-on-remote-devices-running-mikrotik-routeros">
|
|
||||||
<h1>community.routeros.command module – Run commands on remote devices running MikroTik RouterOS<a class="headerlink" href="#community-routeros-command-module-run-commands-on-remote-devices-running-mikrotik-routeros" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.command</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id2">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id3">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#notes" id="id4">Notes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id5">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id6">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-values" id="id7">Return Values</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Sends arbitrary commands to an RouterOS node and returns the results read from the device. This module includes an argument that will cause the module to wait for a specific condition before returning or timing out if the condition is not met.</p></li>
|
|
||||||
<li><p>The module always indicates a (changed) status. You can use <a class="reference external" href="https://docs.ansible.com/ansible/devel/playbook_guide/playbooks_error_handling.html#override-the-changed-result" title="(in Ansible vdevel)"><span class="xref std std-ref">the changed_when task property</span></a> to determine whether a command task actually resulted in a change or not.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-commands"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-parameter-commands"><strong>commands</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-commands" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>List of commands to send to the remote RouterOS device over the configured provider. The resulting output from the command is returned. If the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-command-module-parameter-wait-for"><span class="std std-ref"><span class="pre">wait_for</span></span></a></strong></code> argument is provided, the module is not returned until the condition is satisfied or the number of retries has expired.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-interval"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-parameter-interval"><strong>interval</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-interval" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Configures the interval in seconds to wait between retries of the command. If the command does not pass the specified conditions, the interval indicates how long to wait before trying the command again.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">1</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-match"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-parameter-match"><strong>match</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-match" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-command-module-parameter-match"><span class="std std-ref"><span class="pre">match</span></span></a></strong></code> argument is used in conjunction with the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-command-module-parameter-wait-for"><span class="std std-ref"><span class="pre">wait_for</span></span></a></strong></code> argument to specify the match policy. Valid values are <code class="ansible-value docutils literal notranslate"><span class="pre">all</span></code> or <code class="ansible-value docutils literal notranslate"><span class="pre">any</span></code>. If the value is set to <code class="ansible-value docutils literal notranslate"><span class="pre">all</span></code> then all conditionals in the wait_for must be satisfied. If the value is set to <code class="ansible-value docutils literal notranslate"><span class="pre">any</span></code> then only one of the values must be satisfied.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">"any"</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">"all"</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-retries"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-parameter-retries"><strong>retries</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-retries" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Specifies the number of retries a command should by tried before it is considered failed. The command is run on the target device every retry and evaluated against the <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-command-module-parameter-wait-for"><span class="std std-ref"><span class="pre">wait_for</span></span></a></strong></code> conditions.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">10</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-wait_for"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-parameter-wait-for"><strong>wait_for</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-wait_for" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>List of conditions to evaluate against the output of the command. The task will wait for each condition to be true before moving forward. If the conditional is not true within the configured number of retries, the task fails. See examples.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-partial">partial</strong></p>
|
|
||||||
<p>The module claims to support check mode, but it simply always executes the command.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-none">none</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="notes">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Notes</a><a class="headerlink" href="#notes" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>The module declares that it <strong>supports check mode</strong>. This is a bug and will be changed in community.routeros 3.0.0.</p></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="docsite/ssh-guide.html#ansible-collections-community-routeros-docsite-ssh-guide"><span class="std std-ref">How to connect to RouterOS devices with SSH</span></a></dt><dd><p>How to connect to RouterOS devices with SSH</p>
|
|
||||||
</dd>
|
|
||||||
<dt><a class="reference internal" href="docsite/quoting.html#ansible-collections-community-routeros-docsite-quoting"><span class="std std-ref">How to quote and unquote commands and arguments</span></a></dt><dd><p>How to quote and unquote commands and arguments</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Run command on remote devices</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system routerboard print</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Run command and check to see if output contains routeros</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system resource print</span>
|
|
||||||
<span class="w"> </span><span class="nt">wait_for</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">result[0] contains MikroTik</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Run multiple commands on remote nodes</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system routerboard print</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system identity print</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Run multiple commands and evaluate the output</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system routerboard print</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/interface ethernet print</span>
|
|
||||||
<span class="w"> </span><span class="nt">wait_for</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">result[0] contains x86</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">result[1] contains ether1</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-values">
|
|
||||||
<h2><a class="toc-backref" href="#id7" role="doc-backlink">Return Values</a><a class="headerlink" href="#return-values" title="Link to this heading"></a></h2>
|
|
||||||
<p>Common return values are documented <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/common_return_values.html#common-return-values" title="(in Ansible vdevel)"><span class="xref std std-ref">here</span></a>, the following are the fields unique to this module:</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-failed_conditions"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-return-failed-conditions"><strong>failed_conditions</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-failed_conditions" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of conditionals that have failed</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> failed</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">["...",</span> <span class="pre">"..."]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-stdout"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-return-stdout"><strong>stdout</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-stdout" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The set of responses from the commands</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always apart from low level errors (such as action plugin)</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">["...",</span> <span class="pre">"..."]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-stdout_lines"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-command-module-return-stdout-lines"><strong>stdout_lines</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-stdout_lines" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The value of stdout split into a list</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always apart from low level errors (such as action plugin)</p>
|
|
||||||
<p class="ansible-option-line ansible-option-sample"><strong class="ansible-option-sample-bold">Sample:</strong> <code class="ansible-option-sample docutils literal notranslate"><span class="pre">[["...",</span> <span class="pre">"..."],</span> <span class="pre">["..."],</span> <span class="pre">["..."]]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Egor Zaitsev (@heuels)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api_modify_module.html" class="btn btn-neutral float-left" title="community.routeros.api_modify module – Modify data at paths with API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="facts_module.html" class="btn btn-neutral float-right" title="community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,352 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="../">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>How to connect to RouterOS devices with the RouterOS API — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="../_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="../_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="../_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="../_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="../_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="../_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="../search.html" />
|
|
||||||
<link rel="next" title="How to connect to RouterOS devices with SSH" href="ssh-guide.html" />
|
|
||||||
<link rel="prev" title="Community.Routeros Release Notes" href="../changelog.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="../_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="../index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">How to connect to RouterOS devices with the RouterOS API</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#using-the-community-routeros-api-module-defaults-group">Using the <code class="docutils literal notranslate"><span class="pre">community.routeros.api</span></code> module defaults group</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#setting-up-encryption">Setting up encryption</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#setting-up-a-pki">Setting up a PKI</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#installing-a-certificate-on-a-mikrotik-router">Installing a certificate on a MikroTik router</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="../index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="../index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">How to connect to RouterOS devices with the RouterOS API</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<section id="how-to-connect-to-routeros-devices-with-the-routeros-api">
|
|
||||||
<span id="ansible-collections-community-routeros-docsite-api-guide"></span><h1>How to connect to RouterOS devices with the RouterOS API<a class="headerlink" href="#how-to-connect-to-routeros-devices-with-the-routeros-api" title="Link to this heading"></a></h1>
|
|
||||||
<p>You can use the <a class="reference internal" href="../api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api module</span></a> to connect to a RouterOS device with the RouterOS API. More specific module to modify certain entries are the <a class="reference internal" href="../api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a> and <a class="reference internal" href="../api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">community.routeros.api_find_and_modify</span></a> modules. The <a class="reference internal" href="../api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">community.routeros.api_info module</span></a> allows to retrieve information on specific predefined paths that can be used as input for the <a class="reference internal" href="../api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">community.routeros.api_modify</span></a> module, and the <a class="reference internal" href="../api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">community.routeros.api_facts module</span></a> allows to retrieve Ansible facts using the RouterOS API.</p>
|
|
||||||
<p>No special setup is needed; the module needs to be run on a host that can connect to the device’s API. The most common case is that the module is run on <code class="docutils literal notranslate"><span class="pre">localhost</span></code>, either by using <code class="docutils literal notranslate"><span class="pre">hosts:</span> <span class="pre">localhost</span></code> in the playbook, or by using <code class="docutils literal notranslate"><span class="pre">delegate_to:</span> <span class="pre">localhost</span></code> for the task. The following example shows how to run the equivalent of <code class="docutils literal notranslate"><span class="pre">/ip</span> <span class="pre">address</span> <span class="pre">print</span></code>:</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">RouterOS test with API</span>
|
|
||||||
<span class="w"> </span><span class="nt">hosts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">localhost</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_facts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">vars</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.1.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">admin</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">test1234</span>
|
|
||||||
<span class="w"> </span><span class="nt">tasks</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Get "ip address print"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">hostname</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">username</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># The following options configure TLS/SSL.</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Depending on your setup, these options need different values:</span>
|
|
||||||
<span class="w"> </span><span class="nt">tls</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_certs</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_cert_hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="c1"># If you are using your own PKI, specify the path to your CA certificate here:</span>
|
|
||||||
<span class="w"> </span><span class="c1"># ca_path: /path/to/ca-certificate.pem</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">print_path</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Show IP address of first interface</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">print_path.msg</span><span class="o">[</span><span class="m">0</span><span class="o">]</span><span class="nv">.address</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>This results in the following output:</p>
|
|
||||||
<div class="highlight-ansible-output notranslate"><div class="highlight"><pre><span></span><span class="k">PLAY</span> <span class="p">[</span><span class="l">RouterOS test</span><span class="p">]</span> <span class="nv">*********************************************************************************************</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Get "ip address print"</span><span class="p">]</span> <span class="nv">************************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">localhost</span><span class="p">]</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Show IP address of first interface</span><span class="p">]</span> <span class="nv">************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">localhost</span><span class="p">]</span> <span class="p">=></span> <span class="p">{</span>
|
|
||||||
<span class="nt">"msg"</span><span class="p">:</span> <span class="s">"192.168.2.1/24"</span>
|
|
||||||
<span class="p">}</span>
|
|
||||||
|
|
||||||
<span class="k">PLAY RECAP</span> <span class="nv">*******************************************************************************************************</span>
|
|
||||||
<span class="n">localhost</span> <span class="p">:</span> <span class="k">ok</span><span class="p">=</span><span class="mi">2</span> <span class="k">changed</span><span class="p">=</span><span class="mi">0</span> <span class="k">unreachable</span><span class="p">=</span><span class="mi">0</span> <span class="k">failed</span><span class="p">=</span><span class="mi">0</span> <span class="k">skipped</span><span class="p">=</span><span class="mi">0</span> <span class="k">rescued</span><span class="p">=</span><span class="mi">0</span> <span class="k">ignored</span><span class="p">=</span><span class="mi">0</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>Check out the documentation of the <a class="reference internal" href="../api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api module</span></a> for details on the options.</p>
|
|
||||||
<section id="using-the-community-routeros-api-module-defaults-group">
|
|
||||||
<h2>Using the <code class="docutils literal notranslate"><span class="pre">community.routeros.api</span></code> module defaults group<a class="headerlink" href="#using-the-community-routeros-api-module-defaults-group" title="Link to this heading"></a></h2>
|
|
||||||
<p>To avoid having to specify common parameters for all the API based modules in every task, you can use the <code class="docutils literal notranslate"><span class="pre">community.routeros.api</span></code> <a class="reference external" href="https://docs.ansible.com/ansible/devel/playbook_guide/playbooks_module_defaults.html#module-defaults-groups" title="(in Ansible vdevel)"><span class="xref std std-ref">module defaults group</span></a>:</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">RouterOS test with API</span>
|
|
||||||
<span class="w"> </span><span class="nt">hosts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">localhost</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_facts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">module_defaults</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">group/community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">192.168.1.1</span>
|
|
||||||
<span class="w"> </span><span class="nt">password</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">admin</span>
|
|
||||||
<span class="w"> </span><span class="nt">username</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">test1234</span>
|
|
||||||
<span class="w"> </span><span class="c1"># The following options configure TLS/SSL.</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Depending on your setup, these options need different values:</span>
|
|
||||||
<span class="w"> </span><span class="nt">tls</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_certs</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_cert_hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="c1"># If you are using your own PKI, specify the path to your CA certificate here:</span>
|
|
||||||
<span class="w"> </span><span class="c1"># ca_path: /path/to/ca-certificate.pem</span>
|
|
||||||
<span class="w"> </span><span class="nt">tasks</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Gather facts</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_facts</span><span class="p">:</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Get "ip address print"</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="s">"ip</span><span class="nv"> </span><span class="s">address"</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Change IP address to 192.168.1.1 for interface bridge</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.api_find_and_modify</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">ip address</span>
|
|
||||||
<span class="w"> </span><span class="nt">find</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">interface</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">bridge</span>
|
|
||||||
<span class="w"> </span><span class="nt">values</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">address</span><span class="p">:</span><span class="w"> </span><span class="s">"192.168.1.1/24"</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>Here all three tasks will use the options set for the module defaults group.</p>
|
|
||||||
</section>
|
|
||||||
<section id="setting-up-encryption">
|
|
||||||
<h2>Setting up encryption<a class="headerlink" href="#setting-up-encryption" title="Link to this heading"></a></h2>
|
|
||||||
<p>It is recommended to always use <code class="ansible-option-value docutils literal notranslate"><span><span class="pre">tls=true</span></span></code> when connecting with the API, even if you are only connecting to the device through a trusted network. The following options control how TLS/SSL is used:</p>
|
|
||||||
<dl class="field-list simple">
|
|
||||||
<dt class="field-odd">force_no_cert<span class="colon">:</span></dt>
|
|
||||||
<dd class="field-odd"><p>Setting to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code> connects to the device without a certificate. <strong>This is discouraged to use in production and is susceptible to Man-in-the-Middle attacks</strong>, but might be useful when setting the device up. The default value is <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code>.</p>
|
|
||||||
</dd>
|
|
||||||
<dt class="field-even">validate_certs<span class="colon">:</span></dt>
|
|
||||||
<dd class="field-even"><p>Setting to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> disables any certificate validation. <strong>This is discouraged to use in production</strong>, but is needed when setting the device up. The default value is <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>.</p>
|
|
||||||
</dd>
|
|
||||||
<dt class="field-odd">validate_cert_hostname<span class="colon">:</span></dt>
|
|
||||||
<dd class="field-odd"><p>Setting to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> (default) disables hostname verification during certificate validation. This is needed if the hostnames specified in the certificate do not match the hostname used for connecting (usually the device’s IP). It is recommended to set up the certificate correctly and set this to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>; the default <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code> is chosen for backwards compatibility to an older version of the module.</p>
|
|
||||||
</dd>
|
|
||||||
<dt class="field-even">ca_path<span class="colon">:</span></dt>
|
|
||||||
<dd class="field-even"><p>If you are not using a commercially trusted CA certificate to sign your device’s certificate, or have not included your CA certificate in Python’s truststore, you need to point this option to the CA certificate.</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
<p>We recommend to create a CA certificate that is used to sign the certificates for your RouterOS devices, and have the certificates include the correct hostname(s), including the IP of the device. That way, you can fully enable TLS and be sure that you always talk to the correct device.</p>
|
|
||||||
<section id="setting-up-a-pki">
|
|
||||||
<h3>Setting up a PKI<a class="headerlink" href="#setting-up-a-pki" title="Link to this heading"></a></h3>
|
|
||||||
<p>Please follow the instructions in the <code class="docutils literal notranslate"><span class="pre">community.crypto</span></code> <a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/community/crypto/docsite/guide_ownca.html#ansible-collections-community-crypto-docsite-guide-ownca" title="(in Ansible vdevel)"><span>How to create a small CA</span></a> guide to set up a CA certificate and sign a certificate for your router. You should add a Subject Alternative Name for the IP address (for example <code class="docutils literal notranslate"><span class="pre">IP:192.168.1.1</span></code>) and - if available - for the DNS name (for example <code class="docutils literal notranslate"><span class="pre">DNS:router.local</span></code>) to the certificate.</p>
|
|
||||||
</section>
|
|
||||||
<section id="installing-a-certificate-on-a-mikrotik-router">
|
|
||||||
<h3>Installing a certificate on a MikroTik router<a class="headerlink" href="#installing-a-certificate-on-a-mikrotik-router" title="Link to this heading"></a></h3>
|
|
||||||
<p>Installing the certificate is best done with the SSH connection. (See the <a class="reference internal" href="ssh-guide.html#ansible-collections-community-routeros-docsite-ssh-guide"><span class="std std-ref">How to connect to RouterOS devices with SSH</span></a> guide for more information.) Once the certificate has been installed, and the HTTPS API enabled, it’s easier to work with the API, since it has a quite a few less problems, and returns data as JSON objects instead of text you first have to parse.</p>
|
|
||||||
<p>First you have to convert the certificate and its private key to a <a class="reference external" href="https://en.wikipedia.org/wiki/PKCS_12">PKCS #12 bundle</a>. This can be done with the <a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/community/crypto/openssl_pkcs12_module.html#ansible-collections-community-crypto-openssl-pkcs12-module" title="(in Ansible vdevel)"><span>community.crypto.openssl_pkcs12</span></a>. The following playbook assumes that the certificate is available as <code class="docutils literal notranslate"><span class="pre">keys/{{</span> <span class="pre">inventory_hostname</span> <span class="pre">}}.pem</span></code>, and its private key is available as <code class="docutils literal notranslate"><span class="pre">keys/{{</span> <span class="pre">inventory_hostname</span> <span class="pre">}}.key</span></code>. It generates a random passphrase to protect the PKCS#12 file.</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Install certificates on devices</span>
|
|
||||||
<span class="w"> </span><span class="nt">hosts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">routers</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_facts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">tasks</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">block</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">random_password</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">lookup</span><span class="o">(</span><span class="s1">'community.general.random_string'</span><span class="o">,</span> <span class="nv">length</span><span class="o">=</span><span class="m">32</span><span class="o">,</span> <span class="nv">override_all</span><span class="o">=</span><span class="s1">'0123456789abcdefghijklmnopqrstuvwxyz'</span><span class="o">)</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Create PKCS#12 bundle</span>
|
|
||||||
<span class="w"> </span><span class="nt">openssl_pkcs12</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">keys/</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.p12</span>
|
|
||||||
<span class="w"> </span><span class="nt">certificate_path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">keys/</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.pem</span>
|
|
||||||
<span class="w"> </span><span class="nt">privatekey_path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">keys/</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.key</span>
|
|
||||||
<span class="w"> </span><span class="nt">friendly_name</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="s">'</span>
|
|
||||||
<span class="w"> </span><span class="nt">passphrase</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="nv">random_password</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="nt">mode</span><span class="p">:</span><span class="w"> </span><span class="s">"0600"</span>
|
|
||||||
<span class="w"> </span><span class="nt">changed_when</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">delegate_to</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">localhost</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Copy router certificate onto router</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.netcommon.net_put</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">src</span><span class="p">:</span><span class="w"> </span><span class="s">'keys/</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="s">.p12'</span>
|
|
||||||
<span class="w"> </span><span class="nt">dest</span><span class="p">:</span><span class="w"> </span><span class="s">'</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="s">.p12'</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Install router certificate and clean up</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Import certificate:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/certificate import name=</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain"> file-name=</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.p12 passphrase="</span><span class="cp">{{</span> <span class="nv">random_password</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Remove PKCS12 bundle:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/file remove </span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.p12</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Show certificates</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/certificate print</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">output</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Show result of certificate import</span>
|
|
||||||
<span class="w"> </span><span class="nt">debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">var</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">output.stdout_lines[0]</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Show certificates</span>
|
|
||||||
<span class="w"> </span><span class="nt">debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">var</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">output.stdout_lines[2]</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="nt">always</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Wipe PKCS12 bundle</span>
|
|
||||||
<span class="w"> </span><span class="nt">command</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">wipe keys/</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain">.p12</span>
|
|
||||||
<span class="w"> </span><span class="nt">changed_when</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">delegate_to</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">localhost</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Use certificate</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/ip service set www-ssl address=</span><span class="cp">{{</span> <span class="nv">admin_network</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain"> certificate=</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain"> disabled=no tls-version=only-1.2</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/ip service set api-ssl address=</span><span class="cp">{{</span> <span class="nv">admin_network</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain"> certificate=</span><span class="cp">{{</span> <span class="nv">inventory_hostname</span> <span class="cp">}}</span><span class="l l-Scalar l-Scalar-Plain"> tls-version=only-1.2</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>The playbook also assumes that <code class="docutils literal notranslate"><span class="pre">admin_network</span></code> describes the network from which the HTTPS and API interface can be accessed. This can be for example <code class="docutils literal notranslate"><span class="pre">192.168.1.0/24</span></code>.</p>
|
|
||||||
<p>When this playbook completed successfully, you should be able to use the HTTPS admin interface (reachable in a browser from <code class="docutils literal notranslate"><span class="pre">https://192.168.1.1/</span></code>, with the correct IP inserted), as well as the <a class="reference internal" href="../api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api module</span></a> module with TLS and certificate validation enabled:</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">community.routeros.api</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">...</span>
|
|
||||||
<span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">tls</span><span class="p p-Indicator">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_certs</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">validate_cert_hostname</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span>
|
|
||||||
<span class="w"> </span><span class="nt">ca_path</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/path/to/ca-certificate.pem</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="../changelog.html" class="btn btn-neutral float-left" title="Community.Routeros Release Notes" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="ssh-guide.html" class="btn btn-neutral float-right" title="How to connect to RouterOS devices with SSH" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,173 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="../">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>How to quote and unquote commands and arguments — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="../_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="../_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="../_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="../_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="../_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="../_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="../search.html" />
|
|
||||||
<link rel="next" title="community.routeros.api module – Ansible module for RouterOS API" href="../api_module.html" />
|
|
||||||
<link rel="prev" title="How to connect to RouterOS devices with SSH" href="ssh-guide.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="../_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="../index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="../index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="../index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">How to quote and unquote commands and arguments</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<section id="how-to-quote-and-unquote-commands-and-arguments">
|
|
||||||
<span id="ansible-collections-community-routeros-docsite-quoting"></span><h1>How to quote and unquote commands and arguments<a class="headerlink" href="#how-to-quote-and-unquote-commands-and-arguments" title="Link to this heading"></a></h1>
|
|
||||||
<p>When using the <a class="reference internal" href="../command_module.html#ansible-collections-community-routeros-command-module"><span class="std std-ref">community.routeros.command module</span></a> or the <a class="reference internal" href="../api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">community.routeros.api module</span></a> modules, you need to pass text data in quoted form. While in some cases quoting is not needed (when passing IP addresses or names without spaces, for example), in other cases it is required, like when passing a comment which contains a space.</p>
|
|
||||||
<p>The community.routeros collection provides a set of Jinja2 filter plugins which helps you with these tasks:</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>The <a class="reference internal" href="../quote_argument_value_filter.html#ansible-collections-community-routeros-quote-argument-value-filter"><span class="std std-ref">community.routeros.quote_argument_value filter</span></a> quotes an argument value: <code class="docutils literal notranslate"><span class="pre">'this</span> <span class="pre">is</span> <span class="pre">a</span> <span class="pre">"comment"'</span> <span class="pre">|</span> <span class="pre">community.routeros.quote_argument_value</span> <span class="pre">==</span> <span class="pre">'"this</span> <span class="pre">is</span> <span class="pre">a</span> <span class="pre">\\"comment\\""'</span></code>.</p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../quote_argument_filter.html#ansible-collections-community-routeros-quote-argument-filter"><span class="std std-ref">community.routeros.quote_argument filter</span></a> quotes an argument with or without a value: <code class="docutils literal notranslate"><span class="pre">'comment=this</span> <span class="pre">is</span> <span class="pre">a</span> <span class="pre">"comment"'</span> <span class="pre">|</span> <span class="pre">community.routeros.quote_argument</span> <span class="pre">==</span> <span class="pre">'comment="this</span> <span class="pre">is</span> <span class="pre">a</span> <span class="pre">\\"comment\\""'</span></code>.</p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../join_filter.html#ansible-collections-community-routeros-join-filter"><span class="std std-ref">community.routeros.join filter</span></a> quotes a list of arguments and joins them to one string: <code class="docutils literal notranslate"><span class="pre">['foo=bar',</span> <span class="pre">'comment=foo</span> <span class="pre">is</span> <span class="pre">bar']</span> <span class="pre">|</span> <span class="pre">community.routeros.join</span> <span class="pre">==</span> <span class="pre">'foo=bar</span> <span class="pre">comment="foo</span> <span class="pre">is</span> <span class="pre">bar"'</span></code>.</p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../split_filter.html#ansible-collections-community-routeros-split-filter"><span class="std std-ref">community.routeros.split filter</span></a> splits a command into a list of arguments (with or without values): <code class="docutils literal notranslate"><span class="pre">'foo=bar</span> <span class="pre">comment="foo</span> <span class="pre">is</span> <span class="pre">bar"'</span> <span class="pre">|</span> <span class="pre">community.routeros.split</span> <span class="pre">==</span> <span class="pre">['foo=bar',</span> <span class="pre">'comment=foo</span> <span class="pre">is</span> <span class="pre">bar']</span></code></p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../list_to_dict_filter.html#ansible-collections-community-routeros-list-to-dict-filter"><span class="std std-ref">community.routeros.list_to_dict filter</span></a> splits a list of arguments with values into a dictionary: <code class="docutils literal notranslate"><span class="pre">['foo=bar',</span> <span class="pre">'comment=foo</span> <span class="pre">is</span> <span class="pre">bar']</span> <span class="pre">|</span> <span class="pre">community.routeros.list_to_dict</span> <span class="pre">==</span> <span class="pre">{'foo':</span> <span class="pre">'bar',</span> <span class="pre">'comment':</span> <span class="pre">'foo</span> <span class="pre">is</span> <span class="pre">bar'}</span></code>. It has two optional arguments: <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="../list_to_dict_filter.html#ansible-collections-community-routeros-list-to-dict-filter-parameter-require-assignment"><span class="std std-ref"><span class="pre">require_assignment</span></span></a></strong></code> (default value <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>) allows to accept arguments without values when set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code>; and <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="../list_to_dict_filter.html#ansible-collections-community-routeros-list-to-dict-filter-parameter-skip-empty-values"><span class="std std-ref"><span class="pre">skip_empty_values</span></span></a></strong></code> (default value <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code>) allows to skip arguments whose value is empty.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="ssh-guide.html" class="btn btn-neutral float-left" title="How to connect to RouterOS devices with SSH" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="../api_module.html" class="btn btn-neutral float-right" title="community.routeros.api module – Ansible module for RouterOS API" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,278 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="../">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>How to connect to RouterOS devices with SSH — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="../_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="../_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="../_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="../_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="../_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="../_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="../_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="../search.html" />
|
|
||||||
<link rel="next" title="How to quote and unquote commands and arguments" href="quoting.html" />
|
|
||||||
<link rel="prev" title="How to connect to RouterOS devices with the RouterOS API" href="api-guide.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="../_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="../index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">How to connect to RouterOS devices with SSH</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#important-notes">Important notes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#setting-up-an-inventory">Setting up an inventory</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#connecting-to-the-device">Connecting to the device</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="../split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="../index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="../index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">How to connect to RouterOS devices with SSH</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<section id="how-to-connect-to-routeros-devices-with-ssh">
|
|
||||||
<span id="ansible-collections-community-routeros-docsite-ssh-guide"></span><h1>How to connect to RouterOS devices with SSH<a class="headerlink" href="#how-to-connect-to-routeros-devices-with-ssh" title="Link to this heading"></a></h1>
|
|
||||||
<p>The collection offers two modules to connect to RouterOS devies with SSH:</p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>The <a class="reference internal" href="../facts_module.html#ansible-collections-community-routeros-facts-module"><span class="std std-ref">community.routeros.facts module</span></a> gathers facts about a RouterOS device;</p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../command_module.html#ansible-collections-community-routeros-command-module"><span class="std std-ref">community.routeros.command module</span></a> executes commands on a RouterOS device.</p></li>
|
|
||||||
</ul>
|
|
||||||
<p>The modules need the <a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/ansible/netcommon/network_cli_connection.html#ansible-collections-ansible-netcommon-network-cli-connection" title="(in Ansible vdevel)"><span>ansible.netcommon.network_cli connection plugin</span></a> for this.</p>
|
|
||||||
<section id="important-notes">
|
|
||||||
<h2>Important notes<a class="headerlink" href="#important-notes" title="Link to this heading"></a></h2>
|
|
||||||
<ol class="arabic">
|
|
||||||
<li><p>The SSH-based modules do not support arbitrary symbols in the router’s identity. If you are having trouble connecting to your device, please make sure that your MikroTik’s identity contains only alphanumeric characters and dashes. Also make sure that the identity string is not longer than 19 characters (<a class="reference external" href="https://github.com/ansible-collections/community.routeros/issues/31">see issue for details</a>). Similar problems can happen for unsupported characters in your username.</p></li>
|
|
||||||
<li><p>The <a class="reference internal" href="../command_module.html#ansible-collections-community-routeros-command-module"><span class="std std-ref">community.routeros.command module</span></a> does not support nesting commands and expects every command to start with a forward slash (<code class="docutils literal notranslate"><span class="pre">/</span></code>). Running the following command will produce an error:</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/ip</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">print</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
<li><p>When using the <a class="reference internal" href="../command_module.html#ansible-collections-community-routeros-command-module"><span class="std std-ref">community.routeros.command module</span></a> module, make sure to not specify too long commands. Alternatively, add something like <code class="docutils literal notranslate"><span class="pre">+cet512w</span></code> to the username (replace <code class="docutils literal notranslate"><span class="pre">admin</span></code> with <code class="docutils literal notranslate"><span class="pre">admin+cet512w</span></code>) to tell RouterOS to not wrap before 512 characters in a line (<a class="reference external" href="https://github.com/ansible-collections/community.routeros/issues/6">see issue for details</a>).</p></li>
|
|
||||||
<li><p>The <a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/ansible/netcommon/network_cli_connection.html#ansible-collections-ansible-netcommon-network-cli-connection" title="(in Ansible vdevel)"><span>ansible.netcommon.network_cli connection plugin</span></a> uses <a class="reference external" href="https://pypi.org/project/paramiko/">paramiko</a> by default to connect to devices with SSH. You can set its <code class="ansible-option docutils literal notranslate"><strong><a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/ansible/netcommon/network_cli_connection.html#ansible-collections-ansible-netcommon-network-cli-connection-parameter-ssh-type" title="(in Ansible vdevel)"><span><span class="pre">ssh_type</span></span></a></strong></code> option to <code class="ansible-value docutils literal notranslate"><span class="pre">libssh</span></code> to use <a class="reference external" href="https://pypi.org/project/ansible-pylibssh/">ansible-pylibssh</a> instead, which offers Python bindings to libssh. See its documentation for details.</p></li>
|
|
||||||
<li><p>User is <strong>not allowed</strong> to login via SSH by password to modern Mikrotik if SSH key for the user is added!</p></li>
|
|
||||||
</ol>
|
|
||||||
</section>
|
|
||||||
<section id="setting-up-an-inventory">
|
|
||||||
<h2>Setting up an inventory<a class="headerlink" href="#setting-up-an-inventory" title="Link to this heading"></a></h2>
|
|
||||||
<p>An example inventory <code class="docutils literal notranslate"><span class="pre">hosts</span></code> file for a RouterOS device is as follows:</p>
|
|
||||||
<div class="highlight-ini notranslate"><div class="highlight"><pre><span></span><span class="k">[routers]</span>
|
|
||||||
<span class="na">router ansible_host</span><span class="o">=</span><span class="s">192.168.2.1</span>
|
|
||||||
|
|
||||||
<span class="k">[routers:vars]</span>
|
|
||||||
<span class="na">ansible_connection</span><span class="o">=</span><span class="s">ansible.netcommon.network_cli</span>
|
|
||||||
<span class="na">ansible_network_os</span><span class="o">=</span><span class="s">community.routeros.routeros</span>
|
|
||||||
<span class="na">ansible_user</span><span class="o">=</span><span class="s">admin</span>
|
|
||||||
<span class="na">ansible_ssh_pass</span><span class="o">=</span><span class="s">test1234</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>This tells Ansible that you have a RouterOS device called <code class="docutils literal notranslate"><span class="pre">router</span></code> with IP <code class="docutils literal notranslate"><span class="pre">192.168.2.1</span></code>. Ansible should use the <a class="reference external" href="https://docs.ansible.com/ansible/devel/collections/ansible/netcommon/network_cli_connection.html#ansible-collections-ansible-netcommon-network-cli-connection" title="(in Ansible vdevel)"><span>ansible.netcommon.network_cli connection plugin</span></a> together with the the <a class="reference internal" href="../routeros_cliconf.html#ansible-collections-community-routeros-routeros-cliconf"><span class="std std-ref">community.routeros.routeros cliconf plugin</span></a>. The credentials are stored as <code class="docutils literal notranslate"><span class="pre">ansible_user</span></code> and <code class="docutils literal notranslate"><span class="pre">ansible_ssh_pass</span></code> in the inventory.</p>
|
|
||||||
</section>
|
|
||||||
<section id="connecting-to-the-device">
|
|
||||||
<h2>Connecting to the device<a class="headerlink" href="#connecting-to-the-device" title="Link to this heading"></a></h2>
|
|
||||||
<p>With the above inventory, you can use the following playbook to execute <code class="docutils literal notranslate"><span class="pre">/system</span> <span class="pre">resource</span> <span class="pre">print</span></code> on the device</p>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="nn">---</span>
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">RouterOS test with network_cli connection</span>
|
|
||||||
<span class="w"> </span><span class="nt">hosts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">routers</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_facts</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">false</span>
|
|
||||||
<span class="w"> </span><span class="nt">tasks</span><span class="p">:</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Gather system resources</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.command</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">commands</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">/system resource print</span>
|
|
||||||
<span class="w"> </span><span class="nt">register</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">system_resource_print</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Show system resources</span>
|
|
||||||
<span class="w"> </span><span class="nt">debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">var</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">system_resource_print.stdout_lines</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Gather facts</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.facts</span><span class="p">:</span>
|
|
||||||
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Show a fact</span>
|
|
||||||
<span class="w"> </span><span class="nt">debug</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">msg</span><span class="p">:</span><span class="w"> </span><span class="s">"First</span><span class="nv"> </span><span class="s">IP</span><span class="nv"> </span><span class="s">address:</span><span class="nv"> </span><span class="cp">{{</span> <span class="nv">ansible_net_all_ipv4_addresses</span><span class="o">[</span><span class="m">0</span><span class="o">]</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
<p>This results in the following output:</p>
|
|
||||||
<div class="highlight-ansible-output notranslate"><div class="highlight"><pre><span></span><span class="k">PLAY</span> <span class="p">[</span><span class="l">RouterOS test with network_cli connection</span><span class="p">]</span> <span class="nv">*****************************************************************</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Gather system resources</span><span class="p">]</span> <span class="nv">***********************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">router</span><span class="p">]</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Show system resources</span><span class="p">]</span> <span class="nv">*************************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">router</span><span class="p">]</span> <span class="p">=></span> <span class="p">{</span>
|
|
||||||
<span class="nt">"system_resource_print.stdout_lines"</span><span class="p">:</span> <span class="p">[</span>
|
|
||||||
<span class="p">[</span>
|
|
||||||
<span class="s">"uptime: 3d10h28m51s"</span><span class="p">,</span>
|
|
||||||
<span class="s">" version: 6.48.3 (stable)"</span><span class="p">,</span>
|
|
||||||
<span class="s">" build-time: May/25/2021 06:09:45"</span><span class="p">,</span>
|
|
||||||
<span class="s">" free-memory: 31.2MiB"</span><span class="p">,</span>
|
|
||||||
<span class="s">" total-memory: 64.0MiB"</span><span class="p">,</span>
|
|
||||||
<span class="s">" cpu: MIPS 24Kc V7.4"</span><span class="p">,</span>
|
|
||||||
<span class="s">" cpu-count: 1"</span><span class="p">,</span>
|
|
||||||
<span class="s">" cpu-frequency: 400MHz"</span><span class="p">,</span>
|
|
||||||
<span class="s">" cpu-load: 1%"</span><span class="p">,</span>
|
|
||||||
<span class="s">" free-hdd-space: 54.2MiB"</span><span class="p">,</span>
|
|
||||||
<span class="s">" total-hdd-space: 128.0MiB"</span><span class="p">,</span>
|
|
||||||
<span class="s">" write-sect-since-reboot: 927"</span><span class="p">,</span>
|
|
||||||
<span class="s">" write-sect-total: 51572981"</span><span class="p">,</span>
|
|
||||||
<span class="s">" bad-blocks: 1%"</span><span class="p">,</span>
|
|
||||||
<span class="s">" architecture-name: mipsbe"</span><span class="p">,</span>
|
|
||||||
<span class="s">" board-name: RB750GL"</span><span class="p">,</span>
|
|
||||||
<span class="s">" platform: MikroTik"</span>
|
|
||||||
<span class="p">]</span>
|
|
||||||
<span class="p">]</span>
|
|
||||||
<span class="p">}</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Gather facts</span><span class="p">]</span> <span class="nv">**********************************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">router</span><span class="p">]</span>
|
|
||||||
|
|
||||||
<span class="k">TASK</span> <span class="p">[</span><span class="l">Show a fact</span><span class="p">]</span> <span class="nv">***********************************************************************************************</span>
|
|
||||||
<span class="k">ok</span><span class="p">:</span> <span class="p">[</span><span class="nv">router</span><span class="p">]</span> <span class="p">=></span> <span class="p">{</span>
|
|
||||||
<span class="nt">"msg"</span><span class="p">:</span> <span class="s">"First IP address: 192.168.2.1"</span>
|
|
||||||
<span class="p">}</span>
|
|
||||||
|
|
||||||
<span class="k">PLAY RECAP</span> <span class="nv">*******************************************************************************************************</span>
|
|
||||||
<span class="n">router</span> <span class="p">:</span> <span class="k">ok</span><span class="p">=</span><span class="mi">4</span> <span class="k">changed</span><span class="p">=</span><span class="mi">0</span> <span class="k">unreachable</span><span class="p">=</span><span class="mi">0</span> <span class="k">failed</span><span class="p">=</span><span class="mi">0</span> <span class="k">skipped</span><span class="p">=</span><span class="mi">0</span> <span class="k">rescued</span><span class="p">=</span><span class="mi">0</span> <span class="k">ignored</span><span class="p">=</span><span class="mi">0</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="api-guide.html" class="btn btn-neutral float-left" title="How to connect to RouterOS devices with the RouterOS API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="quoting.html" class="btn btn-neutral float-right" title="How to quote and unquote commands and arguments" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,163 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>Index of all Collection Environment Variables — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">Index of all Collection Environment Variables</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<section id="index-of-all-collection-environment-variables">
|
|
||||||
<span id="list-of-collection-env-vars"></span><h1>Index of all Collection Environment Variables<a class="headerlink" href="#index-of-all-collection-environment-variables" title="Link to this heading"></a></h1>
|
|
||||||
<p>The following index documents all environment variables declared by plugins in collections.
|
|
||||||
Environment variables used by the ansible-core configuration are documented in <a class="reference external" href="https://docs.ansible.com/ansible/devel/reference_appendices/config.html#ansible-configuration-settings" title="(in Ansible vdevel)"><span>Ansible Configuration Settings</span></a>.</p>
|
|
||||||
<p>No environment variables have been defined.</p>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,523 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform" href="routeros_cliconf.html" />
|
|
||||||
<link rel="prev" title="community.routeros.command module – Run commands on remote devices running MikroTik RouterOS" href="command_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#parameters">Parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#attributes">Attributes</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#see-also">See Also</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#returned-facts">Returned Facts</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/modules/facts.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-facts-module"></span><section id="community-routeros-facts-module-collect-facts-from-remote-devices-running-mikrotik-routeros">
|
|
||||||
<h1>community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS<a class="headerlink" href="#community-routeros-facts-module-collect-facts-from-remote-devices-running-mikrotik-routeros" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This module is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.facts</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#parameters" id="id2">Parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#attributes" id="id3">Attributes</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#see-also" id="id4">See Also</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id5">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#returned-facts" id="id6">Returned Facts</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Collects a base set of device facts from a remote device that is running RouterOS. This module prepends all of the base network fact keys with <code class="docutils literal notranslate"><span class="pre">ansible_net_<fact></span></code>. The facts module will always collect a base set of facts from the device and can enable or disable collection of additional facts.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Parameters</a><a class="headerlink" href="#parameters" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-gather_subset"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-parameter-gather-subset"><strong>gather_subset</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-gather_subset" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>When supplied, this argument will restrict the facts collected to a given subset. Possible values for this argument include <code class="ansible-value docutils literal notranslate"><span class="pre">all</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">config</span></code>, <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code>, and <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code>.</p>
|
|
||||||
<p>Can specify a list of values to include a larger subset. Values can also be used with an initial <code class="ansible-value docutils literal notranslate"><span class="pre">!</span></code> to specify that a specific subset should not be collected.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-default-bold">Default:</strong> <code class="ansible-option-default docutils literal notranslate"><span class="pre">["!config"]</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="attributes">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Attributes</a><a class="headerlink" href="#attributes" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Attribute</p></th>
|
|
||||||
<th class="head"><p>Support</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-check_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-attribute-check-mode"><strong>check_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-check_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Can run in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code> and return changed status prediction without modifying target.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-diff_mode"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-attribute-diff-mode"><strong>diff_mode</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-diff_mode" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong> <span class="ansible-attribute-support-na">N/A</span></p>
|
|
||||||
<p>This action does not modify state.</p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Will return details on what has changed (or possibly needs changing in <code class="docutils literal notranslate"><span class="pre">check_mode</span></code>), when in diff mode.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-facts"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-attribute-facts"><strong>facts</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-facts" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-label">Support: </strong><strong class="ansible-attribute-support-full">full</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Action returns an <code class="docutils literal notranslate"><span class="pre">ansible_facts</span></code> dictionary that will update existing host facts.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="attribute-platform"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-attribute-platform"><strong>platform</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#attribute-platform" title="Permalink to this attribute"></a></div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p><strong class="ansible-attribute-support-property">Platform:</strong> <strong class="ansible-attribute-support-full">RouterOS</strong></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Target OS/families that can be operated against.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="see-also">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">See Also</a><a class="headerlink" href="#see-also" title="Link to this heading"></a></h2>
|
|
||||||
<div class="admonition seealso">
|
|
||||||
<p class="admonition-title">See also</p>
|
|
||||||
<dl class="simple">
|
|
||||||
<dt><a class="reference internal" href="docsite/ssh-guide.html#ansible-collections-community-routeros-docsite-ssh-guide"><span class="std std-ref">How to connect to RouterOS devices with SSH</span></a></dt><dd><p>How to connect to RouterOS devices with SSH</p>
|
|
||||||
</dd>
|
|
||||||
</dl>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Collect all facts from the device</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.facts</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_subset</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">all</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Collect only the config and default facts</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.facts</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_subset</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">config</span>
|
|
||||||
|
|
||||||
<span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Do not collect hardware facts</span>
|
|
||||||
<span class="w"> </span><span class="nt">community.routeros.facts</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">gather_subset</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="s">"!hardware"</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="returned-facts">
|
|
||||||
<h2><a class="toc-backref" href="#id6" role="doc-backlink">Returned Facts</a><a class="headerlink" href="#returned-facts" title="Link to this heading"></a></h2>
|
|
||||||
<p>Facts returned by this module are added/updated in the <code class="docutils literal notranslate"><span class="pre">hostvars</span></code> host facts and can be referenced by name just like any other host fact. They do not need to be registered in order to use them.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_all_ipv4_addresses"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-all-ipv4-addresses"><strong>ansible_net_all_ipv4_addresses</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_all_ipv4_addresses" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>All IPv4 addresses configured on the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_all_ipv6_addresses"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-all-ipv6-addresses"><strong>ansible_net_all_ipv6_addresses</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_all_ipv6_addresses" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>All IPv6 addresses configured on the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_arch"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-arch"><strong>ansible_net_arch</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_arch" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The CPU architecture of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_instance"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-bgp-instance"><strong>ansible_net_bgp_instance</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_instance" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP instance information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_peer"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-bgp-peer"><strong>ansible_net_bgp_peer</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_peer" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP peer information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_bgp_vpnv4_route"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-bgp-vpnv4-route"><strong>ansible_net_bgp_vpnv4_route</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_bgp_vpnv4_route" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with BGP vpnv4 route information.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_config"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-config"><strong>ansible_net_config</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_config" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The current active config from the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">config</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_config_nonverbose"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-config-nonverbose"><strong>ansible_net_config_nonverbose</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_config_nonverbose" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
<p><em class="ansible-option-versionadded">added in community.routeros 1.2.0</em></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The current active config from the device in minimal form.</p>
|
|
||||||
<p>This value is idempotent in the sense that if the facts module is run twice and the device’s config was not changed between the runs, the value is identical. This is achieved by running <code class="docutils literal notranslate"><span class="pre">/export</span></code> and stripping the timestamp from the comment in the first line.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">config</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_cpu_load"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-cpu-load"><strong>ansible_net_cpu_load</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_cpu_load" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Current CPU load.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_gather_subset"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-gather-subset"><strong>ansible_net_gather_subset</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_gather_subset" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of fact subsets collected from the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> always</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_hostname"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-hostname"><strong>ansible_net_hostname</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_hostname" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The configured hostname of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_interfaces"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-interfaces"><strong>ansible_net_interfaces</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_interfaces" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A hash of all interfaces running on the system.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_memfree_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-memfree-mb"><strong>ansible_net_memfree_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_memfree_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The available free memory on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_memtotal_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-memtotal-mb"><strong>ansible_net_memtotal_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_memtotal_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">integer</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The total memory on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_model"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-model"><strong>ansible_net_model</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_model" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The model name returned from the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_neighbors"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-neighbors"><strong>ansible_net_neighbors</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_neighbors" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of neighbors from the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">interfaces</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_ospf_instance"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-ospf-instance"><strong>ansible_net_ospf_instance</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_ospf_instance" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with OSPF instances.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_ospf_neighbor"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-ospf-neighbor"><strong>ansible_net_ospf_neighbor</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_ospf_neighbor" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary with OSPF neighbors.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_route"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-route"><strong>ansible_net_route</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_route" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary for routes in all routing tables.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">routing</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_serialnum"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-serialnum"><strong>ansible_net_serialnum</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_serialnum" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The serial number of the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_spacefree_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-spacefree-mb"><strong>ansible_net_spacefree_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_spacefree_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The available disk space on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_spacetotal_mb"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-spacetotal-mb"><strong>ansible_net_spacetotal_mb</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_spacetotal_mb" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The total disk space on the remote device in MiB.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">hardware</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_uptime"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-uptime"><strong>ansible_net_uptime</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_uptime" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The uptime of the device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-ansible_facts/ansible_net_version"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-facts-module-return-ansible-facts-ansible-net-version"><strong>ansible_net_version</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-ansible_facts/ansible_net_version" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The operating system version running on the remote device.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> <code class="ansible-option docutils literal notranslate"><strong><a class="reference internal" href="#ansible-collections-community-routeros-facts-module-parameter-gather-subset"><span class="std std-ref"><span class="pre">gather_subset</span></span></a></strong></code> contains <code class="ansible-value docutils literal notranslate"><span class="pre">default</span></code></p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Egor Zaitsev (@heuels)</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="command_module.html" class="btn btn-neutral float-left" title="community.routeros.command module – Run commands on remote devices running MikroTik RouterOS" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="routeros_cliconf.html" class="btn btn-neutral float-right" title="community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,262 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>Community.Routeros — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="Community.Routeros Release Notes" href="changelog.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="#" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="#">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="#" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">Community.Routeros</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<section id="community-routeros">
|
|
||||||
<span id="plugins-in-community-routeros"></span><h1>Community.Routeros<a class="headerlink" href="#community-routeros" title="Link to this heading"></a></h1>
|
|
||||||
<p>Collection version 2.20.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#description" id="id1">Description</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#communication" id="id2">Communication</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#changelog" id="id3">Changelog</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#guides" id="id4">Guides</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#plugin-index" id="id5">Plugin Index</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="description">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Description</a><a class="headerlink" href="#description" title="Link to this heading"></a></h2>
|
|
||||||
<p>Modules and plugins for MikroTik RouterOS</p>
|
|
||||||
<p><strong>Authors:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Egor Zaitsev (github.com/heuels)</p></li>
|
|
||||||
<li><p>Nikolay Dachev (github.com/NikolayDachev)</p></li>
|
|
||||||
<li><p>Felix Fontein (github.com/felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<p><strong>Supported ansible-core versions:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>2.9.10 or newer</p></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="communication">
|
|
||||||
<span id="communication-for-community-routeros"></span><h2><a class="toc-backref" href="#id2" role="doc-backlink">Communication</a><a class="headerlink" href="#communication" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Forum: <a class="reference external" href="https://forum.ansible.com/c/help/6/none">Ansible Forum: General usage and support questions</a>.</p></li>
|
|
||||||
<li><p>Forum: <a class="reference external" href="https://forum.ansible.com/tag/routeros">Ansible Forum: Discussions about RouterOS</a>.</p></li>
|
|
||||||
<li><p>Matrix room <code class="docutils literal notranslate"><span class="pre">#users:ansible.im</span></code>: <a class="reference external" href="https://matrix.to/#/#users:ansible.im">General usage and support questions</a>.</p></li>
|
|
||||||
<li><p>IRC channel <code class="docutils literal notranslate"><span class="pre">#ansible</span></code> (Libera network):
|
|
||||||
<a class="reference external" href="https://web.libera.chat/?channel=#ansible">General usage and support questions</a>.</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="changelog">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Changelog</a><a class="headerlink" href="#changelog" title="Link to this heading"></a></h2>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="guides">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Guides</a><a class="headerlink" href="#guides" title="Link to this heading"></a></h2>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="plugin-index">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Plugin Index</a><a class="headerlink" href="#plugin-index" title="Link to this heading"></a></h2>
|
|
||||||
<p>These are the plugins in the community.routeros collection:</p>
|
|
||||||
<section id="modules">
|
|
||||||
<h3>Modules<a class="headerlink" href="#modules" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="api_module.html#ansible-collections-community-routeros-api-module"><span class="std std-ref">api module</span></a> – Ansible module for RouterOS API</p></li>
|
|
||||||
<li><p><a class="reference internal" href="api_facts_module.html#ansible-collections-community-routeros-api-facts-module"><span class="std std-ref">api_facts module</span></a> – Collect facts from remote devices running MikroTik RouterOS using the API</p></li>
|
|
||||||
<li><p><a class="reference internal" href="api_find_and_modify_module.html#ansible-collections-community-routeros-api-find-and-modify-module"><span class="std std-ref">api_find_and_modify module</span></a> – Find and modify information using the API</p></li>
|
|
||||||
<li><p><a class="reference internal" href="api_info_module.html#ansible-collections-community-routeros-api-info-module"><span class="std std-ref">api_info module</span></a> – Retrieve information from API</p></li>
|
|
||||||
<li><p><a class="reference internal" href="api_modify_module.html#ansible-collections-community-routeros-api-modify-module"><span class="std std-ref">api_modify module</span></a> – Modify data at paths with API</p></li>
|
|
||||||
<li><p><a class="reference internal" href="command_module.html#ansible-collections-community-routeros-command-module"><span class="std std-ref">command module</span></a> – Run commands on remote devices running MikroTik RouterOS</p></li>
|
|
||||||
<li><p><a class="reference internal" href="facts_module.html#ansible-collections-community-routeros-facts-module"><span class="std std-ref">facts module</span></a> – Collect facts from remote devices running MikroTik RouterOS</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="cliconf-plugins">
|
|
||||||
<h3>Cliconf Plugins<a class="headerlink" href="#cliconf-plugins" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="routeros_cliconf.html#ansible-collections-community-routeros-routeros-cliconf"><span class="std std-ref">routeros cliconf</span></a> – Use routeros cliconf to run command on MikroTik RouterOS platform</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="filter-plugins">
|
|
||||||
<h3>Filter Plugins<a class="headerlink" href="#filter-plugins" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="join_filter.html#ansible-collections-community-routeros-join-filter"><span class="std std-ref">join filter</span></a> – Join a list of arguments to a command</p></li>
|
|
||||||
<li><p><a class="reference internal" href="list_to_dict_filter.html#ansible-collections-community-routeros-list-to-dict-filter"><span class="std std-ref">list_to_dict filter</span></a> – Convert a list of arguments to a dictionary</p></li>
|
|
||||||
<li><p><a class="reference internal" href="quote_argument_filter.html#ansible-collections-community-routeros-quote-argument-filter"><span class="std std-ref">quote_argument filter</span></a> – Quote an argument</p></li>
|
|
||||||
<li><p><a class="reference internal" href="quote_argument_value_filter.html#ansible-collections-community-routeros-quote-argument-value-filter"><span class="std std-ref">quote_argument_value filter</span></a> – Quote an argument value</p></li>
|
|
||||||
<li><p><a class="reference internal" href="split_filter.html#ansible-collections-community-routeros-split-filter"><span class="std std-ref">split filter</span></a> – Split a command into arguments</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="toctree-wrapper compound">
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="changelog.html" class="btn btn-neutral float-right" title="Community.Routeros Release Notes" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,270 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.join filter – Join a list of arguments to a command — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary" href="list_to_dict_filter.html" />
|
|
||||||
<link rel="prev" title="community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform" href="routeros_cliconf.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.join filter – Join a list of arguments to a command</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#input">Input</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-value">Return Value</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.join filter – Join a list of arguments to a command</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/filter/join.yml?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-join-filter"></span><section id="community-routeros-join-filter-join-a-list-of-arguments-to-a-command">
|
|
||||||
<h1>community.routeros.join filter – Join a list of arguments to a command<a class="headerlink" href="#community-routeros-join-filter-join-a-list-of-arguments-to-a-command" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This filter plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.join</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.0.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#input" id="id2">Input</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id3">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-value" id="id4">Return Value</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Join and quotes a list of arguments to a command.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="input">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Input</a><a class="headerlink" href="#input" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes the input of the filter, the value before <code class="docutils literal notranslate"><span class="pre">|</span> <span class="pre">community.routeros.join</span></code>.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-_input"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-join-filter-parameter-input"><strong>Input</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-_input" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of arguments to quote and join.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Join arguments for a RouterOS CLI command</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">arguments</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="o">[</span><span class="s1">'foo=bar'</span><span class="o">,</span> <span class="s1">'comment=foo is bar'</span><span class="o">]</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.join</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Should result in 'foo=bar comment="foo is bar"'</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-value">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Return Value</a><a class="headerlink" href="#return-value" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-_value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-join-filter-return-value"><strong>Return value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-_value" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The joined and quoted result.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="routeros_cliconf.html" class="btn btn-neutral float-left" title="community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="list_to_dict_filter.html" class="btn btn-neutral float-right" title="community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,310 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.quote_argument filter – Quote an argument" href="quote_argument_filter.html" />
|
|
||||||
<link rel="prev" title="community.routeros.join filter – Join a list of arguments to a command" href="join_filter.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#input">Input</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#keyword-parameters">Keyword parameters</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-value">Return Value</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/filter/list_to_dict.yml?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-list-to-dict-filter"></span><section id="community-routeros-list-to-dict-filter-convert-a-list-of-arguments-to-a-dictionary">
|
|
||||||
<h1>community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary<a class="headerlink" href="#community-routeros-list-to-dict-filter-convert-a-list-of-arguments-to-a-dictionary" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This filter plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.list_to_dict</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.0.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#input" id="id2">Input</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#keyword-parameters" id="id3">Keyword parameters</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id4">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-value" id="id5">Return Value</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Convert a list of arguments to a dictionary.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="input">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Input</a><a class="headerlink" href="#input" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes the input of the filter, the value before <code class="docutils literal notranslate"><span class="pre">|</span> <span class="pre">community.routeros.list_to_dict</span></code>.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-_input"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-list-to-dict-filter-parameter-input"><strong>Input</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-_input" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A list of assignments. Can be the result of the <a class="reference internal" href="split_filter.html#ansible-collections-community-routeros-split-filter"><span class="std std-ref">community.routeros.split</span></a> filter.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="keyword-parameters">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Keyword parameters</a><a class="headerlink" href="#keyword-parameters" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes keyword parameters of the filter. These are the values <code class="docutils literal notranslate"><span class="pre">key1=value1</span></code>, <code class="docutils literal notranslate"><span class="pre">key2=value2</span></code> and so on in the following
|
|
||||||
example: <code class="docutils literal notranslate"><span class="pre">input</span> <span class="pre">|</span> <span class="pre">community.routeros.list_to_dict(key1=value1,</span> <span class="pre">key2=value2,</span> <span class="pre">...)</span></code></p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-require_assignment"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-list-to-dict-filter-parameter-require-assignment"><strong>require_assignment</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-require_assignment" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Allows to accept arguments without values when set to <code class="ansible-value docutils literal notranslate"><span class="pre">false</span></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">false</span></code></p></li>
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">true</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
<tr class="row-odd"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-skip_empty_values"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-list-to-dict-filter-parameter-skip-empty-values"><strong>skip_empty_values</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-skip_empty_values" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">boolean</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>Allows to skip arguments whose value is empty when set to <code class="ansible-value docutils literal notranslate"><span class="pre">true</span></code>.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-choices">Choices:</strong></p>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><code class="ansible-option-default-bold docutils literal notranslate"><strong><span class="pre">false</span></strong></code> <span class="ansible-option-choices-default-mark">← (default)</span></p></li>
|
|
||||||
<li><p><code class="ansible-option-choices-entry docutils literal notranslate"><span class="pre">true</span></code></p></li>
|
|
||||||
</ul>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Convert a list to a dictionary</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">dictionary</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="o">[</span><span class="s1">'foo=bar'</span><span class="o">,</span> <span class="s1">'comment=foo is bar'</span><span class="o">]</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.list_to_dict</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># dictionary == {'foo': 'bar', 'comment': 'foo is bar'}</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-value">
|
|
||||||
<h2><a class="toc-backref" href="#id5" role="doc-backlink">Return Value</a><a class="headerlink" href="#return-value" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-_value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-list-to-dict-filter-return-value"><strong>Return value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-_value" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">dictionary</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A dictionary representation of the input data.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="join_filter.html" class="btn btn-neutral float-left" title="community.routeros.join filter – Join a list of arguments to a command" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="quote_argument_filter.html" class="btn btn-neutral float-right" title="community.routeros.quote_argument filter – Quote an argument" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,270 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.quote_argument filter – Quote an argument — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.quote_argument_value filter – Quote an argument value" href="quote_argument_value_filter.html" />
|
|
||||||
<link rel="prev" title="community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary" href="list_to_dict_filter.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.quote_argument filter – Quote an argument</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#input">Input</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-value">Return Value</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.quote_argument filter – Quote an argument</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/filter/quote_argument.yml?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-quote-argument-filter"></span><section id="community-routeros-quote-argument-filter-quote-an-argument">
|
|
||||||
<h1>community.routeros.quote_argument filter – Quote an argument<a class="headerlink" href="#community-routeros-quote-argument-filter-quote-an-argument" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This filter plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.quote_argument</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.0.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#input" id="id2">Input</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id3">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-value" id="id4">Return Value</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Quote an argument.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="input">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Input</a><a class="headerlink" href="#input" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes the input of the filter, the value before <code class="docutils literal notranslate"><span class="pre">|</span> <span class="pre">community.routeros.quote_argument</span></code>.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-_input"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-quote-argument-filter-parameter-input"><strong>Input</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-_input" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>An argument to quote.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Quote a RouterOS CLI command argument</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">quoted</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="s1">'comment=this is a "comment"'</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.quote_argument</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Should result in 'comment="this is a \"comment\""'</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-value">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Return Value</a><a class="headerlink" href="#return-value" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-_value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-quote-argument-filter-return-value"><strong>Return value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-_value" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The quoted argument.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="list_to_dict_filter.html" class="btn btn-neutral float-left" title="community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="quote_argument_value_filter.html" class="btn btn-neutral float-right" title="community.routeros.quote_argument_value filter – Quote an argument value" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,270 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.quote_argument_value filter – Quote an argument value — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.split filter – Split a command into arguments" href="split_filter.html" />
|
|
||||||
<link rel="prev" title="community.routeros.quote_argument filter – Quote an argument" href="quote_argument_filter.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.quote_argument_value filter – Quote an argument value</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#input">Input</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-value">Return Value</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.quote_argument_value filter – Quote an argument value</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/filter/quote_argument_value.yml?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-quote-argument-value-filter"></span><section id="community-routeros-quote-argument-value-filter-quote-an-argument-value">
|
|
||||||
<h1>community.routeros.quote_argument_value filter – Quote an argument value<a class="headerlink" href="#community-routeros-quote-argument-value-filter-quote-an-argument-value" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This filter plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.quote_argument_value</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.0.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#input" id="id2">Input</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id3">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-value" id="id4">Return Value</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Quote an argument value.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="input">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Input</a><a class="headerlink" href="#input" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes the input of the filter, the value before <code class="docutils literal notranslate"><span class="pre">|</span> <span class="pre">community.routeros.quote_argument_value</span></code>.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-_input"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-quote-argument-value-filter-parameter-input"><strong>Input</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-_input" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>An argument value to quote.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Quote a RouterOS CLI command argument's value</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">quoted</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="s1">'this is a "comment"'</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.quote_argument_value</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Should result in '"this is a \"comment\""'</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-value">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Return Value</a><a class="headerlink" href="#return-value" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-_value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-quote-argument-value-filter-return-value"><strong>Return value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-_value" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The quoted argument value.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="quote_argument_filter.html" class="btn btn-neutral float-left" title="community.routeros.quote_argument filter – Quote an argument" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="split_filter.html" class="btn btn-neutral float-right" title="community.routeros.split filter – Split a command into arguments" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,214 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="next" title="community.routeros.join filter – Join a list of arguments to a command" href="join_filter.html" />
|
|
||||||
<link rel="prev" title="community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS" href="facts_module.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/cliconf/routeros.py?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-routeros-cliconf"></span><section id="community-routeros-routeros-cliconf-use-routeros-cliconf-to-run-command-on-mikrotik-routeros-platform">
|
|
||||||
<h1>community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform<a class="headerlink" href="#community-routeros-routeros-cliconf-use-routeros-cliconf-to-run-command-on-mikrotik-routeros-platform" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This cliconf plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.routeros</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>This routeros plugin provides low level abstraction apis for sending and receiving CLI commands from MikroTik RouterOS network devices.</p></li>
|
|
||||||
</ul>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Egor Zaitsev (@heuels)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="facts_module.html" class="btn btn-neutral float-left" title="community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
<a href="join_filter.html" class="btn btn-neutral float-right" title="community.routeros.join filter – Join a list of arguments to a command" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,176 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>Search — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<script src="_static/searchtools.js"></script>
|
|
||||||
<script src="_static/language_data.js"></script>
|
|
||||||
<link rel="search" title="Search" href="#" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="#" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="split_filter.html">community.routeros.split filter – Split a command into arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">Search</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<noscript>
|
|
||||||
<div id="fallback" class="admonition warning">
|
|
||||||
<p class="last">
|
|
||||||
Please activate JavaScript to enable the search functionality.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</noscript>
|
|
||||||
|
|
||||||
|
|
||||||
<div id="search-results">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
<script>
|
|
||||||
jQuery(function() { Search.loadIndex("searchindex.js"); });
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<script id="searchindexloader"></script>
|
|
||||||
<!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,268 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html class="writer-html5" lang="en" data-content_root="./">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
<meta content="2.16.3" name="antsibull-docs" />
|
|
||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
||||||
<title>community.routeros.split filter – Split a command into arguments — Community.Routeros Collection documentation</title>
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=41de9001" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/ansible.css?v=c5b67dd2" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/antsibull-minimal.css" />
|
|
||||||
<link rel="stylesheet" type="text/css" href="_static/css/rtd-ethical-ads.css?v=289b023e" />
|
|
||||||
|
|
||||||
|
|
||||||
<link rel="shortcut icon" href="_static/images/Ansible-Mark-RGB_Black.png"/>
|
|
||||||
<script src="_static/jquery.js?v=5d32c60e"></script>
|
|
||||||
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
||||||
<script src="_static/documentation_options.js?v=7f41d439"></script>
|
|
||||||
<script src="_static/doctools.js?v=9bcbadda"></script>
|
|
||||||
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
||||||
<script src="_static/js/theme.js"></script>
|
|
||||||
<link rel="search" title="Search" href="search.html" />
|
|
||||||
<link rel="prev" title="community.routeros.quote_argument_value filter – Quote an argument value" href="quote_argument_value_filter.html" /><!-- extra head elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body class="wy-body-for-nav"><!-- extra body elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
<div class="DocSite-globalNav ansibleNav">
|
|
||||||
<ul>
|
|
||||||
<li><a href="https://www.ansible.com/blog" target="_blank">Blog</a></li>
|
|
||||||
<li><a href="https://forum.ansible.com/" target="_blank">Ansible community forum</a></li>
|
|
||||||
<li><a href="https://docs.ansible.com/" target="_blank">Documentation</a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<a class="DocSite-nav" href="https://ansible-collections.github.io/community.routeros/branch/main/" style="padding-bottom: 30px;">
|
|
||||||
|
|
||||||
<img class="DocSiteNav-logo"
|
|
||||||
src="_static/images/Ansible-Mark-RGB_White.png"
|
|
||||||
alt="Ansible Logo">
|
|
||||||
<div class="DocSiteNav-title">Community.Routeros Collection Docs</div>
|
|
||||||
</a>
|
|
||||||
<div class="wy-grid-for-nav">
|
|
||||||
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
||||||
<div class="wy-side-scroll">
|
|
||||||
<div class="wy-side-nav-search" >
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a href="index.html" class="icon icon-home">
|
|
||||||
Community.Routeros Collection
|
|
||||||
</a><!--- Based on https://github.com/rtfd/sphinx_rtd_theme/pull/438/files -->
|
|
||||||
|
|
||||||
<div class="version">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
<div role="search">
|
|
||||||
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
|
|
||||||
<label class="sr-only" for="q">Search docs:</label>
|
|
||||||
<input type="text" class="st-default-search-input" id="q" name="q" placeholder="Search docs" />
|
|
||||||
<input type="hidden" name="check_keywords" value="yes" />
|
|
||||||
<input type="hidden" name="area" value="default" />
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="changelog.html">Community.Routeros Release Notes</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/api-guide.html">How to connect to RouterOS devices with the RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/ssh-guide.html">How to connect to RouterOS devices with SSH</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="docsite/quoting.html">How to quote and unquote commands and arguments</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_module.html">community.routeros.api module – Ansible module for RouterOS API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_facts_module.html">community.routeros.api_facts module – Collect facts from remote devices running MikroTik RouterOS using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_find_and_modify_module.html">community.routeros.api_find_and_modify module – Find and modify information using the API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_info_module.html">community.routeros.api_info module – Retrieve information from API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="api_modify_module.html">community.routeros.api_modify module – Modify data at paths with API</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="command_module.html">community.routeros.command module – Run commands on remote devices running MikroTik RouterOS</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="facts_module.html">community.routeros.facts module – Collect facts from remote devices running MikroTik RouterOS</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="routeros_cliconf.html">community.routeros.routeros cliconf – Use routeros cliconf to run command on MikroTik RouterOS platform</a></li>
|
|
||||||
</ul>
|
|
||||||
<ul class="current">
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="join_filter.html">community.routeros.join filter – Join a list of arguments to a command</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="list_to_dict_filter.html">community.routeros.list_to_dict filter – Convert a list of arguments to a dictionary</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_filter.html">community.routeros.quote_argument filter – Quote an argument</a></li>
|
|
||||||
<li class="toctree-l1"><a class="reference internal" href="quote_argument_value_filter.html">community.routeros.quote_argument_value filter – Quote an argument value</a></li>
|
|
||||||
<li class="toctree-l1 current"><a class="current reference internal" href="#">community.routeros.split filter – Split a command into arguments</a><ul>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#synopsis">Synopsis</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#input">Input</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#examples">Examples</a></li>
|
|
||||||
<li class="toctree-l2"><a class="reference internal" href="#return-value">Return Value</a><ul>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#authors">Authors</a></li>
|
|
||||||
<li class="toctree-l3"><a class="reference internal" href="#collection-links">Collection links</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<!-- extra nav elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
||||||
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
||||||
<a href="index.html">Community.Routeros Collection</a>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="wy-nav-content">
|
|
||||||
<div class="rst-content">
|
|
||||||
<div role="navigation" aria-label="Page navigation">
|
|
||||||
<ul class="wy-breadcrumbs">
|
|
||||||
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
||||||
<li class="breadcrumb-item active">community.routeros.split filter – Split a command into arguments</li>
|
|
||||||
<li class="wy-breadcrumbs-aside">
|
|
||||||
<!-- User defined GitHub URL -->
|
|
||||||
<a href="https://github.com/ansible-collections/community.routeros/edit/main/plugins/filter/split.yml?description=%23%23%23%23%23%20SUMMARY%0A%3C!—%20Your%20description%20here%20–%3E%0A%0A%0A%23%23%23%23%23%20ISSUE%20TYPE%0A-%20Docs%20Pull%20Request%0A%0A%2Blabel:%20docsite_pr" class="fa fa-github"> Edit on GitHub</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
<hr/>
|
|
||||||
</div>
|
|
||||||
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
||||||
|
|
||||||
|
|
||||||
<div itemprop="articleBody">
|
|
||||||
|
|
||||||
<span class="target" id="ansible-collections-community-routeros-split-filter"></span><section id="community-routeros-split-filter-split-a-command-into-arguments">
|
|
||||||
<h1>community.routeros.split filter – Split a command into arguments<a class="headerlink" href="#community-routeros-split-filter-split-a-command-into-arguments" title="Link to this heading"></a></h1>
|
|
||||||
<div class="admonition note">
|
|
||||||
<p class="admonition-title">Note</p>
|
|
||||||
<p>This filter plugin is part of the <a class="reference external" href="https://galaxy.ansible.com/ui/repo/published/community/routeros/">community.routeros collection</a> (version 2.20.0).</p>
|
|
||||||
<p>It is not included in <code class="docutils literal notranslate"><span class="pre">ansible-core</span></code>.
|
|
||||||
To check whether it is installed, run <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">list</span></code>.</p>
|
|
||||||
<p>To install it, use: <code class="code docutils literal notranslate"><span class="pre">ansible-galaxy</span> <span class="pre">collection</span> <span class="pre">install</span> <span class="pre">community.routeros</span></code>.</p>
|
|
||||||
<p>To use it in a playbook, specify: <code class="code docutils literal notranslate"><span class="pre">community.routeros.split</span></code>.</p>
|
|
||||||
</div>
|
|
||||||
<p class="ansible-version-added">New in community.routeros 2.0.0</p>
|
|
||||||
<nav class="contents local" id="contents">
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p><a class="reference internal" href="#synopsis" id="id1">Synopsis</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#input" id="id2">Input</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#examples" id="id3">Examples</a></p></li>
|
|
||||||
<li><p><a class="reference internal" href="#return-value" id="id4">Return Value</a></p></li>
|
|
||||||
</ul>
|
|
||||||
</nav>
|
|
||||||
<section id="synopsis">
|
|
||||||
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Synopsis</a><a class="headerlink" href="#synopsis" title="Link to this heading"></a></h2>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Split a command into arguments.</p></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
<section id="input">
|
|
||||||
<h2><a class="toc-backref" href="#id2" role="doc-backlink">Input</a><a class="headerlink" href="#input" title="Link to this heading"></a></h2>
|
|
||||||
<p>This describes the input of the filter, the value before <code class="docutils literal notranslate"><span class="pre">|</span> <span class="pre">community.routeros.split</span></code>.</p>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Parameter</p></th>
|
|
||||||
<th class="head"><p>Comments</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="parameter-_input"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-split-filter-parameter-input"><strong>Input</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#parameter-_input" title="Permalink to this option"></a><p class="ansible-option-type-line"><span class="ansible-option-type">string</span> / <span class="ansible-option-required">required</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>A command.</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</section>
|
|
||||||
<section id="examples">
|
|
||||||
<h2><a class="toc-backref" href="#id3" role="doc-backlink">Examples</a><a class="headerlink" href="#examples" title="Link to this heading"></a></h2>
|
|
||||||
<div class="highlight-yaml+jinja notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">Split command into list of arguments</span>
|
|
||||||
<span class="w"> </span><span class="nt">ansible.builtin.set_fact</span><span class="p">:</span>
|
|
||||||
<span class="w"> </span><span class="nt">argument_list</span><span class="p">:</span><span class="w"> </span><span class="s">"</span><span class="cp">{{</span> <span class="s1">'foo=bar comment="foo is bar" baz'</span> <span class="o">|</span> <span class="nf">community</span><span class="nv">.routeros.split</span> <span class="cp">}}</span><span class="s">"</span>
|
|
||||||
<span class="w"> </span><span class="c1"># Should result in ['foo=bar', 'comment=foo is bar', 'baz']</span>
|
|
||||||
</pre></div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="return-value">
|
|
||||||
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Return Value</a><a class="headerlink" href="#return-value" title="Link to this heading"></a></h2>
|
|
||||||
<table class="longtable ansible-option-table docutils align-default" style="width: 100%">
|
|
||||||
<thead>
|
|
||||||
<tr class="row-odd"><th class="head"><p>Key</p></th>
|
|
||||||
<th class="head"><p>Description</p></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr class="row-even"><td><div class="ansible-option-cell">
|
|
||||||
<div class="ansibleOptionAnchor" id="return-_value"></div><p class="ansible-option-title" id="ansible-collections-community-routeros-split-filter-return-value"><strong>Return value</strong></p>
|
|
||||||
<a class="ansibleOptionLink" href="#return-_value" title="Permalink to this return value"></a><p class="ansible-option-type-line"><span class="ansible-option-type">list</span> / <span class="ansible-option-elements">elements=string</span></p>
|
|
||||||
</div></td>
|
|
||||||
<td><div class="ansible-option-cell"><p>The list of arguments.</p>
|
|
||||||
<p class="ansible-option-line"><strong class="ansible-option-returned-bold">Returned:</strong> success</p>
|
|
||||||
</div></td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
<section id="authors">
|
|
||||||
<h3>Authors<a class="headerlink" href="#authors" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="simple">
|
|
||||||
<li><p>Felix Fontein (@felixfontein)</p></li>
|
|
||||||
</ul>
|
|
||||||
<div class="admonition hint">
|
|
||||||
<p class="admonition-title">Hint</p>
|
|
||||||
<p>Configuration entries for each entry type have a low to high priority order. For example, a variable that is lower in the list will override a variable that is higher up.</p>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
<section id="collection-links">
|
|
||||||
<h3>Collection links<a class="headerlink" href="#collection-links" title="Link to this heading"></a></h3>
|
|
||||||
<ul class="ansible-links">
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues" rel="noopener external" target="_blank">Issue Tracker</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros" rel="noopener external" target="_blank">Repository (Sources)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://forum.ansible.com/tags/c/help/6/none/routeros" rel="noopener external" target="_blank">Ask for help (RouterOS)</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=bug_report.md" rel="noopener external" target="_blank">Submit a bug report</a></span></li>
|
|
||||||
<li><span><a aria-role="button" class="ansible-link reference external" href="https://github.com/ansible-collections/community.routeros/issues/new?assignees=&labels=&template=feature_request.md" rel="noopener external" target="_blank">Request a feature</a></span></li>
|
|
||||||
<li><span><a class="reference internal" href="index.html#communication-for-community-routeros"><span class="std std-ref">Communication</span></a></span></li>
|
|
||||||
</ul>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
||||||
<a href="quote_argument_value_filter.html" class="btn btn-neutral float-left" title="community.routeros.quote_argument_value filter – Quote an argument value" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<div role="contentinfo">
|
|
||||||
<p>© Copyright Community.Routeros Contributors.</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
jQuery(function () {
|
|
||||||
SphinxRtdTheme.Navigation.enable(true);
|
|
||||||
});
|
|
||||||
</script><!-- extra footer elements for Ansible beyond RTD Sphinx Theme -->
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|