Skip to content

Could Not Find Mandatory Parameter TimeZone #9

Description

@richardjgreen

I've created a really simple DSC Configuration using this module to configure the time zone of a machine.
`Configuration SetRegionalSettings {

Param
(
    [Parameter(Mandatory = $true)]
    [ValidateNotNullorEmpty()]
    [String]$NewTimeZone
)

Import-DscResource -ModuleName rsInternationalSettings

rsTime SetTimeZone {
    TimeZone = $NewTimeZone
}

}

SetRegionalSettings -NewTimeZone "GMT Standard Time"`

When I run Start-DscConfiguration to enact the MOF file, I get the error Could Not Find Mandatory Parameter TimeZone. When I look inside the MOF file, TimeZone is set to NULL. As you can see from my example, I am clearly defining a value for TimeZone so I think there is a problem with the rsTime module not passing this value through.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions