Actually, after banging my head on this for a few days, and then
posting here, I had insight - the problem was that I needed to set the
execution policy at the user scope to be AllSigned.  In my testing, I
launched a shell and was testing in there having set the execution
policy.  It would last within that shell context but drop as soon as I
launched a new shell.  I didn't catch that until I exited the shell by
accident and tried it again.   Sorry for the noise all - nothing to do
with CCNet afterall.

On Nov 3, 2:15 pm, Dan Winsor <[email protected]> wrote:
> Hi all,
>
> I'm running CCNet 1.6.7981.1 as an application, not a service, on a
> Windows 7 64 bit machine with NAnt 0.86 and Powershell 2.0.  I'm
> porting a build environment based on WinXP, CCNet 1.4.4.83, NAnt 0.86,
> and Powershell 1.0.
>
> In short, I have a few situations where CCNet calls NAnt, which, in
> turn, self-signs and runs some powershell scripts.  In the older
> enviornment, everything works fine.  However in my new environment the
> ps1 files end up signed and can be run by hand, but when are run by
> CCNet, they invariably fail with:
>
> <script> cannot be loaded because the execution of scripts is disabled
> on this system. Please see "get-help about_signing" for more details.
>
> Since I'm running this as an app as the logged in user instead of a
> service, I'm not sure why this would be happening - the same user that
> can run it by hand should be the one running CCNet and therefore
> powershell and therefore have no problems with the signature.
>
> I realize this is a bit of a longshot, but short of allowing all
> scripts to run, does anyone have any suggestions I can try to debug
> what is going wrong here?
>
> Thanks very much in advance.
>
> --
> Dan Winsor
>
> Soy un poco loco en el coco.

Reply via email to