# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from . import _utilities

__all__ = [
    'GetNodeResult',
    'AwaitableGetNodeResult',
    'get_node',
    'get_node_output',
]

@pulumi.output_type
class GetNodeResult:
    """
    A collection of values returned by getNode.
    """
    def __init__(__self__, cpu_count=None, cpu_model=None, cpu_sockets=None, id=None, memory_available=None, memory_total=None, memory_used=None, node_name=None, uptime=None):
        if cpu_count and not isinstance(cpu_count, int):
            raise TypeError("Expected argument 'cpu_count' to be a int")
        pulumi.set(__self__, "cpu_count", cpu_count)
        if cpu_model and not isinstance(cpu_model, str):
            raise TypeError("Expected argument 'cpu_model' to be a str")
        pulumi.set(__self__, "cpu_model", cpu_model)
        if cpu_sockets and not isinstance(cpu_sockets, int):
            raise TypeError("Expected argument 'cpu_sockets' to be a int")
        pulumi.set(__self__, "cpu_sockets", cpu_sockets)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)
        if memory_available and not isinstance(memory_available, int):
            raise TypeError("Expected argument 'memory_available' to be a int")
        pulumi.set(__self__, "memory_available", memory_available)
        if memory_total and not isinstance(memory_total, int):
            raise TypeError("Expected argument 'memory_total' to be a int")
        pulumi.set(__self__, "memory_total", memory_total)
        if memory_used and not isinstance(memory_used, int):
            raise TypeError("Expected argument 'memory_used' to be a int")
        pulumi.set(__self__, "memory_used", memory_used)
        if node_name and not isinstance(node_name, str):
            raise TypeError("Expected argument 'node_name' to be a str")
        pulumi.set(__self__, "node_name", node_name)
        if uptime and not isinstance(uptime, int):
            raise TypeError("Expected argument 'uptime' to be a int")
        pulumi.set(__self__, "uptime", uptime)

    @property
    @pulumi.getter(name="cpuCount")
    def cpu_count(self) -> int:
        """
        The CPU count on the node.
        """
        return pulumi.get(self, "cpu_count")

    @property
    @pulumi.getter(name="cpuModel")
    def cpu_model(self) -> str:
        """
        The CPU model on the node.
        """
        return pulumi.get(self, "cpu_model")

    @property
    @pulumi.getter(name="cpuSockets")
    def cpu_sockets(self) -> int:
        """
        The CPU utilization on the node.
        """
        return pulumi.get(self, "cpu_sockets")

    @property
    @pulumi.getter
    def id(self) -> str:
        """
        The provider-assigned unique ID for this managed resource.
        """
        return pulumi.get(self, "id")

    @property
    @pulumi.getter(name="memoryAvailable")
    def memory_available(self) -> int:
        """
        The memory available on the node.
        """
        return pulumi.get(self, "memory_available")

    @property
    @pulumi.getter(name="memoryTotal")
    def memory_total(self) -> int:
        """
        The total memory on the node.
        """
        return pulumi.get(self, "memory_total")

    @property
    @pulumi.getter(name="memoryUsed")
    def memory_used(self) -> int:
        """
        The memory used on the node.
        """
        return pulumi.get(self, "memory_used")

    @property
    @pulumi.getter(name="nodeName")
    def node_name(self) -> str:
        return pulumi.get(self, "node_name")

    @property
    @pulumi.getter
    def uptime(self) -> int:
        """
        The uptime in seconds on the node.
        """
        return pulumi.get(self, "uptime")


class AwaitableGetNodeResult(GetNodeResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetNodeResult(
            cpu_count=self.cpu_count,
            cpu_model=self.cpu_model,
            cpu_sockets=self.cpu_sockets,
            id=self.id,
            memory_available=self.memory_available,
            memory_total=self.memory_total,
            memory_used=self.memory_used,
            node_name=self.node_name,
            uptime=self.uptime)


def get_node(node_name: Optional[str] = None,
             opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetNodeResult:
    """
    Retrieves information about node.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_proxmoxve as proxmoxve

    node = proxmoxve.get_node()
    ```


    :param str node_name: The node name.
    """
    __args__ = dict()
    __args__['nodeName'] = node_name
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('proxmoxve:index/getNode:getNode', __args__, opts=opts, typ=GetNodeResult).value

    return AwaitableGetNodeResult(
        cpu_count=pulumi.get(__ret__, 'cpu_count'),
        cpu_model=pulumi.get(__ret__, 'cpu_model'),
        cpu_sockets=pulumi.get(__ret__, 'cpu_sockets'),
        id=pulumi.get(__ret__, 'id'),
        memory_available=pulumi.get(__ret__, 'memory_available'),
        memory_total=pulumi.get(__ret__, 'memory_total'),
        memory_used=pulumi.get(__ret__, 'memory_used'),
        node_name=pulumi.get(__ret__, 'node_name'),
        uptime=pulumi.get(__ret__, 'uptime'))


@_utilities.lift_output_func(get_node)
def get_node_output(node_name: Optional[pulumi.Input[str]] = None,
                    opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetNodeResult]:
    """
    Retrieves information about node.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_proxmoxve as proxmoxve

    node = proxmoxve.get_node()
    ```


    :param str node_name: The node name.
    """
    ...
