Configure a Sharepoint 2013 Dev VM to Workflows

SharePoint 2013 supports two Workflow plataforms, one for SharePoint 2010 WFs and another for SharePoint 2013 Wfs.

The 2010 plataform is installed by default with SharePoint 2013.

To work with 2013 workflows, you need to install the workflow manager.

When you finish this setup, you have to decide if you prefer to do the configurations with the wizard, or if you prefer with power shell.

If you prefer power shell, you have a button, in the wizard, to get power shell commands.

You need to change this power shell script with your key, and run it:

# To be run in Workflow Manager PowerShell console that has both Workflow Manager and Service Bus installed.

# Create new SB Farm $SBCertificateAutoGenerationKey = ConvertTo-SecureString -AsPlainText  -Force  -String ‘***** Replace with Service Bus Certificate Auto-generation key ******’ -Verbose;

New-SBFarm -SBFarmDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=SbManagementDB;Integrated Security=True;Encrypt=False’ -InternalPortRangeStart 9000 -TcpPort 9354 -MessageBrokerPort 9356 -RunAsAccount ‘Administrator’ -AdminGroup ‘BUILTIN\Administrators’ -GatewayDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=SbGatewayDatabase;Integrated Security=True;Encrypt=False’ -CertificateAutoGenerationKey $SBCertificateAutoGenerationKey -MessageContainerDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=SBMessageContainer01;Integrated Security=True;Encrypt=False’ -Verbose;

# To be run in Workflow Manager PowerShell console that has both Workflow Manager and Service Bus installed.

# Create new WF Farm $WFCertAutoGenerationKey = ConvertTo-SecureString -AsPlainText  -Force  -String ‘***** Replace with Workflow Manager Certificate Auto-generation key ******’ -Verbose;

New-WFFarm -WFFarmDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=WFManagementDB;Integrated Security=True;Encrypt=False’ -RunAsAccount ‘Administrator’ -AdminGroup ‘BUILTIN\Administrators’ -HttpsPort 12290 -HttpPort 12291 -InstanceDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=WFInstanceManagementDB;Integrated Security=True;Encrypt=False’ -ResourceDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=WFResourceManagementDB;Integrated Security=True;Encrypt=False’ -CertificateAutoGenerationKey $WFCertAutoGenerationKey -Verbose;

# Add SB Host $SBRunAsPassword = ConvertTo-SecureString -AsPlainText  -Force  -String ‘***** Replace with RunAs Password for Service Bus ******’ -Verbose;

Add-SBHost -SBFarmDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=SbManagementDB;Integrated Security=True;Encrypt=False’ -RunAsPassword $SBRunAsPassword -EnableFirewallRules $true -CertificateAutoGenerationKey $SBCertificateAutoGenerationKey -Verbose;

Try {     # Create new SB Namespace     New-SBNamespace -Name ‘WorkflowDefaultNamespace’ -AddressingScheme ‘Path’ -ManageUsers ‘Administrator’,’Administrator’ -Verbose;

Start-Sleep -s 90 } Catch [system.InvalidOperationException] { }

# Get SB Client Configuration $SBClientConfiguration = Get-SBClientConfiguration -Namespaces ‘WorkflowDefaultNamespace’ -Verbose;

# Add WF Host $WFRunAsPassword = ConvertTo-SecureString -AsPlainText  -Force  -String ‘***** Replace with RunAs Password for Workflow Manager ******’ -Verbose;

Add-WFHost -WFFarmDBConnectionString ‘Data Source=WIN-UOLELEUK31P\SHAREPOINT;Initial Catalog=WFManagementDB;Integrated Security=True;Encrypt=False’ -RunAsPassword $WFRunAsPassword -EnableFirewallRules $true -SBClientConfiguration $SBClientConfiguration -EnableHttpPort  -CertificateAutoGenerationKey $WFCertAutoGenerationKey -Verbose;

After this you can run inetmgr and see in the iis the new site for WF Manager services.

If there is no http binding, configure that to port 12291, this can happen if you didn’t select http enabled in the installation wizard.

wf

After that, you have to configure your communications using http:

Register-SPWorkflowService –SPSite “http://myserver/mysitecollection” –WorkflowHostUri “http://workflow.example.com:12291” –AllowOAuthHttp

Or https:

Register-SPWorkflowService –SPSite “https://myserver/mysitecollection” –WorkflowHostUri https://workflow.example.com:12290

References: http://technet.microsoft.com/en-us/library/jj658588.aspx#section4

Advertisements

Tags: ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: