views:

147

answers:

1

I've published my website many times. But didn't think about this though until I came across this issue. So I decided to publish my WAP project to a local folder on my C drive first. Then used FTP to upload it to my shared host on discountasp.net. I noticed during runtime that the stack trace was referencing that local folder still and erroring out.

Anyone know what config settings are affected when publishing? Obviously something is still pointing to my local C drive and I've searched my entire solution and don't see why.

Here's the runtime error I get when my code tries to run in discountasp.net's web server

 Cannot write into the public directory - check permissions
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: ScrewTurn.Wiki.PluginFramework.InvalidConfigurationException: Cannot write into the public directory - check permissions

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[InvalidConfigurationException: Cannot write into the public directory - check permissions]
   ScrewTurn.Wiki.SettingsStorageProvider.Init(IHostV30 host, String config) in C:\www\Wiki\Screwturn3_0_2_509\Core\SettingsStorageProvider.cs:90
   ScrewTurn.Wiki.StartupTools.Startup() in C:\www\Wiki\Screwturn3_0_2_509\Core\StartupTools.cs:69
   ScrewTurn.Wiki.Global.Application_BeginRequest(Object sender, EventArgs e) in C:\www\Wiki\Screwturn3_0_2_509\WebApplication\Global.asax.cs:29
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +68
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75

Discountasp says it's not a permission issue but obviously it is.

+3  A: 

The .pdb file is what's pointing to your local directory, that's not to say anything in the site is, that's an unrelated issue. Wherever the project was compiled ad the .pdb files created, those are the paths that will appear in the stack trace.

These directory entries have no bearing on where the application is actually deployed, it's mainly just so you can see where the class that errored out is located (and hopefully you as a developer can go "oh yeah, that damn class again"). If you posted the stack we may be able to help...but the fact that the directory points to your C:\ drive is nothing to worry about, this is absolutely normal.

Nick Craver
updated with the error so you can see what I'm talking about. The code is running or trying to run on discountasp.net host
CoffeeAddict
@coffeeaddict - You need to adjust the web.config a bit and point the public directory property to where it's installed like `/public`. See here for a full setup list for ScrewTurn and discountasp.net specifically: http://forum.discountasp.net/showthread.php?t=4889
Nick Craver
yea I read that too. But it is not going to be /public. In my case my root when I look at it in an FTP client is /webfoundnet. In my root is a folder called Wiki. So I've tried all sort of combintations like just "Wiki", "webfoundnet/Wikie", "/Wiki" and so on...
CoffeeAddict
@coffeeaddict - Looks like some people are using `<add key="PublicDirectory" value="..\_database\" />`, give it a go? I'm not familiar with exactly how you're deploying, so hard to guess.
Nick Craver
@coffeeaddict - I poked the discountasp.net forums a bit, they are usually very helpful for hosting issues, I use them for hosting as well :)
Nick Craver
thanks a lot for your help.
CoffeeAddict
@coffeeaddict - Welcome :) Glad you got it working
Nick Craver