1. Packages
  2. Libvirt Provider
  3. API Docs
  4. getNodeInfo
libvirt v0.5.3 published on Thursday, Oct 24, 2024 by Pulumi

libvirt.getNodeInfo

Explore with Pulumi AI

libvirt logo
libvirt v0.5.3 published on Thursday, Oct 24, 2024 by Pulumi

    Retrieve information about the current node

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as libvirt from "@pulumi/libvirt";
    
    const node = libvirt.getNodeInfo({});
    
    import pulumi
    import pulumi_libvirt as libvirt
    
    node = libvirt.get_node_info()
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-libvirt/sdk/go/libvirt"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := libvirt.GetNodeInfo(ctx, map[string]interface{}{}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Libvirt = Pulumi.Libvirt;
    
    return await Deployment.RunAsync(() => 
    {
        var node = Libvirt.GetNodeInfo.Invoke();
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.libvirt.LibvirtFunctions;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var node = LibvirtFunctions.getNodeInfo();
    
        }
    }
    
    variables:
      node:
        fn::invoke:
          Function: libvirt:getNodeInfo
          Arguments: {}
    

    Using getNodeInfo

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getNodeInfo(opts?: InvokeOptions): Promise<GetNodeInfoResult>
    function getNodeInfoOutput(opts?: InvokeOptions): Output<GetNodeInfoResult>
    def get_node_info(opts: Optional[InvokeOptions] = None) -> GetNodeInfoResult
    def get_node_info_output(opts: Optional[InvokeOptions] = None) -> Output[GetNodeInfoResult]
    func GetNodeInfo(ctx *Context, opts ...InvokeOption) (*GetNodeInfoResult, error)
    func GetNodeInfoOutput(ctx *Context, opts ...InvokeOption) GetNodeInfoResultOutput

    > Note: This function is named GetNodeInfo in the Go SDK.

    public static class GetNodeInfo 
    {
        public static Task<GetNodeInfoResult> InvokeAsync(InvokeOptions? opts = null)
        public static Output<GetNodeInfoResult> Invoke(InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetNodeInfoResult> getNodeInfo(InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: libvirt:index/getNodeInfo:getNodeInfo
      arguments:
        # arguments dictionary

    getNodeInfo Result

    The following output properties are available:

    CpuCoresPerSocket int
    Number of CPU cores per each socket
    CpuCoresTotal int
    Number of CPU cores in total
    CpuModel string
    CPU Architecture, usually x86_64
    CpuSockets int
    How many CPU sockets are present
    CpuThreadsPerCore int
    How many CPU Threads are available per each CPU core
    Id string
    The provider-assigned unique ID for this managed resource.
    MemoryTotalKb int
    The amount of memory installed, in KiB
    NumaNodes int
    How many NUMA nodes/cells are available.
    CpuCoresPerSocket int
    Number of CPU cores per each socket
    CpuCoresTotal int
    Number of CPU cores in total
    CpuModel string
    CPU Architecture, usually x86_64
    CpuSockets int
    How many CPU sockets are present
    CpuThreadsPerCore int
    How many CPU Threads are available per each CPU core
    Id string
    The provider-assigned unique ID for this managed resource.
    MemoryTotalKb int
    The amount of memory installed, in KiB
    NumaNodes int
    How many NUMA nodes/cells are available.
    cpuCoresPerSocket Integer
    Number of CPU cores per each socket
    cpuCoresTotal Integer
    Number of CPU cores in total
    cpuModel String
    CPU Architecture, usually x86_64
    cpuSockets Integer
    How many CPU sockets are present
    cpuThreadsPerCore Integer
    How many CPU Threads are available per each CPU core
    id String
    The provider-assigned unique ID for this managed resource.
    memoryTotalKb Integer
    The amount of memory installed, in KiB
    numaNodes Integer
    How many NUMA nodes/cells are available.
    cpuCoresPerSocket number
    Number of CPU cores per each socket
    cpuCoresTotal number
    Number of CPU cores in total
    cpuModel string
    CPU Architecture, usually x86_64
    cpuSockets number
    How many CPU sockets are present
    cpuThreadsPerCore number
    How many CPU Threads are available per each CPU core
    id string
    The provider-assigned unique ID for this managed resource.
    memoryTotalKb number
    The amount of memory installed, in KiB
    numaNodes number
    How many NUMA nodes/cells are available.
    cpu_cores_per_socket int
    Number of CPU cores per each socket
    cpu_cores_total int
    Number of CPU cores in total
    cpu_model str
    CPU Architecture, usually x86_64
    cpu_sockets int
    How many CPU sockets are present
    cpu_threads_per_core int
    How many CPU Threads are available per each CPU core
    id str
    The provider-assigned unique ID for this managed resource.
    memory_total_kb int
    The amount of memory installed, in KiB
    numa_nodes int
    How many NUMA nodes/cells are available.
    cpuCoresPerSocket Number
    Number of CPU cores per each socket
    cpuCoresTotal Number
    Number of CPU cores in total
    cpuModel String
    CPU Architecture, usually x86_64
    cpuSockets Number
    How many CPU sockets are present
    cpuThreadsPerCore Number
    How many CPU Threads are available per each CPU core
    id String
    The provider-assigned unique ID for this managed resource.
    memoryTotalKb Number
    The amount of memory installed, in KiB
    numaNodes Number
    How many NUMA nodes/cells are available.

    Package Details

    Repository
    libvirt pulumi/pulumi-libvirt
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the libvirt Terraform Provider.
    libvirt logo
    libvirt v0.5.3 published on Thursday, Oct 24, 2024 by Pulumi