Home > Workflow Manager > Configuring Workflow Manager 1.0 using PowerShell

Configuring Workflow Manager 1.0 using PowerShell

This post covers the process of configuring Workflow Manager 1.0 using PowerShell. It assumes that Workflow Manager 1.0 has already been installed. To get the step by step on the installation procedure, check this article. In Configuring Workflow Manager 1.0, I have detailed the post installation configuration process of the Workflow Manager product through the Configuration Wizard UI. If however, you like me, are the kind of person that would like to monitor as many steps along the process as you can, you may want to run configuration through PowerShell. Note that while you can follow the commands purely as shown in this article, and make required changes for your environment, it would be easier to refer to the configuration post and use the wizard to make all the settings but not run it. Instead, at the end of that article, you can see how the PowerShell commands based on the settings made are handed to you by the wizard so you can copy them, close out the wizard and move on to the console.

You can run the entire configuration process through a script that the configuration wizard provides you as mentioned above. All you need to do to generate this script is use the Get PowerShell Commands link on the Summary page. There are a couple of good reasons for using PowerShell instead of the wizard based configuration process

  1. You can run each command, verify the outcome and move on to the next step confidently.
  2. Error handling becomes easier since it is very evident what specific operation failed and you can resume after the last successful step.

If you have already copied, the PowerShell commands provided by the configuration wizard, you may have to or want to make some changes to it before you proceed. The following are the changes I made.

  1. If you open the commands, you will notice that text at the places where the RunAs account password or the certificate generation key are used have been replaced with some placeholder text (which looks like this – ‘***** Replace with Workflow Manager Certificate Auto-generation key *****’) so as not expose those. This will need to be corrected.
  2. The script instantiates a couple of references to hold the certificate generation key – $WFCertAutoGenerationKey and $SBCertificateAutoGenerationKey. These are used in the New-SBFarm, New-WFFarm, Add-WFHost and Add-SBHost commands to follow. It does this because this allows using different certificate auto-generation keys for each service. If you wish to use the same certificate, you can eliminate one of these statements and make sure you use the variable from the other in both commands.
  3. The same as above holds true for the RunAsPassword. One of these can be removed and the variable from the other statement can be used in both the Add-SBHost and Add-WFHost commands.
  4. Once all of this is done, you may choose to save the script as a PS1 file and run the entire set of commands at once through the console or type each command individually.

To start configuration, launch a new Workflow Manager PowerShell console. You should find a shortcut to this in the Workflow Manager 1.0 program folder in the Start menu. If not, you could navigate to %ProgramFiles%\Workflow Manager\1.0\Scripts and run StartWFConsole.cmd. Either way, you’ll end up launching Windows PowerShell with the WorkflowManager module imported.


STEP 1 – Get a secured string for the Certificate Generation Key


STEP 2 – Create a new Service Bus farm


In progress…


… and done.


STEP 3 – Create a new Workflow Management farm


In progress…


… and done.


STEP 4 – Get secure string for the super-secret password


STEP 5 – Add this host to the service bus farm


In progress. The part where the service bus services are started may take a while. This is where the Service Bus Gateway and the Service Bus Message Broker are being spun up. This is also the most troublesome part of the entire configuration process.


And done.


The farm information now looks as shown below


If you face any challenges with the addition of the host to the service bus farm, please check this post to see if you are having a problem similar to the ones documented. If everything went alright, you can proceed on to the next step.

STEP 6 – Create a namespace on the Service Bus to be used by Workflow Manager. Couple of things to note here.

First, you can call this namespace anything as long as you ensure you use the same name in the client configuration parameter you use when adding the host to the Workflow Manager farm.

Second, if you copied the configuration PowerShell from the wizard, it does some exception handling and implements a wait after the New-SBNamespace cmdlet is called presumably to allow the time it takes for the instantiation to complete before we proceed on to getting a client configuration based on it. I am not doing any of this below because I am running each command in sequence and can manually handle these things.


STEP 7 – Get a client configuration for the namespace just created. This provides you an XML structure that can be used by the Workflow Manager client to establish connections and communicate with the Service Bus.


STEP 8 – Finally, add the current host to the Workflow Manager farm. This usually goes through without a hitch and completes the configuration. At least on the Workflow Manager.


So you see a couple of HTTPS and HTTP endpoints. Let’s take a quick look at IIS Manager to see if these show up correctly. As you can see below, there is now a Workflow Management site on IIS that is bound to port 12290 for SSL and 12291 for HTTP based communication.


One final piece of verification is to hit up the workflow endpoint over HTTP in a browser. And everything looks good.


If you’ve gotten this far, you are done with the farm creation process and the addition of the host to the farms. The Workflow Manager farm should be online and humming merrily at this point. But if your original intent for the farm was to lend its cool new features to SharePoint 2013, check out how to Configure SharePoint 2013 to use Workflow Manager 1.0 services.

  1. No comments yet.
  1. December 12, 2013 at 6:34 AM

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: