Skip to content

Commit

Permalink
Merge pull request #156 from PowerShell/dev
Browse files Browse the repository at this point in the history
Release of version 5.0.0.0 of ComputerManagementDsc
  • Loading branch information
kwirkykat authored May 2, 2018
2 parents 88277cb + 134208a commit 8f9a482
Show file tree
Hide file tree
Showing 63 changed files with 298 additions and 293 deletions.
2 changes: 1 addition & 1 deletion .vscode/RunAllTests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ if ( (-not (Test-Path -Path (Join-Path -Path $repoRoot -ChildPath 'DSCResource.T

Import-Module (Join-Path $PSScriptRoot "..\Tests\TestHarness.psm1" -Resolve)
$dscTestsPath = Join-Path -Path $PSScriptRoot `
-ChildPath "..\Modules\xComputerManagement\DscResource.Tests\Meta.Tests.ps1"
-ChildPath "..\Modules\ComputerManagementDsc\DscResource.Tests\Meta.Tests.ps1"
Invoke-TestHarness -DscTestsPath $dscTestsPath
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

## Unreleased

## 5.0.0.0

- BREAKING CHANGE:
- Renamed ComputerManagement to ComputerManagementDsc - fixes [Issue #119](https://github.com/PowerShell/ComputerManagementDsc/issues/119).
- Changed all MSFT\_xResourceName to MSFT\_ResourceName.
- Updated DSCResources, Examples, Modules and Tests with new naming.
- Updated Year to 2018 in License and Manifest.
- Updated README.md from xComputerManagement to ComputerManagementDsc.
- OfflineDomainJoin:
- Cleaned up spacing in strings file to make consistent with other
resources.
- VirtualMemory:
- Converted strings to single quotes in integration test.

## 4.1.0.0

- xScheduledTask:
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2017 Microsoft Corporation.
Copyright (c) 2018 Microsoft Corporation.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@{
# Version number of this module.
moduleVersion = '4.1.0.0'
moduleVersion = '5.0.0.0'

# ID used to uniquely identify this module
GUID = 'B5004952-489E-43EA-999C-F16A25355B89'
Expand All @@ -12,10 +12,10 @@ Author = 'Microsoft Corporation'
CompanyName = 'Microsoft Corporation'

# Copyright statement for this module
Copyright = '(c) 2017 Microsoft Corporation. All rights reserved.'
Copyright = '(c) 2018 Microsoft Corporation. All rights reserved.'

# Description of the functionality provided by this module
Description = 'The xComputerManagement module is originally part of the Windows PowerShell Desired State Configuration (DSC) Resource Kit. This version has been modified for use in Azure. This module contains the xComputer and xDisk resources. These DSC Resources allow you to perform computer management tasks, like joining a domain or initializing disks.
Description = 'The ComputerManagementDsc module is originally part of the Windows PowerShell Desired State Configuration (DSC) Resource Kit. This version has been modified for use in Azure. This module contains the xComputer and xDisk resources. These DSC Resources allow you to perform computer management tasks, like joining a domain or initializing disks.
All of the resources in the DSC Resource Kit are provided AS IS, and are not supported through any Microsoft standard support program or service.'

Expand All @@ -40,24 +40,26 @@ PrivateData = @{
Tags = @('DesiredStateConfiguration', 'DSC', 'DSCResourceKit', 'DSCResource')

# A URL to the license for this module.
LicenseUri = 'https://github.com/PowerShell/xComputerManagement/blob/master/LICENSE'
LicenseUri = 'https://github.com/PowerShell/ComputerManagementDsc/blob/master/LICENSE'

# A URL to the main website for this project.
ProjectUri = 'https://github.com/PowerShell/xComputerManagement'
ProjectUri = 'https://github.com/PowerShell/ComputerManagementDsc'

# A URL to an icon representing this module.
# IconUri = ''

# ReleaseNotes of this module
ReleaseNotes = '- xScheduledTask:
- Update existing Scheduled Task using SetScheduleTask
instead of UnRegister/Register - See [Issue 134](https://github.com/PowerShell/xComputerManagement/issues/134).
- Fix master branch AppVeyor badge link URL in README.MD - See [Issue 140](https://github.com/PowerShell/xComputerManagement/issues/140).
- Fix deletion of scheduled task with unknown or empty task trigger.
Get-TargetResource returns an empty ScheduleType string if the task
trigger is empty or unknown - See [Issue
137](https://github.com/PowerShell/xComputerManagement/issues/137).
- Added dependency information for xScheduledTask to README.MD.
ReleaseNotes = '- BREAKING CHANGE:
- Renamed ComputerManagement to ComputerManagementDsc - fixes [Issue 119](https://github.com/PowerShell/ComputerManagementDsc/issues/119).
- Changed all MSFT\_xResourceName to MSFT\_ResourceName.
- Updated DSCResources, Examples, Modules and Tests with new naming.
- Updated Year to 2018 in License and Manifest.
- Updated README.md from xComputerManagement to ComputerManagementDsc.
- OfflineDomainJoin:
- Cleaned up spacing in strings file to make consistent with other
resources.
- VirtualMemory:
- Converted strings to single quotes in integration test.
'

Expand All @@ -66,13 +68,3 @@ PrivateData = @{
} # End of PrivateData hashtable
}











Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Import-Module -Name (Join-Path -Path $modulePath `

# Import Localization Strings
$script:localizedData = Get-LocalizedData `
-ResourceName 'MSFT_xComputer' `
-ResourceName 'MSFT_Computer' `
-ResourcePath (Split-Path -Parent $Script:MyInvocation.MyCommand.Path)

<#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[ClassVersion("1.0.1.0"), FriendlyName("xComputer")]
class MSFT_xComputer : OMI_BaseResource
[ClassVersion("1.0.1.0"), FriendlyName("Computer")]
class MSFT_Computer : OMI_BaseResource
{
[Key, Description("The desired computer name.")] String Name;
[Write, Description("The name of the domain to join.")] String DomainName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Import-Module -Name (Join-Path -Path $modulePath `

# Import Localization Strings
$script:localizedData = Get-LocalizedData `
-ResourceName 'MSFT_xOfflineDomainJoin' `
-ResourceName 'MSFT_OfflineDomainJoin' `
-ResourcePath (Split-Path -Parent $Script:MyInvocation.MyCommand.Path)

<#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[ClassVersion("1.0.0.0"), FriendlyName("xOfflineDomainJoin")]
class MSFT_xOfflineDomainJoin : OMI_BaseResource
[ClassVersion("1.0.0.0"), FriendlyName("OfflineDomainJoin")]
class MSFT_OfflineDomainJoin : OMI_BaseResource
{
[Key, Description("Specifies the resource is a single instance, the value must be 'Yes'."), ValueMap{"Yes"}, Values{"Yes"}] String IsSingleInstance;
[Required, Description("The full path to the Offline Domain Join Request file to use.")] String RequestFile;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
ConvertFrom-StringData @'
GettingOfflineDomainJoinMessage = Getting the Offline Domain Join State.
ApplyingOfflineDomainJoinMessage = Applying the Offline Domain Join State.
AttemptingDomainJoinMessage = Attempting domain join using ODJ Request file '{0}'.
DomainJoinedMessage = Domain joined using ODJ Request file '{0}'. Reboot will be required.
CheckingOfflineDomainJoinMessage = Checking the Offline Domain Join State.
DomainAlreadyJoinedMessage = The computer is already joined to a domain '{0}'. Change not required.
DomainNotJoinedMessage = The computer is not joined to a domain. Change required.
RequestFileNotFoundError = The ODJ Request file '{0}' does not exist.
DjoinError = Error {0} occured requesting the Offline Domain Join.
'@
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Import-Module -Name (Join-Path -Path $modulePath `

# Import Localization Strings
$script:localizedData = Get-LocalizedData `
-ResourceName 'MSFT_xPowerPlan' `
-ResourceName 'MSFT_PowerPlan' `
-ResourcePath (Split-Path -Parent $Script:MyInvocation.MyCommand.Path)

<#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[ClassVersion("1.0.0.0"), FriendlyName("xPowerPlan")]
class MSFT_xPowerPlan : OMI_BaseResource
[ClassVersion("1.0.0.0"), FriendlyName("PowerPlan")]
class MSFT_PowerPlan : OMI_BaseResource
{
[Key, Description("Specifies the resource is a single instance, the value must be 'Yes'."), ValueMap{"Yes"}, Values{"Yes"}] String IsSingleInstance;
[Required, Description("The name of the power plan to activate.")] String Name;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[Description("This resource is used to activate a power plan.") : Amended,AMENDMENT, LOCALE("MS_409")]
class MSFT_xPowerPlan : OMI_BaseResource
class MSFT_PowerPlan : OMI_BaseResource
{
[Key, Description("Specifies the resource is a single instance, the value must be 'Yes'.") : Amended] String IsSingleInstance;
[Description("The name of the power plan to activate.") : Amended] String Name;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Add-Type -TypeDefinition @'
namespace xScheduledTask
namespace ScheduledTask
{
public enum DaysOfWeek
{
Expand Down Expand Up @@ -28,7 +28,7 @@ Import-Module -Name (Join-Path -Path $modulePath `

# Import Localization Strings
$script:localizedData = Get-LocalizedData `
-ResourceName 'MSFT_xScheduledTask' `
-ResourceName 'MSFT_ScheduledTask' `
-ResourcePath (Split-Path -Parent $Script:MyInvocation.MyCommand.Path)

<#
Expand Down Expand Up @@ -453,7 +453,7 @@ function Get-TargetResource

if ($day -ne 0)
{
$daysOfWeek += [xScheduledTask.DaysOfWeek] $day
$daysOfWeek += [ScheduledTask.DaysOfWeek] $day
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[ClassVersion("1.0.0.0"), FriendlyName("xScheduledTask")]
class MSFT_xScheduledTask : OMI_BaseResource
[ClassVersion("1.0.0.0"), FriendlyName("ScheduledTask")]
class MSFT_ScheduledTask : OMI_BaseResource
{
[Key, Description("The name of the task")] string TaskName;
[Write, Description("The path to the task - defaults to the root directory")] string TaskPath;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Import-Module -Name (Join-Path -Path $modulePath `

# Import Localization Strings
$script:localizedData = Get-LocalizedData `
-ResourceName 'MSFT_xVirtualMemory' `
-ResourceName 'MSFT_VirtualMemory' `
-ResourcePath (Split-Path -Parent $Script:MyInvocation.MyCommand.Path)

<#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

[ClassVersion("1.0.0.0"), FriendlyName("xVirtualMemory")]
class MSFT_xVirtualMemory : OMI_BaseResource
[ClassVersion("1.0.0.0"), FriendlyName("VirtualMemory")]
class MSFT_VirtualMemory : OMI_BaseResource
{
[Key, Description("The drive letter for which paging settings should be set. Can be letter only, letter and colon or letter with colon and trailing slash.")] String Drive;
[Key, Description("The type of the paging setting to use. If set to AutoManagePagingFile, the drive letter will be ignored. If set to SystemManagedSize, the values for InitialSize and MaximumSize will be ignored"), ValueMap{"AutoManagePagingFile","CustomSize","SystemManagedSize","NoPagingFile"}, Values{"AutoManagePagingFile","CustomSize","SystemManagedSize","NoPagingFile"}] String Type;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer NewNameAndWorkgroup
Computer NewNameAndWorkgroup
{
Name = 'Server01'
WorkGroupName = 'ContosoWorkgroup'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ Configuration Example
$Credential
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer JoinDomain
Computer JoinDomain
{
Name = 'Server01'
DomainName = 'Contoso'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ Configuration Example
$Credential
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer NewName
Computer NewName
{
Name = 'Server01'
Credential = $Credential # Domain credential
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer NewName
Computer NewName
{
Name = 'Server01'
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ Configuration Example
$Credential
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer JoinWorkgroup
Computer JoinWorkgroup
{
Name = 'Server01'
WorkGroupName = 'ContosoWorkgroup'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -Module xComputerManagement
Import-DscResource -Module ComputerManagementDsc

Node $NodeName
{
xComputer NewDescription
Computer NewDescription
{
Name = 'localhost'
Description = 'This is my computer.'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xOfflineDomainJoin ODJ
OfflineDomainJoin ODJ
{
IsSingleInstance = 'Yes'
RequestFile = 'C:\ODJ\ODJBlob.txt'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xPowerPlan SetPlanHighPerformance
PowerPlan SetPlanHighPerformance
{
IsSingleInstance = 'Yes'
Name = 'High performance'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xScheduledTask xScheduledTaskOnceAdd
ScheduledTask ScheduledTaskOnceAdd
{
TaskName = 'Test task Once'
TaskPath = '\MyTasks'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ Configuration Example
$Credential
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xScheduledTask MaintenanceScriptExample
ScheduledTask MaintenanceScriptExample
{
TaskName = 'Test task Interactive'
TaskPath = '\MyTasks'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xScheduledTask DisableCreateExplorerShellUnelevatedTask
ScheduledTask DisableCreateExplorerShellUnelevatedTask
{
TaskName = 'CreateExplorerShellUnelevatedTask'
TaskPath = '\'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Configuration Example
$NodeName = 'localhost'
)

Import-DscResource -ModuleName xComputerManagement
Import-DscResource -ModuleName ComputerManagementDsc

Node $NodeName
{
xScheduledTask DeleteCreateExplorerShellUnelevatedTask
ScheduledTask DeleteCreateExplorerShellUnelevatedTask
{
TaskName = 'CreateExplorerShellUnelevatedTask'
TaskPath = '\'
Expand Down
Loading

0 comments on commit 8f9a482

Please sign in to comment.