Skip to content

Commit

Permalink
Merge pull request #5561 from ykuijs/Dev
Browse files Browse the repository at this point in the history
Fixing Export does not convert tenant name into generic $OrganizationName variable
  • Loading branch information
NikCharlebois authored Dec 16, 2024
2 parents 550bef8 + 25766c6 commit 52335bc
Show file tree
Hide file tree
Showing 43 changed files with 1,442 additions and 721 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
* FIXES [#5550](https://github.com/microsoft/Microsoft365DSC/issues/5550)
* MISC
* Fixed the Fabric web request to use basic parsing.
* Fixed an issue where the export does not convert tenant name into
generic $OrganizationName variable correctly.
* M365DSCUtil
* Update `Get-M365DSCWorkloadsListFromResourceNames` function for more input types.
FIXES [#5525](https://github.com/microsoft/Microsoft365DSC/issues/5525)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1149,9 +1149,8 @@ function Export-TargetResource
$currentDSCBlock = Convert-DSCStringParamToVariable -DSCBlock $currentDSCBlock -ParameterName 'Members' -IsCIMArray $true
$currentDSCBlock = $currentDSCBlock.Replace("`",`"`r`n", '')
$currentDSCBlock = $currentDSCBlock.Replace(",`r`n", '').Replace("`");`r`n", ");`r`n")
$currentDSCBlock = $currentDSCBlock.Replace("Members = @(`"", 'Members = @(')
$currentDSCBlock = $currentDSCBlock.Replace("`$OrganizationName'", "' + `$OrganizationName")
}

$dscContent += $currentDSCBlock
Save-M365DSCPartialExport -Content $currentDSCBlock `
-FileName $Global:PartialExportFileName
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ class MSFT_DeviceManagementConfigurationPolicyAssignments
[Write, Description("The collection Id that is the target of the assignment.(ConfigMgr)")] String collectionId;
};



[ClassVersion("1.0.0.0")]
class MSFT_MicrosoftGraphIntuneSettingsCatalogpol_hardenedpaths
{
Expand Down Expand Up @@ -491,6 +489,7 @@ class MSFT_MicrosoftGraphIntuneSettingsCatalogDeviceSettings_IntuneSecurityBasel
[Write, Description("AD Password Encryption Principal - Depends on BackupDirectory")] String ADPasswordEncryptionPrincipal;
[Write, Description("Password Expiration Protection Enabled - Depends on BackupDirectory (false: Allow configured password expiriration timestamp to exceed maximum password age, true: Do not allow configured password expiriration timestamp to exceed maximum password age)"), ValueMap{"false", "true"}, Values{"false", "true"}] String PasswordExpirationProtectionEnabled;
};

[ClassVersion("1.0.0.0")]
class MSFT_MicrosoftGraphIntuneSettingsCatalogUserSettings_IntuneSecurityBaselineWindows10
{
Expand All @@ -506,6 +505,7 @@ class MSFT_MicrosoftGraphIntuneSettingsCatalogUserSettings_IntuneSecurityBaselin
[Write, Description("Allow Windows Spotlight Windows Welcome Experience (User) - Depends on AllowWindowsSpotlight (0: Not allowed., 1: Allowed.)"), ValueMap{"0", "1"}, Values{"0", "1"}] String AllowWindowsSpotlightWindowsWelcomeExperience;
[Write, Description("Allow Third Party Suggestions In Windows Spotlight (User) - Depends on AllowWindowsSpotlight (0: Third-party suggestions not allowed., 1: Third-party suggestions allowed.)"), ValueMap{"0", "1"}, Values{"0", "1"}] String AllowThirdPartySuggestionsInWindowsSpotlight;
};

[ClassVersion("1.0.0.0"), FriendlyName("IntuneSecurityBaselineWindows10")]
class MSFT_IntuneSecurityBaselineWindows10 : OMI_BaseResource
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,44 +1,44 @@
{
"resourceName":"IntuneSecurityBaselineWindows10",
"description":"This resource configures an Intune Security Baseline for Windows10.",
"permissions":{
"graph":{
"delegated":{
"read":[
{
"name":"DeviceManagementConfiguration.Read.All"
},
{
"name":"Group.Read.All"
}
],
"update":[
{
"name":"Group.Read.All"
"resourceName": "IntuneSecurityBaselineWindows10",
"description": "This resource configures an Intune Security Baseline for Windows10.",
"permissions": {
"graph": {
"delegated": {
"read": [
{
"name": "DeviceManagementConfiguration.Read.All"
},
{
"name": "Group.Read.All"
}
],
"update": [
{
"name": "Group.Read.All"
},
{
"name":"DeviceManagementConfiguration.ReadWrite.All"
}
]
},
"application":{
"read":[
{
"name":"DeviceManagementConfiguration.Read.All"
},
{
"name":"Group.Read.All"
}
],
"update":[
{
"name":"Group.Read.All"
"name": "DeviceManagementConfiguration.ReadWrite.All"
}
]
},
"application": {
"read": [
{
"name": "DeviceManagementConfiguration.Read.All"
},
{
"name": "Group.Read.All"
}
],
"update": [
{
"name": "Group.Read.All"
},
{
"name":"DeviceManagementConfiguration.ReadWrite.All"
}
]
}
}
"name": "DeviceManagementConfiguration.ReadWrite.All"
}
]
}
}
}
}
}
Loading

0 comments on commit 52335bc

Please sign in to comment.