Copied to clipboard

Flag this post as spam?

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


  • Bradley Petersen 3 posts 92 karma points
    Dec 17, 2022 @ 19:15
    Bradley Petersen
    0

    Issues publishing an Umbraco 9 website

    Hello Community, I hope you can help me.

    I've taken over the development of an umbraco site from a developer that no longer has the time to complete it.

    I've completed the site and am ready to publish it to production. I created a deployment profile that publishes to a folder.

    When I upload the site to the server, and browse to the domain, it asks me to install the application. I've copied over the Umbraco.mdf file into the /umbraco/Data/ folder but it's still asking me to install the website. I'm not sure what I'm doing wrong.

    if I run it from visual studio 2022, everything works fine, but not when I publish the site.

    Sites using Umbraco V9.5.4 and .Net Core 6.

    Any help/suggestions would be greatly appreciated.

    kind Regards

  • Bradley Petersen 3 posts 92 karma points
    Dec 19, 2022 @ 19:52
    Bradley Petersen
    100

    So I've managed to sort out the issue.

    I started by checking event viewer and found the following issue,

    "Cannot get a local application data path. Most probably a user profile is not loaded. If LocalDB is executed under IIS, make sure that profile loading is enabled for the current user."

    after a few hours of googling, coffee, and hair loss I've come across a few articles that kinda pointed me in the right direction.

    It boils down to when running the site under IIS with local DB, SQLCE has no user to attach to the DB (if that makes sense).

    What I had to do was set "Load User Profile" to true in the application pool for the Umbraco website. AppPoolSettings

    After that I had to change another setting in the applicationHost.config file located at C:\Windows\System32\inetsrv\config, please make a backup of this file before you make any changes.

    locate your site within that file and make the following changes.

    loadUserProfile="true" setProfileEnvironment="true"

    Apphost

    You need to restart IIS after making these changes.

    After a restart, copied the Db files and media files over, ran it, and all worked.

    I hope this will help someone.

    Regards

Please Sign in or register to post replies

Write your reply to:

Draft