JetBrains runAs plugin for TeamCity
This plugin provides the ability to run a build step under the specific windows user account.
How to Use It
The main purpose of the plugin is to provide isolation based on access rights of windows account.
All you need is to:
- Specify the configuration parameter "teamcity.agent.run_as_user" in the format: user_name or user_name@domain or domain\user_name.
- Specify the configuration parameter "teamcity.agent.run_as_password".
- The user account should have the foollowing list of rights:
- Read/write access to "temp" directories on the each agent
- Read/write access to the "checkout" directory on the each agent
- ... will be specified
That's it! Once the build is run, the plugin runs all commands under the specific account.
Install
To install the plugin, put the zip archive to 'plugins' direrctory under TeamCity data directory. Restart the server.
Implemention
This project contains 3 modules: 'runAs-server', 'runAs-agent' and 'runAs-common'. They contain code for server and agent parts and a common part, available for both (agent and server). When implementing components for server and agent parts, do not forget to update spring context files under 'main/resources/META-INF'. See TeamCity documentation for details on plugin development.
Build
To build this plugin you should have following:
- Visual Studio 2015 or Microsoft Build Tools 2015
- Mictosoft .Net framework 2
- Mictosoft .Net framework 4 or above
Use 'build.cmd' to build your plugin. Resulting package 'runAs.zip' will be placed in root directory. The build is configured on the JetBrains TeamCity build server.
License
JetBrains runAs plugin for TeamCity is under the Apache License.