-
Notifications
You must be signed in to change notification settings - Fork 108
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
148 additions
and
11 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
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
94 changes: 94 additions & 0 deletions
94
Modules/SharePointDsc/en-US/about_SPSitePropertyBag.help.txt
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 |
---|---|---|
@@ -0,0 +1,94 @@ | ||
.NAME | ||
SPSitePropertyBag | ||
|
||
# Description | ||
|
||
**Type:** Distributed | ||
**Requires CredSSP:** No | ||
|
||
This resource is used to work with SharePoint Property Bags at the site | ||
collection level. The account that runs this resource (PsDscRunAsCredential | ||
or InstallAccount) must be a site collection administrator. | ||
|
||
The default value for the Ensure parameter is Present. When not specifying | ||
this parameter, the property bag is configured. | ||
|
||
.PARAMETER Url | ||
Key - string | ||
The URL of the site collection | ||
|
||
.PARAMETER Key | ||
Key - string | ||
The key of the SPSite property | ||
|
||
.PARAMETER Value | ||
Write - String | ||
Value of the SPSite property | ||
|
||
.PARAMETER Ensure | ||
Write - string | ||
Allowed values: Present, Absent | ||
Set to present to ensure the SPSite property exists, or absent to ensure it is removed | ||
|
||
.PARAMETER InstallAccount | ||
Write - String | ||
POWERSHELL 4 ONLY: The account to run this resource as, use PsDscRunAsCredential if using PowerShell 5 | ||
|
||
|
||
.EXAMPLE | ||
This example shows how add property bag value in a site collection. | ||
|
||
|
||
Configuration Example | ||
{ | ||
param | ||
( | ||
[Parameter(Mandatory = $true)] | ||
[PSCredential] | ||
$SetupAccount | ||
) | ||
|
||
Import-DscResource -ModuleName SharePointDsc | ||
|
||
node localhost | ||
{ | ||
SPSitePropertyBag Site_APPCodeProperty | ||
{ | ||
PsDscRunAsCredential = $SetupAccount | ||
Url = "https://web.contoso.com" | ||
Key = "KeyToAdd" | ||
Value = "ValueToAddOrModify" | ||
Ensure = "Present" | ||
} | ||
} | ||
} | ||
|
||
|
||
.EXAMPLE | ||
This example shows how remove a property bag value in a site collection. | ||
|
||
|
||
Configuration Example | ||
{ | ||
param | ||
( | ||
[Parameter(Mandatory = $true)] | ||
[PSCredential] | ||
$SetupAccount | ||
) | ||
|
||
Import-DscResource -ModuleName SharePointDsc | ||
|
||
node localhost | ||
{ | ||
SPSitePropertyBag Site_APPCodeProperty | ||
{ | ||
PsDscRunAsCredential = $SetupAccount | ||
Url = "https://web.contoso.com" | ||
Key = "KeyToRemove" | ||
Ensure = "Absent" | ||
} | ||
} | ||
} | ||
|
||
|