On this page
fortios_report_chart – Report chart widget configuration in Fortinet’s FortiOS and FortiGate
New in version 2.8.
Synopsis
- This module is able to configure a FortiGate or FortiOS (FOS) device by allowing the user to set and modify report feature and chart category. Examples include all parameters and values need to be adjusted to datasources before usage. Tested with FOS v6.0.5
Requirements
The below requirements are needed on the host that executes this module.
- fortiosapi>=0.9.8
Parameters
Parameter | Choices/Defaults | Comments | |||
---|---|---|---|---|---|
host
string
|
FortiOS or FortiGate IP address.
|
||||
https
boolean
|
|
Indicates if the requests towards FortiGate must use HTTPS protocol.
|
|||
password
string
|
Default:
""
|
FortiOS or FortiGate password.
|
|||
report_chart
dictionary
|
Default:
null
|
Report chart widget configuration.
|
|||
background
string
|
Chart background.
|
||||
category
string
|
|
Category.
|
|||
category_series
dictionary
|
Category series of pie chart.
|
||||
databind
string
|
Category series value expression.
|
||||
font_size
integer
|
Font size of category-series title.
|
||||
color_palette
string
|
Color palette (system will pick color automatically by default).
|
||||
column
list
|
Table column definition.
|
||||
detail_unit
string
|
Detail unit of column.
|
||||
detail_value
string
|
Detail value of column.
|
||||
footer_unit
string
|
Footer unit of column.
|
||||
footer_value
string
|
Footer value of column.
|
||||
header_value
string
|
Display name of table header.
|
||||
id
integer / required
|
ID.
|
||||
mapping
list
|
Show detail in certain display value for certain condition.
|
||||
displayname
string
|
Display name.
|
||||
id
integer / required
|
id
|
||||
op
string
|
|
Comparison operator.
|
|||
value1
string
|
Value 1.
|
||||
value2
string
|
Value 2.
|
||||
value_type
string
|
|
Value type.
|
|||
comments
string
|
Comment.
|
||||
dataset
string
|
Bind dataset to chart.
|
||||
dimension
string
|
|
Dimension.
|
|||
drill_down_charts
list
|
Drill down charts.
|
||||
chart_name
string
|
Drill down chart name.
|
||||
id
integer / required
|
Drill down chart ID.
|
||||
status
string
|
|
Enable/disable this drill down chart.
|
|||
favorite
string
|
|
Favorite.
|
|||
graph_type
string
|
|
Graph type.
|
|||
legend
string
|
|
Enable/Disable Legend area.
|
|||
legend_font_size
integer
|
Font size of legend area.
|
||||
name
string / required
|
Chart Widget Name
|
||||
period
string
|
|
Time period.
|
|||
policy
integer
|
Used by monitor policy.
|
||||
state
string
|
|
Deprecated
Starting with Ansible 2.9 we recommend using the top-level 'state' parameter.
Indicates whether to create or remove the object.
|
|||
style
string
|
|
Style.
|
|||
title
string
|
Chart title.
|
||||
title_font_size
integer
|
Font size of chart title.
|
||||
type
string
|
|
Chart type.
|
|||
value_series
dictionary
|
Value series of pie chart.
|
||||
databind
string
|
Value series value expression.
|
||||
x_series
dictionary
|
X-series of chart.
|
||||
caption
string
|
X-series caption.
|
||||
caption_font_size
integer
|
X-series caption font size.
|
||||
databind
string
|
X-series value expression.
|
||||
font_size
integer
|
X-series label font size.
|
||||
is_category
string
|
|
X-series represent category or not.
|
|||
label_angle
string
|
|
X-series label angle.
|
|||
scale_direction
string
|
|
Scale increase or decrease.
|
|||
scale_format
string
|
|
Date/time format.
|
|||
scale_step
integer
|
Scale step.
|
||||
scale_unit
string
|
|
Scale unit.
|
|||
unit
string
|
X-series unit.
|
||||
y_series
dictionary
|
Y-series of chart.
|
||||
caption
string
|
Y-series caption.
|
||||
caption_font_size
integer
|
Y-series caption font size.
|
||||
databind
string
|
Y-series value expression.
|
||||
extra_databind
string
|
Extra Y-series value.
|
||||
extra_y
string
|
|
Allow another Y-series value
|
|||
extra_y_legend
string
|
Extra Y-series legend type/name.
|
||||
font_size
integer
|
Y-series label font size.
|
||||
group
string
|
Y-series group option.
|
||||
label_angle
string
|
|
Y-series label angle.
|
|||
unit
string
|
Y-series unit.
|
||||
y_legend
string
|
First Y-series legend type/name.
|
||||
ssl_verify
boolean
added in 2.9
|
|
Ensures FortiGate certificate must be verified by a proper CA.
|
|||
state
string
added in 2.9
|
|
Indicates whether to create or remove the object. This attribute was present already in previous version in a deeper level. It has been moved out to this outer level.
|
|||
username
string
|
FortiOS or FortiGate username.
|
||||
vdom
string
|
Default:
"root"
|
Virtual domain, among those defined previously. A vdom is a virtual instance of the FortiGate that can be configured and used as a different unit.
|
Notes
Note
- Requires fortiosapi library developed by Fortinet
- Run as a local_action in your playbook
Examples
- hosts: localhost
vars:
host: "192.168.122.40"
username: "admin"
password: ""
vdom: "root"
ssl_verify: "False"
tasks:
- name: Report chart widget configuration.
fortios_report_chart:
host: "{{ host }}"
username: "{{ username }}"
password: "{{ password }}"
vdom: "{{ vdom }}"
https: "False"
state: "present"
report_chart:
background: "<your_own_value>"
category: "misc"
category_series:
databind: "<your_own_value>"
font_size: "7"
color_palette: "<your_own_value>"
column:
-
detail_unit: "<your_own_value>"
detail_value: "<your_own_value>"
footer_unit: "<your_own_value>"
footer_value: "<your_own_value>"
header_value: "<your_own_value>"
id: "15"
mapping:
-
displayname: "<your_own_value>"
id: "18"
op: "none"
value_type: "integer"
value1: "<your_own_value>"
value2: "<your_own_value>"
comments: "<your_own_value>"
dataset: "<your_own_value>"
dimension: "2D"
drill_down_charts:
-
chart_name: "<your_own_value>"
id: "28"
status: "enable"
favorite: "no"
graph_type: "none"
legend: "enable"
legend_font_size: "33"
name: "default_name_34"
period: "last24h"
policy: "36"
style: "auto"
title: "<your_own_value>"
title_font_size: "39"
type: "graph"
value_series:
databind: "<your_own_value>"
x_series:
caption: "<your_own_value>"
caption_font_size: "45"
databind: "<your_own_value>"
font_size: "47"
is_category: "yes"
label_angle: "45-degree"
scale_direction: "decrease"
scale_format: "YYYY-MM-DD-HH-MM"
scale_step: "52"
scale_unit: "minute"
unit: "<your_own_value>"
y_series:
caption: "<your_own_value>"
caption_font_size: "57"
databind: "<your_own_value>"
extra_databind: "<your_own_value>"
extra_y: "enable"
extra_y_legend: "<your_own_value>"
font_size: "62"
group: "<your_own_value>"
label_angle: "45-degree"
unit: "<your_own_value>"
y_legend: "<your_own_value>"
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
build
string
|
always |
Build number of the fortigate image
Sample:
1547
|
http_method
string
|
always |
Last method used to provision the content into FortiGate
Sample:
PUT
|
http_status
string
|
always |
Last result given by FortiGate on last operation applied
Sample:
200
|
mkey
string
|
success |
Master key (id) used in the last call to FortiGate
Sample:
id
|
name
string
|
always |
Name of the table used to fulfill the request
Sample:
urlfilter
|
path
string
|
always |
Path of the table used to fulfill the request
Sample:
webfilter
|
revision
string
|
always |
Internal revision number
Sample:
17.0.2.10658
|
serial
string
|
always |
Serial number of the unit
Sample:
FGVMEVYYQT3AB5352
|
status
string
|
always |
Indication of the operation's result
Sample:
success
|
vdom
string
|
always |
Virtual domain used
Sample:
root
|
version
string
|
always |
Version of the FortiGate
Sample:
v5.6.3
|
Status
- This module is not guaranteed to have a backwards compatible interface. [preview]
- This module is maintained by the Ansible Community. [community]
Authors
- Miguel Angel Munoz (@mamunozgonzalez)
- Nicolas Thomas (@thomnico)
Hint
If you notice any issues in this documentation, you can edit this document to improve it.
© 2012–2018 Michael DeHaan
© 2018–2019 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.9/modules/fortios_report_chart_module.html