This is a Proof of Concept Project on how a database solution can be utilized to manage DSC configurations. Metadata for the configuration is stored in JSON within the database so that it can be easily retrieved and deployed. Credentials are also stored securely in the database. The project consists of a database schema and a PowerShell module which has a series of functions.
Перейти к файлу
Troy Ault e7b534dc9a Update to Readme 2017-08-17 14:51:49 -04:00
.vscode LiabAzureUpdate with GUI 2017-06-12 16:21:14 -04:00
build Addition of AlwaysOn Configuration and bug fixes 2016-09-08 12:40:22 -04:00
modules Adding New DSCCentral Functionality 2017-02-08 13:53:40 -05:00
scripts Modfication to Status update 2016-09-09 14:02:19 -04:00
sql Added SSDT project and associated T-SQL. 2017-02-09 14:09:52 -05:00
utility/LabInaBox Update to Readme 2017-08-17 14:51:49 -04:00
.gitattributes Added SSDT project and associated T-SQL. 2017-02-09 14:09:52 -05:00
.gitignore Added SSDT project and associated T-SQL. 2017-02-09 14:09:52 -05:00
LICENSE Initial setup 2016-08-15 14:45:33 -04:00
README.md Addition of functions and simplification 2016-12-12 13:26:47 -05:00

README.md

Build status

DSC-data-driven-deployment

Proof-of-concept project illustrating an approach to persisting configuration which allows one to manage and apply DSC configurations in a push driven environment. Metadata such as parameters and defaults for the configuration are stored as JSON within a database so that it can be programmatically retrieved and deployed. Credentials are also stored securely in the database. A queuing mechanism exposed as a cmdlet and backed by a table is provided as a means to push configurations on demand.

Why?

Provide a central repository to store configurations and credentials, to allow efficient Enterprise provisioning and auditing of configurations.

##Prerequisites

  • SQL Server to hold central database repository.
  • Windows Server to act as central deployment server.

##Installation

  • Log on to SQL Server
  • Clone repository with git clone https://github.com/Microsoft/DSC-data-driven-deployment
    • If Clone location is other than C:\DSC-data-driven-deployment\Modules\ConfigurationHelper.psm1 then update DSCExecutionTask.ps1 and InputDSCConfigurationMetadata.ps1 to reflect the location.
  • Open PowerShell Prompt as admin
  • Install-module xSQLServer
  • Edit DSCDataDrivenSQLConfiguration.ps1 replace variable values for your environment
  • Run DSCDataDrivenSQLConfiguration.ps1
  • Open SSMS connect to server.
    • Right click Databases and select Deploy-Data-tier Application
    • Select dacpac from build directory
    • Click Next and Finish
  • Log on to Deployment Server
    • Copy Project locally to Deployment Server. Same drive letter as SQL or modifications will need to be made.
    • Open PowerShell Prompt as admin
    • Install-module xSQLServer
    • Install-module xFailoverCluster
  • Open InputDSCConfigurationMetadata.ps1 and modify parmaters at top to meet your environment.
  • Execute InputDSCConfigurationMetaData.ps1
  • Modify DSCSQLMetaBuild.ps1 to match your needs
  • Create scheduled task to call script
  • At this point you can use the Examples commented out in InputDSCConfigurationMetadata.ps1 to Enqueue a new build request.

##Assumptions

  • SMB (Port 445) is open between deployment server and servers to receive configuration.
    • xcopy of DSC module is leveraged to move DSC module to remote node
  • Configurations provided are using AllowPlainTextPassword for demonstration purposes only.
    • Configurations should be updated to leverage certificates so passwords are not stored plain text.
    • Steps to complete this are detailed here
  • SQL Server bits location provided must have a folder in it called Source with the installation bits of SQL Server
  • Windows Bits location provided must have the full path to the sxs folder of Windows Server you are applying .NET

##Updates

  • New Utility added LabInaBox
  • LabInaBox updated with new simplified approach. Functions provided which take JSON file with required paramaters.

Contribute

There are many ways to contribute.

  • Submit bugs and help us verify fixes as they are checked in.
  • Review code changes.
  • Contribute bug fixes and features.

For code contributions, you will need to complete a Contributor License Agreement (CLA). Briefly, this agreement testifies that you grant us permission to use the submitted change according to the terms of the project's license, and that the work being submitted is under the appropriate copyright.

Please submit a Contributor License Agreement (CLA) before submitting a pull request. You may visit https://cla.microsoft.com to sign digitally. Alternatively, download the agreement Microsoft Contribution License Agreement.pdf, sign, scan, and email it back to cla@microsoft.com. Be sure to include your GitHub user name along with the agreement. Once we have received the signed CLA, we'll review the request.

##Code of Conduct This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.

License

This project is licensed under the MIT License.