IT tutorials
 
Applications Server
 

Packaging and Deploying Sharepoint 2013 Apps : Deploying an App (part 1) - SharePoint-Hosted App Deployment

2/8/2014 1:10:38 AM
- Free product key for windows 10
- Free Product Key for Microsoft office 365
- Malwarebytes Premium 3.7.1 Serial Keys (LifeTime) 2019

The options available for deploying apps depend on your deployment scenario and application type. There are three main application types and each one requires a different deployment scenario. Table 1 summarizes these various scenarios.

TABLE 1: Application Deployment Summary

APP TYPE APP CODE DEPLOYED TO APP PACKAGE DEPLOYED TO
SharePoint-hosted N/A App catalog or Marketplace
Provider-hosted Azure or other App catalog or Marketplace
Autohosted Azure App catalog or Marketplace

SharePoint-hosted apps are a bit simpler than the others given that there isn’t any Web deploy package to have deployed, and because they generally consist of HTML pages and JavaScript only. SharePoint-hosted apps don’t have any other dependencies on a runtime environment for this reason.

Provider-hosted apps are a bit more complex and consist of just an app package without any Web deploy package in it. This is because the provider of the app is already required to be hosting it either in Azure or some other Internet-accessible location. The provider of the app manages running the code for the app and any associated databases or dependent resources.

Autohosted app packages are the only ones that contain Web deploy packages and/or database packages. This is because Autohosted apps are the only app types where SharePoint needs to take both the Web deploy package and database package and deploy them to Azure when the app is installed. Azure is currently the only option for autodeployment in the Autohosted scenario.

1. SharePoint-Hosted App Deployment

SharePoint-hosted apps are the simplest of the three app types to package and deploy because of the lack of a code package and associated deployment steps. All that is required is to package the application using the Publish wizard in Visual Studio and then deploy the app to either the Marketplace or an app catalog. After the app is deployed, users can install the app on their site. When this occurs, SharePoint takes the app package, creates a new app Web for that instance of the application, and provisions the pages and content from the app package into it. Any custom UI actions and App Parts are also deployed to the host Web.

Try your hand at deploying a SharePoint-hosted app in the next exercise to learn how straightforward the process is.


Deploying a SharePoint-Hosted App

In this example you create a very basic SharePoint-hosted app using Visual Studio 2012 development tools and deploy that new app to the app catalog. You will need to use the app catalog created from the previous Try It Out, “Creating a Private App Catalog in Office 365.”

1. Ensure you have created an app catalog. See the earlier exercise, “Creating a Private App Catalog in Office 365.”

2. Open Visual Studio and create a new app for a SharePoint 2013 project called SharePoint Hosted App by selecting File ⇒ New Project ⇒ App for SharePoint 2013. In the Name field enter MySharePointHostedApp.

3. In the New Project wizard specify SharePoint-hosted as shown in Figure 1.

FIGURE 1

image
4. After the project has been created, right-click the project and select Publish. The publishing wizard for the application launches; see Figure 2.

FIGURE 2

image

5. Click Finish. A new Windows Explorer window opens with your application package called MySharePointHostedApp.app showing.

6. Open a browser window and navigate to the tenant admin portal for your Office 365 environment at: http://portal.microsoftonline.com.

7. Under the Admin menu in the top navigation, click SharePoint to go to the SharePoint Online tenant admin pages.

8. Click apps in the left-side navigation.

9. Click the App Catalog link. The app catalog you created in the previous exercise appears.

10. Click the Distribute apps for SharePoint tile.

11. Click the New App button. A prompt appears asking you to pick the .app file for your application.

12. Click Browse and select the .app file that Visual Studio packaged for you in step 5. Click OK. A dialog appears asking for information about your application, as shown in Figure 3.

FIGURE 3

image

13. You are not required to enter any information unless you want to. Click Save to proceed. You should now see your application in the app catalog, as shown in Figure 4.

FIGURE 4

image

14. Navigate to your development site in SharePoint Online.

15. Click Site Contents in the left-side navigation.

16. Click Add an App.

17. Click From Your Organization in the left-side navigation and you should see your newly added application listed, as shown in Figure 5.

FIGURE 5

image

18. Click the tile for the application and click Trust It when prompted. SharePoint Online begins to provision your app in the site.

19. When the process completes, click the newly installed app tile. The Start page for your application appears; your username will be listed as shown in Figure 6.

FIGURE 6

image

How It Works

In this exercise you created a rudimentary SharePoint-hosted app that simply lists the name of the currently logged-in user. You packaged the app ready for deployment using the Publish wizard in Visual Studio and then uploaded and configured the app in the app catalog in SharePoint Online. You then installed the app on a SharePoint Online site. Behind the scenes, SharePoint created a new SharePoint site specifically for this installation of the application and deployed the application’s assets, such as pages and JavaScript, to the appropriate places. You can see in the URL for the app the domain name created and set up specifically for the app instance. These steps are done on demand each time a SharePoint-hosted app is installed. When the application is run it uses the JavaScript Client-Side Object Model to make a call to web.get_currentUser(); to retrieve the currently logged-in user. This code is in the /Scripts/App.js file in the Visual Studio project.
 
Others
 
- Microsoft Lync Server 2013 Edge Server : Edge Server Administration (part 5) - Managing External Web Conferencing Features
- Microsoft Lync Server 2013 Edge Server : Edge Server Administration (part 4) - Managing Public Providers
- Microsoft Lync Server 2013 Edge Server : Edge Server Administration (part 3) - Managing XMPP Federation
- Microsoft Lync Server 2013 Edge Server : Edge Server Administration (part 2) - Assigning External Access Policies, Managing Federation
- Microsoft Lync Server 2013 Edge Server : Edge Server Administration (part 1) - Editing the Global External Access Policy, Creating a New External Access Policy
- Microsoft Lync Server 2013 Edge Server : Edge Server Configuration
- Packaging and Deploying Sharepoint 2013 Apps : Packaging and Publishing an App
- Packaging and Deploying Sharepoint 2013 Apps : Anatomy of an App (part 3) - Web Deploy Package, Database Package
- Packaging and Deploying Sharepoint 2013 Apps : Anatomy of an App (part 2) - Manifest and Assets, SharePoint Solution Package
- Packaging and Deploying Sharepoint 2013 Apps : Anatomy of an App (part 1)
 
 
Top 10
 
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 2) - Wireframes,Legends
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 1) - Swimlanes
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Formatting and sizing lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Adding shapes to lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Sizing containers
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 3) - The Other Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 2) - The Data Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 1) - The Format Properties of a Control
- Microsoft Access 2010 : Form Properties and Why Should You Use Them - Working with the Properties Window
- Microsoft Visio 2013 : Using the Organization Chart Wizard with new data
Technology FAQ
- Is possible to just to use a wireless router to extend wireless access to wireless access points?
- Ruby - Insert Struct to MySql
- how to find my Symantec pcAnywhere serial number
- About direct X / Open GL issue
- How to determine eclipse version?
- What SAN cert Exchange 2010 for UM, OA?
- How do I populate a SQL Express table from Excel file?
- code for express check out with Paypal.
- Problem with Templated User Control
- ShellExecute SW_HIDE
programming4us programming4us