Web PI Extensibility: Custom Feeds – Installing Custom Applications
One of the most important features of Web Platform Installer, version 2 RTW of which released in September, is that it surfaces web applications offered by Windows Web App Gallery. The Gallery is the place for open source apps that can be submitted through online submission process and be available through various sources, including Web PI, to millions of people. Both submission and admission is totally free, the application just needs to adhere to App Gallery Principles and be a Web Deploy zip package.
However, you don’t need to submit an app to the App Gallery to make Web PI install it for you. With a new feature that version 2 comes with – extensibility – deploying your custom application via Web PI becomes a piece of cake. This article will show you how to create a custom feed for Web PI to recognize your application and be able to install it.
All you need to start with this article is a Web Deploy zip package of your app and (optionally) an icon for the prettier UI display of your app.
Let the fun begin!
The feed below represents an example of how to add applications with ASP.NET/SQL and PHP/MySql dependencies, create a new tab and subtabs based on keywords, group products together and hint Web PI that your product is available in different languages. Please note that you have to define a new custom tab for your custom products, since they cannot be added to Web PI core tabs.
You can also download this feed from here or add it to Web PI by specifying this link: http://blogs.iis.net/blogs/kateroh/WebPI/SampleCustomAppsFeed.xml
<?xml version="1.0" encoding="utf-8"?> <feed xmlns="http://www.w3.org/2005/Atom"> <version>1.0.0</version> <title>Sample Applications for WebPI v2 RTW Feed</title> <link href="http://www.contoso.com/SampleApplicationsFeed.xml" /> <updated>2009-10-5T16:30:00Z</updated> <author> <name>Sample Application Builder</name> <uri>http://www.contoso.com/</uri> </author> <id>http://www.contoso.com/SampleApplicationsFeed.xml</id> <!-- Sample ASP.NET & SQL app with dependencies --> <entry type="application"> <productId>Sample_ASPNET_SQL_App</productId> <title>Sample ASP.NET and SQL application</title> <summary>ASP.NET and SQL application sample</summary> <longSummary>Sample ASP.NET and SQL to show how to add a feed with a custom ASP.NET application to WebPI and define all dependencies.</longSummary> <!-- Defines grouping for the application based on the keyword(s) --> <keywords> <keywordId>ASPNETApps</keywordId> </keywords> <version>1.0</version> <images> <icon>c:\SampleASPNETAppIcon.jpg</icon> </images> <updated>2009-10-5T18:30:02Z</updated> <published>2009-10-5T18:30:02Z</published> <author> <name>Sample Application Builder</name> <uri>http://www.contoso.com</uri> </author> <!-- Bring along SQLExpress, if it is not installed as a related/nice-to-have product, not a dependency --> <related> <relatedProduct> <productId>SQLExpress</productId> </relatedProduct> </related> <!-- Minimum set of requirements/dependencies in order to successfully install the application: WDeploy, SQL Management Objects and URL Rewrite. --> <dependency> <and> <dependency> <productId>SMO</productId> </dependency> <dependency> <productId>WDeployNoSMO</productId> </dependency> <dependency> <productId>UrlRewrite2</productId> </dependency> </and> </dependency> <!-- Installer for an application should be Web Deploy package --> <installers> <installer> <id>1</id> <!-- List of languages this package is localized in: English, Korean, Spanish, Traditional and Simplified Chinese --> <languageId>en</languageId> <languageId>ko</languageId> <languageId>es</languageId> <languageId>zh-tw</languageId> <languageId>zh-cn</languageId> <installerFile> <!-- size of the package in KBs --> <fileSize>1024</fileSize> <installerURL>http://www.contoso.com/SampleASPNETApplication.zip</installerURL> <displayURL>http://www.contoso.com/SampleASPNETApplication.aspx</displayURL> <!-- SHA of the package file for signature verification --> <sha1>1223334444555556666667777777888888889999</sha1> </installerFile> <helpLink>http://www.contoso.com/SampleASPNETApplicationForum.aspx</helpLink> <msDeploy> <startPage> <!-- start with a setup page rather than a default one --> <startPage>Setup.aspx</startPage> </startPage> </msDeploy> </installer> </installers> </entry> <!-- Sample PHP & MySQL app with dependencies --> <entry type="application"> <productId>Sample_PHP_MySQL_App</productId> <title>Sample PHP and and MySQL application</title> <summary>PHP and MySQL application sample</summary> <longSummary>Sample PHP and MySQL to show how to add a feed with a custom PHP application to WebPI and define all dependencies.</longSummary> <!-- Display under PHPApps keyword subtab --> <keywords> <keywordId>PHPApps</keywordId> </keywords> <version>1.0</version> <images> <icon>c:\SamplePHPAppIcon.jpg</icon> </images> <updated>2009-10-5T18:30:02Z</updated> <published>2009-10-5T18:30:02Z</published> <author> <name>Sample Application Builder</name> <uri>http://www.contoso.com</uri> </author> <!-- Bring along SQLExpress, if it is not installed as a related/nice-to-have product, not a dependency --> <related> <relatedProduct> <productId>SQLExpress</productId> </relatedProduct> </related> <!-- Minimum set of requirements/dependencies in order to successfully install the application: PHP, WDeploy, SQL Management Objects, MySql Connector and URL Rewrite. --> <dependency> <and> <dependency> <productId>WDeployNoSMO</productId> </dependency> <dependency> <productId>PHP</productId> </dependency> <dependency> <productId>MySQLConnector</productId> </dependency> <dependency> <productId>UrlRewrite2</productId> </dependency> </and> </dependency> <!-- Installer for an application should be Web Deploy package --> <installers> <installer> <id>1</id> <!-- List of languages this package is localized in: English, Russian, French, German and Italian --> <languageId>en</languageId> <languageId>ru</languageId> <languageId>fr</languageId> <languageId>de</languageId> <languageId>it</languageId> <installerFile> <!-- size of the package in KBs --> <fileSize>1024</fileSize> <installerURL>http://www.contoso.com/SamplePHPApplication.zip</installerURL> <displayURL>http://www.contoso.com/SamplePHPApplication.aspx</displayURL> <!-- SHA of the package file for signature verification --> <sha1>1223334444555556666667777777888888889999</sha1> </installerFile> <helpLink>http://www.contoso.com/SamplePHPApplicationForum.aspx</helpLink> <msDeploy> <!-- Default page is a start page --> <startPage /> </msDeploy> </installer> </installers> </entry> <!-- Tab definition --> <tabs> <tab> <keywordTab> <id>SampleApplications</id> <name>Sample Applications</name> <description>Select from sample applications:</description> <!-- Subtabs definitions --> <keywords> <keywordId>ASPNETApps</keywordId> <keywordId>PHPApps</keywordId> </keywords> </keywordTab> </tab> </tabs> <!-- Keyword/titles of subtabs to group apps with those keywords under --> <keywords> <keyword id="ASPNETApps">ASP.NET Apps</keyword> <keyword id="PHPApps">PHP Apps</keyword> </keywords> </feed>
You can get a hash of your zip package, by using a free utility called File Checksum Integrity Verifier (FCIV) and running fciv.exe –sha <path to your zip package> from the command prompt.
Now, you can try the feed out by saving it locally or uploading it, opening the Options dialog and adding a feed through either a physical path or URL.
Note how applications are grouped based on keywords rather than product families like products do. Also, applications are grouped into keyword subtabs rather than group boxes (pillars for products). To read about adding a custom product through a custom feed refer to this article - Web PI Extensibility: Custom Feeds – Installing Custom Products.