Getting UnauthorizedAccessException on application.config and trees.config
A couple of times I have installed Umbraco through nuget (VS2012) in a new empty MVC-project. Works like a charm, but when I check in to source control (TFS, sue me) I get two errors when running the site.
System.UnauthorizedAccessException on config/application.config and also on config/trees.config. If I remove the write-protection on theese files, everything works as expected.
Why do theese errors occur? Umbraco is not atempting to write to theese files when simply firering up the site, is it? Also, is there anything I can do to avoid this?
Getting UnauthorizedAccessException on application.config and trees.config
A couple of times I have installed Umbraco through nuget (VS2012) in a new empty MVC-project. Works like a charm, but when I check in to source control (TFS, sue me) I get two errors when running the site.
System.UnauthorizedAccessException on config/application.config and also on config/trees.config. If I remove the write-protection on theese files, everything works as expected.
Why do theese errors occur? Umbraco is not atempting to write to theese files when simply firering up the site, is it? Also, is there anything I can do to avoid this?
Yes it is. It's reflecting over all of the dlls to see if there's a tree/application attribute anywhere and then it updates the config file.
What you can do is not make these files read-only.
Ok. Thats fine really. Thanks.
is working on a reply...