I'm using TeamCity 8.x's EC2 plugin and Agent Push capability to create ubuntu build agents running in AWS EC2. These are created and destroyed on demand.
Is there a way to get custom content into the resulting build-agent's buildagent.properties file, so that, for example, it can know that ansible is installed and what version it is?
I'm looking for a way that this can be totally automated, but TeamCity (v8 at least) doesn't seem to provide any opportunity to customise the file, whether by supplying static content or whether by templating of some sort.
I suppose I could do it via a build itself - but then that would need to trigger off an event that TeamCity does not expose. It would need to happen every time the agent is created.
I could maybe do this by EC2 UserData - except TeamCity doesn't let me customise that.
I could attempt to do this via an on-startup task on the agent - except that would fire before the build-agent software itself is pushed onto the agent.
I suppose I could use incron, to wait for the file to exist before templating in my own content - but can anyone think of a different approach?