community.general.memset_server_facts (0.1.4) — module

Retrieve server information.

Authors: Simon Weald (@glitchcrab)

Install collection

Install with ansible-galaxy collection install community.general:==0.1.4


Add to requirements.yml

  collections:
    - name: community.general
      version: 0.1.4

Description

Retrieve server information.

This module was called C(memset_server_facts) before Ansible 2.9. The usage did not change.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Get details for testyaa1
  memset_server_info:
    name: testyaa1
    api_key: 5eb86c9896ab03919abcf03857163741
  delegate_to: localhost

Inputs

    
name:
    description:
    - The server product name (i.e. C(testyaa1)).
    required: true

api_key:
    description:
    - The API key obtained from the Memset control panel.
    required: true

Outputs

memset_api:
  contains:
    backups:
      description: Whether this server has a backup service.
      returned: always
      sample: true
      type: bool
    control_panel:
      description: Whether the server has a control panel (i.e. cPanel).
      returned: always
      sample: cpanel
      type: str
    data_zone:
      description: The data zone the server is in.
      returned: always
      sample: Memset Public Cloud
      type: str
    expiry_date:
      description: Current expiry date of the server.
      returned: always
      sample: '2018-08-10'
      type: str
    firewall_rule_group:
      description: Details about the firewall group this server is in.
      returned: always
      sample:
        default_outbound_policy: RETURN
        name: testyaa-fw1
        nickname: testyaa cPanel rules
        notes: ''
        public: false
        rules:
          51d7db54d39c3544ef7c48baa0b9944f:
            action: ACCEPT
            comment: ''
            dest_ip6s: any
            dest_ips: any
            dest_ports: any
            direction: Inbound
            ip_version: any
            ordering: 2
            protocols: icmp
            rule_group_name: testyaa-fw1
            rule_id: 51d7db54d39c3544ef7c48baa0b9944f
            source_ip6s: any
            source_ips: any
            source_ports: any
      type: dict
    firewall_type:
      description: The type of firewall the server has (i.e. self-managed, managed).
      returned: always
      sample: managed
      type: str
    host_name:
      description: The server's hostname.
      returned: always
      sample: testyaa1.miniserver.com
      type: str
    ignore_monitoring_off:
      description: When true, Memset won't remind the customer that monitoring is
        disabled.
      returned: always
      sample: true
      type: bool
    ips:
      description: List of dictionaries of all IP addresses assigned to the server.
      returned: always
      sample:
      - address: 1.2.3.4
        bytes_in_today: 1000.0
        bytes_in_yesterday: 2000.0
        bytes_out_today: 1000.0
        bytes_out_yesterday: 2000.0
      type: list
    monitor:
      description: Whether the server has monitoring enabled.
      returned: always
      sample: true
      type: bool
    monitoring_level:
      description: The server's monitoring level (i.e. basic).
      returned: always
      sample: basic
      type: str
    name:
      description: Server name (same as the service name).
      returned: always
      sample: testyaa1
      type: str
    network_zones:
      description: The network zone(s) the server is in.
      returned: always
      sample:
      - reading
      type: list
    nickname:
      description: Customer-set nickname for the server.
      returned: always
      sample: database server
      type: str
    no_auto_reboot:
      description: Whether or not to reboot the server if monitoring detects it down.
      returned: always
      sample: true
      type: bool
    no_nrpe:
      description: Whether Memset should use NRPE to monitor this server.
      returned: always
      sample: true
      type: bool
    os:
      description: The server's Operating System.
      returned: always
      sample: debian_stretch_64
      type: str
    penetration_patrol:
      description: Intrusion detection support level for this server.
      returned: always
      sample: managed
      type: str
    penetration_patrol_alert_level:
      description: The alert level at which notifications are sent.
      returned: always
      sample: 10
      type: int
    primary_ip:
      description: Server's primary IP.
      returned: always
      sample: 1.2.3.4
      type: str
    renewal_price_amount:
      description: Renewal cost for the server.
      returned: always
      sample: '30.00'
      type: str
    renewal_price_currency:
      description: Currency for renewal payments.
      returned: always
      sample: GBP
      type: str
    renewal_price_vat:
      description: VAT rate for renewal payments
      returned: always
      sample: '20'
      type: str
    start_date:
      description: Server's start date.
      returned: always
      sample: '2013-04-10'
      type: str
    status:
      description: Current status of the server (i.e. live, onhold).
      returned: always
      sample: LIVE
      type: str
    support_level:
      description: Support level included with the server.
      returned: always
      sample: managed
      type: str
    type:
      description: What this server is (i.e. dedicated)
      returned: always
      sample: miniserver
      type: str
    vlans:
      description: Dictionary of tagged and untagged VLANs this server is in.
      returned: always
      sample:
        tagged: []
        untagged:
        - testyaa-vlan1
        - testyaa-vlan2
      type: dict
    vulnscan:
      description: Vulnerability scanning level.
      returned: always
      sample: basic
      type: str
  description: Info from the Memset API
  returned: always
  type: complex