"Run action as" on a custom action

Hi there,

I've created a custom action using C# to start and stop websites in IIS7. Problem is, the build user under which FB is running, isn't allowed to do this. Now I'd like to set a username and password for the action to run under, but the "execution properties" are disabled.

How can I turn them on and run my action under a different user?

Thanks,
Dennis

Hi Dennis,

You are correct that the "run user as" options only work for certain types of actions at the moment, and do not work for custom action types.

We should be able to add support for that feature in a future release. In the meantime, you may want to add your own "Username" and "Password" fields to the action, add properties to the action for "Username" and an encrypted version of the password, and use these to pass credentials to IIS 7.

(Alternatively, if you install the IIS 6 compatibility layer then you can use the IIS 6 actions in FB.)

Regards,

Angus

IIS6 actions don't allow me to use different credentials on a local IIS server. As the build user can't have access to IIS I can't get that to work.

I've looked around how to pass credentials to IIS7 but can't figure it out. I tried using impersonation but get the weirdest results there. So no luck until now. If you have any idea or suggestion, it's very appreciated.