Skip to content

Commit

Permalink
Merge pull request #102 from dsccommunity/ModuleDependencies
Browse files Browse the repository at this point in the history
Module dependencies: Removing external module dependencies
  • Loading branch information
NEllis280 authored Nov 11, 2021
2 parents 250092b + ac9eebb commit e75f2d0
Show file tree
Hide file tree
Showing 9 changed files with 73 additions and 683 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- Added support for VPN and IPv6Prefix boundaries to the CMBoundaries resource.
- Updated module versions for SqlServerDsc, NetworkingDsc, ComputerManagementDsc
- Removed firewall configurations from the xSccmPreReqs resource. See
(Source\Examples\PrimaryInstall.ps1) for an example of firewall configurations.

### Removed

- Removed xSccmSql resource in favor of using the SQLSetup resource. See
(Source\Examples\PrimaryInstall.ps1) for an example of a SQL install configuration.

## [1.0.2] - 2021-05-12

Expand Down
86 changes: 4 additions & 82 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ is Import-ConfigMgrPowerShellModule.

This project has adopted this [Code of Conduct](CODE_OF_CONDUCT.md).

## Change Log

A full list of changes in each version can be found in the [Change Log](CHANGELOG.md).

## Releases

For each merge to the branch `master` a preview release will be
Expand All @@ -53,7 +57,6 @@ Please check out common DSC Community [contributing guidelines](https://dsccommu
- **xSccmPreReqs**: Provides a composite resource to install ADK, ADK WinPE, MDT,
required Windows Features, modify Local Administrators group, and create the
no_sms_on_drive files.
- **xSccmSqlSetup**: Provides a composite resource to install SQL for SCCM.
- **xSccmInstall**: Provides a composite resource to install SCCM.
- **ClientSettings**: Provides a resource to perform configuration of client settings.
- **CMAccounts**: Provides a resource to manage Configuration Manager accounts.
Expand Down Expand Up @@ -189,20 +192,9 @@ Please check out common DSC Community [contributing guidelines](https://dsccommu
EnrollmentPoint | EnrollmentProxyPoint | FallbackServicePoint |
ManagementPoint | ReportingServicesPoint | ServiceConnectionPoint |
StateMigrationPoint | SoftwareUpdatePoint}
- **[Boolean] AddWindowsFirewallRule** : Specifies whether to add the Windows
Firewall Rules needed for the install.
Default Value: $false
- **[String] WindowsFeatureSource** : Specifies the source that will be used
to install windows features if the files are not present in the local
side-by-side store.
- **[String[]] FirewallProfile** : Specifies the Windows Firewall profile for
the rules to be added.
- **[String[]] FirewallTcpLocalPort** : Specifies the TCP ports to be added to
the windows firewall as allowed.
Default Value: @('1433','1434','4022','445','135','139','49154-49157')
- **[String[]] FirewallUdpLocalPort** : Specifies the UDP ports to be added to
the windows firewall as allowed.
Default Value: @('137-138','1434','5355')
- **[String] LocalAdministrators** : Specifies the accounts and/or groups you
want to add to the local administrators group.
- **[String] NoSmsOnDrives** : Specifies the drive letters of the drive you
Expand Down Expand Up @@ -254,76 +246,6 @@ you are using apply and auto correct.

- [SccmInstall](Source\Examples\Resources\xSccmInstall\SccmInstall.ps1)

### xSccmSqlSetup

- **[String] SqlVersion** _(Required)_: Specify the version of SQL to be installed.
- Values: { 2008 | 2008R2 | 2012 | 2014 | 2016 | 2017 | 2019 }
- **[String] SqlInstallPath** _(Required)_: Specifies the path to the setup.exe
file for SQL.
- **[String] SqlInstanceName** _(Required)_: Specifies a SQL Server instance name.
- **[PSCredential] SqlServiceCredential** _(Required)_: Specifies the credential
for the service account used to run the SQL Service.
- **[PSCredential] SqlAgentServiceCredential** _(Required)_: Specifies the
credential for the service account used to run the SQL Agent Service.
- **[String] SqlSysAdminAccounts** _(Required)_: Use this parameter to provision
logins to be members of the sysadmin role.
- **[String]** : SQL features to install.
Default Value: 'SQLENGINE,RS,CONN,BC,SSMS,ADV_SSMS'
- **[String] InstallSharedDir** : Specifies the installation directory for
64-bit shared components.
Default Value: 'C:\Program Files\Microsoft SQL Server'
- **[String] InstallSharedWowDir** : Specifies the installation directory for
32-bit shared components. Supported only on a 64-bit system.
Default Value: 'C:\Program Files (x86)\Microsoft SQL Server'
- **[String] InstanceDir** : Specifies the installation path for SQL Server
instance files.
Default Value: 'C:\Program Files\Microsoft SQL Server'
- **[String] RSSvcStartupType** : Specifies the startup mode for Reporting Services.
Default Value: 'Automatic'
- **[String] AgtSvcStartupType** : Specifies the startup mode for the SQL Server
Agent service.
Default Value: 'Automatic'
- **[String] RSInstallMode** : Specifies the Install mode for Reporting Services.
Default Value: 'DefaultNativeMode'
- **[String] SqlCollation** : Specifies the collation settings for SQL Server.
Default Value: 'SQL_Latin1_General_CP1_CI_AS'
- **[String] InstallSqlDataDir** : Specifies the data directory for SQL Server
data files.
Default Value: 'C:\'
- **[String] SqlUserDBDir** : Specifies the directory for the data
files for user databases.
Default Value: '<InstallSQLDataDir>\<SQLInstanceID>\MSSQL\Data'
- **[String] SqlUserDBLogDir** : Specifies the directory for the log
files for user databases.
Default Value: '<InstallSQLDataDir>\<SQLInstanceID>\MSSQL\Data'
- **[String] SqlTempDBDir** : Specifies the directory for the data
files for tempdb.
Default Value: '<InstallSQLDataDir>\<SQLInstanceID>\MSSQL\Data'
- **[String] SqlTempDBLogDir** : Specifies the directory for the log
files for tempdb.
Default Value: '<InstallSQLDataDir>\<SQLInstanceID>\MSSQL\Data'
- **[String] UpdateEnabled** : Specify whether SQL Server setup should discover
and include product updates.
Default Value: $false
- **[String] SqlPort** : Specifies the port SQL listens on.
Default Value: 1433
- **[String] InstallManagementStudio** : Specify whether to install SQL
Management Studio.
Default Value: $false
- **[String] SqlManagementStudioExePath** : Specify that path and filename to
the exe for Management Studio instal.
- **[String] SqlManagementStudioName** : Specify the name of SQL Server
Management Studio.
Default Value: 'SQL Server Management Studio'
- **[String] SqlManagementStudioProductId** : Specify the product if of the SQL
Management Studio install being performed.
Default Value: 'E3FD687D-6757-474B-8D83-5AA944B02C58'

#### xSccmSqlSetup Examples

- [SccmSqlSetup](Source\Examples\Resources\xSccmSqlSetup\SccmSqlSetup.ps1)
- [SccmSqlSetupandManagemenStudio](Source\Examples\Resources\xSccmSqlSetup\SccmSqlSetupAndManagementStudio.ps1)

### CMAccounts

- **[String] SiteCode** _(Key)_: Specifies the Site Code for the Configuration
Expand Down
63 changes: 0 additions & 63 deletions source/DSCResources/xSccmPreReqs/xSccmPreReqs.schema.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -35,18 +35,6 @@
.PARAMETER SccmRole
Specify the SCCM Roles that will be on the server.
.PARAMETER AddWindowsFirewallRule
Specify whether to add the Windows Firewall Rules needed for the install.
.PARAMETER FirewallProfile
Specify the Windows Firewall profile for the rules to be added.
.PARAMETER FirewallTcpLocalPort
Specify the TCP ports to be added to the windows firewall as allowed.
.PARAMETER FirewallUdpLocalPort
Specify the UDP ports to be added to the windows firewall as allowed.
.PARAMETER LocalAdministrators
Specifies the accounts and/or groups you want to add to the local administrators group.
Expand Down Expand Up @@ -131,22 +119,6 @@ Configuration xSCCMPreReqs
[System.String[]]
$SccmRole = 'CASorSiteServer',

[Parameter()]
[Boolean]
$AddWindowsFirewallRule = $false,

[Parameter()]
[System.String[]]
$FirewallProfile,

[Parameter()]
[System.String[]]
$FirewallTcpLocalPort = @('1433','1434','4022','445','135','139','49154-49157'),

[Parameter()]
[System.String[]]
$FirewallUdpLocalPort = @('137-138','1434','5355'),

[Parameter()]
[System.String[]]
$LocalAdministrators,
Expand Down Expand Up @@ -193,7 +165,6 @@ Configuration xSCCMPreReqs
)

