locked
Wsp deployed to a single web application RRS feed

  • Question

  • Hello Experts,

    On my SharePoint farm we are having more than one web application.

    Using Visual web Part I have create WSP (farm trust level).

    I want to deploy wsp to a single web application

    Thanks in advance

    Thanks

    Abasaheb Dubal.


    Thanks & Regards, Abasaheb Dubal.

    Monday, December 17, 2012 6:53 AM

Answers

  • Hi

    The SharePoint Install-SPSolution cmdlet has a WebApplication attribute that you can use to specify a single web application.  Run the following 2 commands to perform the deployment:

    Add-SPSolution -LiteralPath <path to your wsp>
    
    Install-SPSolution -Identity <your solution.wsp> -WebApplication <name or guid of your web application> -GacDeployment
    


    Kind Regards

    Bjoern
    http://spviking.com
    Twitter: Follow @bjoern_rapp

    • Proposed as answer by Gnanasekhar Monday, December 17, 2012 9:53 AM
    • Marked as answer by Kelly Chen 2012 Monday, December 24, 2012 9:31 AM
    Monday, December 17, 2012 9:08 AM

All replies

  • 1. you can create a sandbox solution and deploy it to specific web application.

    2. if you cannot convert it into sandbox solution and need globally deployed, create feature scoped at web application level, or have feature dependency so that you can validate the activation accordingly.

    Check this out it might give an insight for what you want http://stackoverflow.com/questions/4086460/creating-a-solution-that-deploys-to-selected-webapplications-but-copies-the-asse/4165281#4165281


    Raghavendra Shanbhag | Blog: www.SharePointColumn.com
    Please click "Propose As Answer " if a post solves your problem or "Vote As Helpful" if a post has been useful to you.
    Disclaimer: This posting is provided "AS IS" with no warranties.

    Monday, December 17, 2012 7:27 AM
  • Hi

    The SharePoint Install-SPSolution cmdlet has a WebApplication attribute that you can use to specify a single web application.  Run the following 2 commands to perform the deployment:

    Add-SPSolution -LiteralPath <path to your wsp>
    
    Install-SPSolution -Identity <your solution.wsp> -WebApplication <name or guid of your web application> -GacDeployment
    


    Kind Regards

    Bjoern
    http://spviking.com
    Twitter: Follow @bjoern_rapp

    • Proposed as answer by Gnanasekhar Monday, December 17, 2012 9:53 AM
    • Marked as answer by Kelly Chen 2012 Monday, December 24, 2012 9:31 AM
    Monday, December 17, 2012 9:08 AM