forked from dsccommunity/SqlServerDsc
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed a bug if the alias did not exists then Get-ItemProperty would throw an error. Fixed a bug so that the logic to create a new alias is triggered. If the alias did not exist it was the change-logic that created the alias, not the create-logic. Fixed a bug in the create-logic that throw an error if the key ConnectTo already existed. Removed that New-Item since we already test for the existence of the key. Also some style changes. Changes to xSQLAlias Improved testing and added a test for removal of alias Bug found with the test, create-logic was called when it shouldn't Aligned schemas with README.md Also added add text that explains the use of the credential parameter (issue from dsccommunity#58)
- Loading branch information
Showing
6 changed files
with
141 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 13 additions & 15 deletions
28
DSCResources/MSFT_xSQLAOGroupEnsure/MSFT_xSQLAOGroupEnsure.schema.mof
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
|
||
[ClassVersion("1.0.0.0"), FriendlyName("xSQLAOGroupEnsure")] | ||
class MSFT_xSQLAOGroupEnsure : OMI_BaseResource | ||
{ | ||
[Key, ValueMap{"Present","Absent"}, Values{"Present","Absent"}] String Ensure; | ||
[Key] String AvailabilityGroupName; | ||
[Write] String AvailabilityGroupNameListener; | ||
[Write] String AvailabilityGroupNameIP[]; | ||
[Write] String AvailabilityGroupSubMask[]; | ||
[Write] Uint32 AvailabilityGroupPort; | ||
[Write, ValueMap{"None","ReadOnly","ReadIntent"}, Values{"None","ReadOnly","ReadIntent"}] String ReadableSecondary; | ||
[Write, ValueMap{"Primary","Secondary"}, Values{"Primary","Secondary"}] String AutoBackupPreference; | ||
[Write] Uint32 BackupPriority; | ||
[Write] Uint32 EndPointPort; | ||
[Write] String SQLServer; | ||
[Write] String SQLInstanceName; | ||
[Required, EmbeddedInstance("MSFT_Credential"), Description("Credential to be used to Grant Permissions in SQL.")] String SetupCredential; | ||
[Key, Description("Determines whether the availability group should be added or removed."), ValueMap{"Present","Absent"}, Values{"Present","Absent"}] String Ensure; | ||
[Key, Description("Name for availability group.")] String AvailabilityGroupName; | ||
[Write, Description("Listener name for availability group.")] String AvailabilityGroupNameListener; | ||
[Write, Description("List of IP addresses associated with listener.")] String AvailabilityGroupNameIP[]; | ||
[Write, Description("Network subnetmask for listener.")] String AvailabilityGroupSubMask[]; | ||
[Write, Description("Port availability group should listen on.")] Uint32 AvailabilityGroupPort; | ||
[Write, Description("Mode secondaries should operate under (None, ReadOnly, ReadIntent)."), ValueMap{"None","ReadOnly","ReadIntent"}, Values{"None","ReadOnly","ReadIntent"}] String ReadableSecondary; | ||
[Write, Description("Where backups should be backed up from (Primary, Secondary)."), ValueMap{"Primary","Secondary"}, Values{"Primary","Secondary"}] String AutoBackupPreference; | ||
[Write, Description("The percentage weight for backup prority (default 50).")] Uint32 BackupPriority; | ||
[Write, Description("he TCP port for the SQL AG Endpoint (default 5022).")] Uint32 EndPointPort; | ||
[Write, Description("The SQL Server for the database.")] String SQLServer; | ||
[Write, Description("The SQL instance for the database.")] String SQLInstanceName; | ||
[Required, EmbeddedInstance("MSFT_Credential"), Description("Credential to be used to Grant Permissions on SQL Server, set this to $null to use Windows Authentication.")] String SetupCredential; | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.