Import-DscResource -ModuleName PSDesiredStateConfiguration
Import-DscResource -ModuleName NetworkingDsc -ModuleVersion 8.2.0

$features = @()
foreach ($role in $SccmRole)
Expand Down Expand Up @@ -257,40 +228,6 @@ Configuration xSCCMPreReqs
}
}

if ($AddWindowsFirewallRule)
{
if ($null -eq $FirewallProfile)
{
throw 'When specifying AddWindowsFirewallRule you need to provide FirewallProfile, FirewallTcpLocalPort, and FirewallUdpLocalPort.'
}

Firewall AddSccmTCPFirewallRule
{
Name = 'SCCMServerTCP'
DisplayName = 'SCCM to SCCM communication - TCP'
Ensure = 'Present'
Enabled = 'True'
Profile = $FirewallProfile
Direction = 'Inbound'
LocalPort = $FirewallTcpLocalPort
Protocol = 'TCP'
Description = 'Firewall Rule SCCM to SCCM communication - TCP'
}

Firewall AddSccmUdpFirewallRule
{
Name = 'SCCMServerUDP'
DisplayName = 'SCCM to SCCM communication - UDP'
Ensure = 'Present'
Enabled = 'True'
Profile = $FirewallProfile
Direction = 'Inbound'
LocalPort = $FirewallUdpLocalPort
Protocol = 'UDP'
Description = 'Firewall Rule SCCM to SCCM communication - UDP'
}
}

$domainAccounts = $Localadministrators | Where-Object -FilterScript {$_ -like '*\*' -and $_ -notlike 'BUILTIN\*' -and $_ -notlike '.\*' -and $_ -notlike '*@*'}

if ($domainAccounts -gt 0)
Expand Down
113 changes: 0 additions & 113 deletions source/DSCResources/xSccmSqlSetup/xSccmSqlSetup.psd1

This file was deleted.

Loading

0 comments on commit e75f2d0

Please sign in to comment.