SPStateServiceApp - dsccommunity/SharePointDsc GitHub Wiki
Parameters
Parameter | Attribute | DataType | Description | Allowed Values |
---|---|---|---|---|
Name | Key | String | The name of the state service app | |
DatabaseName | Required | String | The name of the database for the service app | |
DatabaseCredentials | Write | PSCredential | The database credentials for accessing the database | |
DatabaseServer | Write | String | The name of the database server | |
Ensure | Write | String | Present if the service app should exist, absent if it should not | Present , Absent |
ProxyName | Write | String | The proxy name, if not specified will be /Name of service app/ Proxy | |
UseSQLAuthentication | Write | Boolean | Should SQL Server authentication be used to connect to the database (unlikely, unless using an Azure SQL Managed Instance)? |
Description
Type: Distributed Requires CredSSP: No
This resource provisions an instance of the state service in to the local farm. The database specific parameters are only used during initial provisioning of the app, and will not change database settings beyond the initial deployment.
The default value for the Ensure parameter is Present. When not specifying this parameter, the service application is provisioned.
Examples
Example 1
This example creates a state service application in the local farm
Configuration Example
{
param
(
[Parameter(Mandatory = $true)]
[PSCredential]
$SetupAccount
)
Import-DscResource -ModuleName SharePointDsc
node localhost
{
SPStateServiceApp StateServiceApp
{
Name = "State Service Application"
DatabaseName = "SP_State"
Ensure = "Present"
PsDscRunAsCredential = $SetupAccount
}
}
}