DSC NoNodedata table - list servers in array.

Welcome Forums DSC (Desired State Configuration) DSC NoNodedata table - list servers in array.

This topic contains 1 reply, has 2 voices, and was last updated by

2 years, 4 months ago.

  • Author
  • #57403

    Points: 2
    Rank: Member

    Hi Using server2012R2 and PS 5.

    I have a $ConfigData table for my Configuration.
    In my NoNodeData section is it possible to set array values?
    like so:

    SharePoint = @(
    FrontEndServers = @(vm01,vm02)

    So that when i point to this table in my resourceblock, it will capture both vm01 and vm02?

    The resourceblock looks like this:

            SPDistributedCacheService EnableDistributedCache
                Name                 = "AppFabricCachingService"
                Ensure               = "Present"
                CacheSizeInMB        = 1024
                ServiceAccount       = $ServicePoolManagedCred.UserName
                PsDscRunAsCredential = $SPSetupCred
                CreateFirewallRules  = $true
                DependsOn            = "[AddUrlToLocalIntranet]CAURL"
                ServerProvisionOrder = $ConfigurationData.NonNodeData.SharePoint.FrontEndServers

    The resource ServerProvisionOrder checks the list from nonodedata to see if Distributed cache has been set up, if not then runs this on the local server. So I was just wondering if my

    SharePoint = @(
    FrontEndServers = @(vm01,vm02)

    would work.



  • #57404

    Points: -19
    Rank: Member


    The sharepoint dsc resource your using requires ServerProvisionOrder to be a string.
    I dont think it will accept an array but it would definitely accept:

    FrontEndServers = "vm01,vm02"

    Second thing, though i havent tested this, but i dont know if NonNodeData accepts more then one depth of object.
    What i mean is that:


    might not be applicable, but:


    definitly wili, if you also remove the FrontEndServers from within the SharePoint array that is inisde your NonNodeData.

    Personally im not sure putting that variable in NonNodeData is the best way, i would actually set it in the AllNodes section under the
    NodeName = "*" section to be the default, and if you want a specific value for a certain node,
    you just overwrite it in the node configuration itself.

The topic ‘DSC NoNodedata table - list servers in array.’ is closed to new replies.

denizli escort samsun escort muğla escort ataşehir escort kuşadası escort