Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • David Conlisk 430 posts 986 karma points
    Feb 05, 2013 @ 11:45
    David Conlisk
    0

    Installing Umbraco v6 using nuget fails

    Hi all,

    I'm not certain I'm going about this the right way, but I'm trying to install Umbraco 6 using nuget. Steps taken:

    1. VS2010, file -> new website -> asp.net empty website  - gives you a solution with a website with a web.config file in there. Delete it.

    2. Open Tools -> Library Package Manager -> Package Manager Console

    3. install-package umbracocms

    Here is the output (below). The web.config now looks like this (which is obviously incorrect):

    <?xml version="1.0"?>
    <configuration>
      <system.web>
        <compilation debug="false" targetFramework="4.0">
          <assemblies>
            <add assembly="Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Web.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Web.Helpers, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Web.WebPages, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Web.WebPages.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add assembly="System.Data.SqlServerCe, Version=4.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>
            <add assembly="System.Data.SqlServerCe.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91"/>
          </assemblies>
        </compilation>
      </system.web>
    </configuration>

    Thanks, 

    David

    nuget output:

    PM> install-package umbracocms
    Attempting to resolve dependency 'UmbracoCms.Core (≥ 6.0.0)'.
    Attempting to resolve dependency 'Microsoft.AspNet.Mvc (= 4.0.20710.0)'.
    Attempting to resolve dependency 'Microsoft.AspNet.WebPages (≥ 2.0.20710.0 && < 2.1)'.
    Attempting to resolve dependency 'Microsoft.Web.Infrastructure (≥ 1.0.0.0)'.
    Attempting to resolve dependency 'Microsoft.AspNet.Razor (≥ 2.0.20710.0 && < 2.1)'.
    Attempting to resolve dependency 'ServiceStack.Text (≥ 3.9.21)'.
    Attempting to resolve dependency 'Microsoft.AspNet.Mvc.FixedDisplayModes (≥ 1.0.0)'.
    Successfully installed 'Microsoft.Web.Infrastructure 1.0.0.0'.
    You are downloading Microsoft.AspNet.Razor from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/WebPages_2_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.
    Successfully installed 'Microsoft.AspNet.Razor 2.0.20715.0'.
    You are downloading Microsoft.AspNet.WebPages from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/WebPages_2_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.
    Successfully installed 'Microsoft.AspNet.WebPages 2.0.20710.0'.
    You are downloading Microsoft.AspNet.Mvc from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/MVC_4_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.
    Successfully installed 'Microsoft.AspNet.Mvc 4.0.20710.0'.
    Successfully installed 'ServiceStack.Text 3.9.35'.
    You are downloading Microsoft.AspNet.Mvc.FixedDisplayModes from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/mvc4extensions_prerelease_eula.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.
    Successfully installed 'Microsoft.AspNet.Mvc.FixedDisplayModes 1.0.0'.
    Successfully installed 'UmbracoCms.Core 6.0.0'.
    Successfully installed 'UmbracoCms 6.0.0'.
    Successfully added 'Microsoft.Web.Infrastructure 1.0.0.0' to Umbraco.
    Successfully added 'Microsoft.AspNet.Razor 2.0.20715.0' to Umbraco.
    Successfully added 'Microsoft.AspNet.WebPages 2.0.20710.0' to Umbraco.
    Successfully added 'Microsoft.AspNet.Mvc 4.0.20710.0' to Umbraco.
    Successfully added 'ServiceStack.Text 3.9.35' to Umbraco.
    Successfully added 'Microsoft.AspNet.Mvc.FixedDisplayModes 1.0.0' to Umbraco.
    Successfully added 'UmbracoCms.Core 6.0.0' to Umbraco.
    'Web.config' already exists. Skipping...
    Successfully added 'UmbracoCms 6.0.0' to Umbraco.
    Get-ChildItem : Cannot find path 'C:\Projects\Themebraco\config' because it does not exist.
    At C:\Projects\Umbraco\packages\UmbracoCms.6.0.0\tools\install.ps1:7 char:15
    +     Get-ChildItem <<<<  -path $configPath |
        + CategoryInfo          : ObjectNotFound: (C:\Projects\Themebraco\config:String) [Get-ChildItem], ItemNotFoundException
        + FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.GetChildItemCommand
     
    Copy-Item : Cannot find path 'C:\Projects\Themebraco\web.config' because it does not exist.
    At C:\Projects\Umbraco\packages\UmbracoCms.6.0.0\tools\install.ps1:18 char:11
    +     Copy-Item <<<<  $webConfigSource $webConfigDestination
        + CategoryInfo          : ObjectNotFound: (C:\Projects\Themebraco\web.config:String) [Copy-Item], ItemNotFoundException
        + FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.CopyItemCommand
     
    Failed to generate binding redirects for 'Umbraco'. An item with the same key has already been added.
    PM> 

  • jaygreasley 416 posts 402 karma points
    Feb 05, 2013 @ 11:59
    jaygreasley
    1

    it doesn't exactly help but I just tried the same on VS2012:

    PM>  install-package umbracocms

    Attempting to resolve dependency 'UmbracoCms.Core (≥ 6.0.0)'.

    Attempting to resolve dependency 'Microsoft.AspNet.Mvc (= 4.0.20710.0)'.

    Attempting to resolve dependency 'Microsoft.AspNet.WebPages (≥ 2.0.20710.0 && < 2.1)'.

    Attempting to resolve dependency 'Microsoft.Web.Infrastructure (≥ 1.0.0.0)'.

    Attempting to resolve dependency 'Microsoft.AspNet.Razor (≥ 2.0.20710.0 && < 2.1)'.

    Attempting to resolve dependency 'ServiceStack.Text (≥ 3.9.21)'.

    Attempting to resolve dependency 'Microsoft.AspNet.Mvc.FixedDisplayModes (≥ 1.0.0)'.

    Successfully installed 'Microsoft.Web.Infrastructure 1.0.0.0'.

    You are downloading Microsoft.AspNet.Razor from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/WebPages_2_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.

    Successfully installed 'Microsoft.AspNet.Razor 2.0.20715.0'.

    You are downloading Microsoft.AspNet.WebPages from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/WebPages_2_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.

    Successfully installed 'Microsoft.AspNet.WebPages 2.0.20710.0'.

    You are downloading Microsoft.AspNet.Mvc from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/MVC_4_eula_ENU.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.

    Successfully installed 'Microsoft.AspNet.Mvc 4.0.20710.0'.

    Successfully installed 'ServiceStack.Text 3.9.35'.

    You are downloading Microsoft.AspNet.Mvc.FixedDisplayModes from Microsoft, the license agreement to which is available at http://www.microsoft.com/web/webpi/eula/mvc4extensions_prerelease_eula.htm. Check the package for additional dependencies, which may come with their own license agreement(s). Your use of the package and dependencies constitutes your acceptance of their license agreements. If you do not accept the license agreement(s), then delete the relevant components from your device.

    Successfully installed 'Microsoft.AspNet.Mvc.FixedDisplayModes 1.0.0'.

    Successfully installed 'UmbracoCms.Core 6.0.0'.

    Successfully installed 'UmbracoCms 6.0.0'.

    Successfully added 'Microsoft.Web.Infrastructure 1.0.0.0' to Tester.

    Successfully added 'Microsoft.AspNet.Razor 2.0.20715.0' to Tester.

    Successfully added 'Microsoft.AspNet.WebPages 2.0.20710.0' to Tester.

    Successfully added 'Microsoft.AspNet.Mvc 4.0.20710.0' to Tester.

    Successfully added 'ServiceStack.Text 3.9.35' to Tester.

    Successfully added 'Microsoft.AspNet.Mvc.FixedDisplayModes 1.0.0' to Tester.

    Successfully added 'UmbracoCms.Core 6.0.0' to Tester.

    Successfully added 'UmbracoCms 6.0.0' to Tester.

  • David Conlisk 430 posts 986 karma points
    Feb 05, 2013 @ 12:15
    David Conlisk
    0

    Thanks Jay - so it was successful for you? What kind of project did you install into?

    The nuget gallery mentions "Visual Studio ASP.NET Webforms project" so I'm having a bit more luck with that, but I think the main issue is I'm missing MVC 4.

    I'll report back with more info. 

  • David Conlisk 430 posts 986 karma points
    Feb 05, 2013 @ 12:29
    David Conlisk
    0

    OK so now I tried installing using an MVC 4 Web Application project. Everything seems to have installed fine. However, attempting to browse to the site gives me the error below. 

    Any ideas on what I'm doing wrong here? Surely this should be pretty easy, i.e. install Umbraco using nuget into a brand new vs2010 solution?

    Thanks,

    David

     

    Server Error in '/' Application.


    Parser Error

    Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

    Parser Error Message: Could not load type 'Umbraco.Web.UmbracoApplication'.

    Source Error:

    Line 1: <%@ Application Codebehind="Global.asax.cs" Inherits="Umbraco.Web.UmbracoApplication" Language="C#" %> 


    Source File: /global.asax    Line: 1


    Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.272              

  • David Conlisk 430 posts 986 karma points
    Feb 05, 2013 @ 13:53
    David Conlisk
    100

    OK so I was right the second time - use an MVC 4 Web Application and ensure you have MVC 4 installed first ;)

    The missing step... is to build the project. Oops. I'd just set up a local url in IIS and pointed it at my website like I normally would, and that was giving me the global.asax error, above. Building first works a treat. Alternatively, just hit F5 in Visual Studio to build and run your site.

  • David Conlisk 430 posts 986 karma points
    Feb 05, 2013 @ 14:07
    David Conlisk
    1

    I just blogged the easy steps to installing Umbraco using nuget - easy when you know how!

    How to install Umbraco from scratch using nuget in visual studio

  • Stephen Davidson 216 posts 391 karma points
    May 07, 2013 @ 21:52
    Stephen Davidson
    0

    Much appreciated David, just about to ask the same question. Out of interest when a new version of Umbraco comes out can we update via Nuget directly.

    Trying to reach some kind of Umbraco Utopia where I can update the umbraco automagically to the latest version and, using continuous integration, deploy directly to my cloud host.

    I do this using GitHib and Azure on all my non umbraco projects and its works beautifully. 

    S

  • David Conlisk 430 posts 986 karma points
    May 30, 2013 @ 16:00
    David Conlisk
    0

    Not sure about that one Stephen I'm afraid. I haven't really used nuget with Umbraco apart from that time I was setting up from scratch.

Please Sign in or register to post replies

Write your reply to:

Draft