Referencing these blog posts, with my own additions:
Alex’s blog: http://www.sharepointalex.co.uk/index.php/2012/11/enabling-sharepoint-2013-apps/
Mirjam van Olst‘s blog: http://www.sharepointchick.com/archive/2012/07/29/setting-up-your-app-domain-for-sharepoint-2013.aspx
For the most part, I followed Alex’s blog post.
-
Start the App Management Service (already done)
-
Provision an App Management Service application (already done)
-
Create a subdomain in DNS. I created apps.cfgmgt.local
-
Set the isolated App Domain using PowerShell
-
Set-SPAppDomain -AppDomain "apps.cfgmgt.local"
-
Start the SPSubscriptionSettings Service using PowerShell or in SCA (already started)
-
Get-SPServiceInstance where{$_.GetType().Name -eq "SPSubscriptionSettingsServiceInstance"} | Start-SPServiceInstance
-
Ensure the App Management Service and SPSubscriptionSettings Services are online (PowerShell or SCA)
-
Get-SPServiceInstance | where{$_.GetType().Name -eq "AppManagementServiceInstance" -or $_.GetType().Name -eq "SPSubscriptionSettingsServiceInstance"}
-
Provision a Subscription Settings Service Application (This was done during the initial setup of SharePoint in my case. Must use PowerShell, as there is no UI in SCA.)
-
Get-SPServiceApplicationPool (to see all Server Application app pools)
-
$appPool = Get-SPServiceApplicationPool "SharePoint Service AppPool"
-
$appSubSvc = New-SPSubscriptionSettingsServiceApplication –ApplicationPool $appPool –Name "Subscription Settings Service Application" –DatabaseName Your_database_name
-
$proxySubSvc = New-SPSubscriptionSettingsServiceApplicationProxy –ServiceApplication $appSubSvc
-
Visit the Manage Service Applications page in Central Admin and verify that both the App Management Service App and Subscriptions Settings Service App are provisioned and started.
-
Create an app catalog. From SCA, select Apps|Manage App Catalog. Be sure and select the correct web application where you want the app catalog created.
-
You’ll get a page where you can fill in all the app catalog details.
-
Configure the app URLs. From SCA, select Apps|Configure App URLs.
-
You need a web application (no site collection needs to be created in it) on port 80 that has no host header. Others have stated you need to create a site collection, but I haven’t had to.
Here are some details, with screen shots, of what I did.
Created a web application on port 80 with no host header.
Changed the public URL so it wouldn’t conflict with my default site, CMSP2013.
Used an existing app pool. Each app pool has a lot of overhead, so you don’t want to make too many unless you have a good reason.
Changed the name of the content database to match my naming conventions. I then initiated the creation of the new web application.
…and there you go.
You might notice your primary site is stopped in IIS. (Perhaps if you do an IISRESET this will clear up.)
So just start it!
In Central Administration, configure the app URLs. The app domain was already there due to executing
Set-SPAppDomain -AppDomain "apps.cfgmgt.local"
in PowerShell earlier.
To create an App Catalog use Manage App Catalog.
Select the appropriate web application. An app catalog is associated with a single web application.
Fill out the details to create the App Catalog site collection.
So then we go to add an app.
Select the SharePoint Store.
Find the Corporate News app.
Pick the free one, because we’re cheap!
Go through the download and trust process.
If we look at our Site Contents, we should see the apps that have been downloaded.
If you click on one, you should get the app’s administration page. If you don’t have your port 80 web application with no host header set up, this will return an error (404) due to the way it redirects using a GUID.
Here’s an example URL that uses the subdomain previously set up in DNS.
And adding the App Part (like adding a web part) to the default page for testing it out.
ERRORS
I attempted to look at the details of an app that was downloaded and installed and SharePoint threw an error with a correlation ID.
Insufficient SQL database permissions for user ‘Name: NT AUTHORITY\IUSR SID: S-1-5-17 ImpersonationLevel: Impersonation’ in database ‘SP15_UsageAndHealth’ on SQL Server instance ‘SP2013SQL’. Additional error information from SQL Server is included below. The EXECUTE permission was denied on the object ‘prc_CountAppInstanceData’, database ‘SP15_UsageAndHealth’, schema ‘dbo’.
This was resolved by identifying the account under which the App Management Service was running (don’t let the NT AUTHORITY\IUSR account throw you off).
Next, SQL was investigated for the SQL Login and it was found only a few stored procedures had been granted access to the login. Instead of adding the stored procedures either individually or en masse, I decided to put the login into one of the existing SharePoint roles.
I appears that putting it into the SPReadOnly database role provides the required execute permissions for the stored procedures.
And for reference, you can see SPReadOnly provides Execute and Select permissions to the database.