fortinet.fortimanager.fmgr_devprof_system_centralmanagement module – Configure central management.

Note

This module is part of the fortinet.fortimanager collection (version 2.7.0).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install fortinet.fortimanager.

To use it in a playbook, specify: fortinet.fortimanager.fmgr_devprof_system_centralmanagement.

New in fortinet.fortimanager 1.0.0

Synopsis

  • This module is able to configure a FortiManager device.

  • Examples include all parameters and values which need to be adjusted to data sources before usage.

Parameters

Parameter

Comments

access_token

string

The token to access FortiManager without using username and password.

adom

string / required

The parameter (adom) in requested url.

bypass_validation

boolean

Only set to True when module schema diffs with FortiManager API structure, module continues to execute without validating parameters.

Choices:

  • false ← (default)

  • true

devprof

string / required

The parameter (devprof) in requested url.

devprof_system_centralmanagement

dictionary

The top level parameters set.

allow-monitor

string

Deprecated, please rename it to allow_monitor. Enable/disable allowing the central management server to remotely monitor t…

Choices:

  • "disable"

  • "enable"

allow-push-configuration

string

Deprecated, please rename it to allow_push_configuration. Enable/disable allowing the central management server to push co…

Choices:

  • "disable"

  • "enable"

allow-push-firmware

string

Deprecated, please rename it to allow_push_firmware. Enable/disable allowing the central management server to push firmwar…

Choices:

  • "disable"

  • "enable"

allow-remote-firmware-upgrade

string

Deprecated, please rename it to allow_remote_firmware_upgrade. Enable/disable remotely upgrading the firmware on this Fort…

Choices:

  • "disable"

  • "enable"

allow-remote-lte-firmware-upgrade

string

Deprecated, please rename it to allow_remote_lte_firmware_upgrade. Enable/disable remotely upgrading the lte firmware on t…

Choices:

  • "disable"

  • "enable"

allow-remote-modem-firmware-upgrade

string

Deprecated, please rename it to allow_remote_modem_firmware_upgrade. Enable/disable remotely upgrading the internal cellul…

Choices:

  • "disable"

  • "enable"

ca-cert

string

Deprecated, please rename it to ca_cert. CA certificate to be used by FGFM protocol.

enc-algorithm

string

Deprecated, please rename it to enc_algorithm. Encryption strength for communications between the FortiGate and central ma…

Choices:

  • "default"

  • "high"

  • "low"

fmg

any

(list) IP address or FQDN of the FortiManager.

fmg-source-ip

string

Deprecated, please rename it to fmg_source_ip. IPv4 source address that this FortiGate uses when communicating with FortiM…

fmg-source-ip6

string

Deprecated, please rename it to fmg_source_ip6. IPv6 source address that this FortiGate uses when communicating with Forti…

fmg-update-port

string

Deprecated, please rename it to fmg_update_port. Port used to communicate with FortiManager that is acting as a FortiGuard…

Choices:

  • "443"

  • "8890"

fortigate-cloud-sso-default-profile

any

(list) Deprecated, please rename it to fortigate_cloud_sso_default_profile. Override access profile.

include-default-servers

string

Deprecated, please rename it to include_default_servers. Enable/disable inclusion of public FortiGuard servers in the over…

Choices:

  • "disable"

  • "enable"

interface

any

(list) Specify outgoing interface to reach server.

interface-select-method

string

Deprecated, please rename it to interface_select_method. Specify how to select outgoing interface to reach server.

Choices:

  • "auto"

  • "sdwan"

  • "specify"

local-cert

string

Deprecated, please rename it to local_cert. Certificate to be used by FGFM protocol.

ltefw-upgrade-frequency

string

Deprecated, please rename it to ltefw_upgrade_frequency. Set LTE firmware auto pushdown frequency.

Choices:

  • "everyHour"

  • "every12hour"

  • "everyDay"

  • "everyWeek"

ltefw-upgrade-time

string

Deprecated, please rename it to ltefw_upgrade_time. Schedule next LTE firmware upgrade time

mode

string

Central management mode.

Choices:

  • "normal"

  • "backup"

modem-upgrade-frequency

string

Deprecated, please rename it to modem_upgrade_frequency. Set internal cellular modem firmware auto pushdown frequency.

Choices:

  • "everyHour"

  • "every12hour"

  • "everyDay"

  • "everyWeek"

modem-upgrade-time

string

Deprecated, please rename it to modem_upgrade_time. Schedule next internal cellular modem firmware upgrade time

schedule-config-restore

string

Deprecated, please rename it to schedule_config_restore. Enable/disable allowing the central management server to restore …

Choices:

  • "disable"

  • "enable"

schedule-script-restore

string

Deprecated, please rename it to schedule_script_restore. Enable/disable allowing the central management server to restore …

Choices:

  • "disable"

  • "enable"

serial-number

any

(list) Deprecated, please rename it to serial_number. Serial number.

server-list

list / elements=dictionary

Deprecated, please rename it to server_list. Server list.

addr-type

string

Deprecated, please rename it to addr_type. Indicate whether the FortiGate communicates with the override server us…

Choices:

  • "fqdn"

  • "ipv4"

  • "ipv6"

fqdn

string

FQDN address of override server.

id

integer

ID.

server-address

string

Deprecated, please rename it to server_address. IPv4 address of override server.

server-address6

string

Deprecated, please rename it to server_address6. IPv6 address of override server.

server-type

list / elements=string

Deprecated, please rename it to server_type. FortiGuard service type.

Choices:

  • "update"

  • "rating"

  • "iot-query"

  • "iot-collect"

  • "vpatch-query"

type

string

Central management type.

Choices:

  • "fortimanager"

  • "fortiguard"

  • "none"

use-elbc-vdom

string

Deprecated, please rename it to use_elbc_vdom. Enable/disable use of special ELBC config sync VDOM to connect to FortiManager.

Choices:

  • "disable"

  • "enable"

vdom

any

(list) Virtual domain

enable_log

boolean

Enable/Disable logging for task.

Choices:

  • false ← (default)

  • true

forticloud_access_token

string

Authenticate Ansible client with forticloud API access token.

proposed_method

string

The overridden method for the underlying Json RPC request.

Choices:

  • "update"

  • "set"

  • "add"

rc_failed

list / elements=integer

The rc codes list with which the conditions to fail will be overriden.

rc_succeeded

list / elements=integer

The rc codes list with which the conditions to succeed will be overriden.

workspace_locking_adom

string

The adom to lock for FortiManager running in workspace mode, the value can be global and others including root.

workspace_locking_timeout

integer

The maximum time in seconds to wait for other user to release the workspace lock.

Default: 300

Notes

Note

  • Starting in version 2.4.0, all input arguments are named using the underscore naming convention (snake_case). Please change the arguments such as “var-name” to “var_name”. Old argument names are still available yet you will receive deprecation warnings. You can ignore this warning by setting deprecation_warnings=False in ansible.cfg.

  • Running in workspace locking mode is supported in this FortiManager module, the top level parameters workspace_locking_adom and workspace_locking_timeout help do the work.

  • Normally, running one module can fail when a non-zero rc is returned. you can also override the conditions to fail or succeed with parameters rc_failed and rc_succeeded

Examples

- name: Example playbook (generated based on argument schema)
  hosts: fortimanagers
  connection: httpapi
  vars:
    ansible_httpapi_use_ssl: true
    ansible_httpapi_validate_certs: false
    ansible_httpapi_port: 443
  tasks:
    - name: Configure central management.
      fortinet.fortimanager.fmgr_devprof_system_centralmanagement:
        # bypass_validation: false
        workspace_locking_adom: <value in [global, custom adom including root]>
        workspace_locking_timeout: 300
        # rc_succeeded: [0, -2, -3, ...]
        # rc_failed: [-2, -3, ...]
        adom: <your own value>
        devprof: <your own value>
        devprof_system_centralmanagement:
          include_default_servers: <value in [disable, enable]>
          server_list:
            -
              addr_type: <value in [fqdn, ipv4, ipv6]>
              fqdn: <string>
              id: <integer>
              server_address: <string>
              server_address6: <string>
              server_type:
                - update
                - rating
                - iot-query
                - iot-collect
                - vpatch-query
          ltefw_upgrade_time: <string>
          vdom: <list or string>
          allow_remote_firmware_upgrade: <value in [disable, enable]>
          local_cert: <string>
          allow_push_firmware: <value in [disable, enable]>
          ltefw_upgrade_frequency: <value in [everyHour, every12hour, everyDay, ...]>
          mode: <value in [normal, backup]>
          serial_number: <list or string>
          fmg_source_ip6: <string>
          allow_monitor: <value in [disable, enable]>
          allow_push_configuration: <value in [disable, enable]>
          ca_cert: <string>
          fmg_update_port: <value in [443, 8890]>
          use_elbc_vdom: <value in [disable, enable]>
          allow_remote_lte_firmware_upgrade: <value in [disable, enable]>
          interface: <list or string>
          schedule_script_restore: <value in [disable, enable]>
          schedule_config_restore: <value in [disable, enable]>
          interface_select_method: <value in [auto, sdwan, specify]>
          type: <value in [fortimanager, fortiguard, none]>
          fmg_source_ip: <string>
          fortigate_cloud_sso_default_profile: <list or string>
          fmg: <list or string>
          enc_algorithm: <value in [default, high, low]>
          allow_remote_modem_firmware_upgrade: <value in [disable, enable]>
          modem_upgrade_frequency: <value in [everyHour, every12hour, everyDay, ...]>
          modem_upgrade_time: <string>

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

meta

dictionary

The result of the request.

Returned: always

request_url

string

The full url requested.

Returned: always

Sample: "/sys/login/user"

response_code

integer

The status of api request.

Returned: always

Sample: 0

response_data

list / elements=string

The api response.

Returned: always

response_message

string

The descriptive message of the api response.

Returned: always

Sample: "OK."

system_information

dictionary

The information of the target system.

Returned: always

rc

integer

The status the request.

Returned: always

Sample: 0

version_check_warning

list / elements=string

Warning if the parameters used in the playbook are not supported by the current FortiManager version.

Returned: complex

Authors

  • Xinwei Du (@dux-fortinet)

  • Xing Li (@lix-fortinet)

  • Jie Xue (@JieX19)

  • Link Zheng (@chillancezen)

  • Frank Shen (@fshen01)

  • Hongbin Lu (@fgtdev-hblu)