File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7575
7676 begin {
7777
78+ # Get the module configurations
79+ $pdcSqlInstance = Get-PSFConfigValue - FullName psdatabaseclone.database.Server
80+ $pdcDatabase = Get-PSFConfigValue - FullName psdatabaseclone.database.name
81+ if (-not $pdcCredential ) {
82+ $pdcCredential = Get-PSFConfigValue - FullName psdatabaseclone.database.credential - Fallback $null
83+ }
84+ else {
85+ $pdcCredential = $PSDCSqlCredential
86+ }
87+
7888 # Test the module database setup
7989 try {
80- Test-PSDCConfiguration - SqlCredential $PSDCSqlCredential - EnableException
90+ Test-PSDCConfiguration - SqlCredential $pdcCredential - EnableException
8191 }
8292 catch {
8393 Stop-PSFFunction - Message " Something is wrong in the module configuration" - ErrorRecord $_ - Continue
8494 }
8595
86- $pdcSqlInstance = Get-PSFConfigValue - FullName psdatabaseclone.database.server
87- $pdcDatabase = Get-PSFConfigValue - FullName psdatabaseclone.database.name
88-
8996 $query = "
9097 SELECT c.CloneID,
9198 c.CloneLocation,
You can’t perform that action at this time.
0 commit comments