anchor.diff:  
   === TeamCity Environments Plugin
   
  -Applying this plugin provides tasks to download, install, start and stop a TeamCity Server and Build Agent.
  +Applying this plugin provides tasks to download, install, start and stop a local TeamCity Server and Build Agent or start and stop a server or agent using Docker.
   This allows a plugin to be debugged or tested against multiple versions of TeamCity.
   
   ==== Configuration
  
positive.code: * `stop<environment>Server` : Stops the TeamCity Server for the environment, requires the environment `homeDir` property to be defined.
  * `start<environment>Agent` : Starts the default TeamCity Build Agent for the environment, requires the environment `homeDir` property to be defined.
  * `stop<environment>Agent` : Stops the default TeamCity Build Agent for the environment, requires the environment `homeDir` property to be defined.
  * `install<environment>` : Downloads and installs TeamCity for the environment, this tasks uses the `downloadBaseUrl` and the environment `homeDir` properties.
  
  ==== Examples
  
  
negative.code: 
              register("teamcity2020.2") {
                  version = "2020.2.4"
              }
          }
      }
  ----
  
  ==== Using Docker
  
  To use Docker to start and stop a TeamCity Server and Build Agent an environment can be configured with
  the `useDocker()` function.
  
  [source,groovy]
  [subs="attributes"]
  .build.gradle
  ----
      teamcity {
          environments {
              'teamcity2021.2' {
                  version = '2021.2.3'
                  useDocker()
              }
          }
      }
  ----
  
  To start and stop a TeamCity Server and Build Agent using Docker requires Docker to be installed and running before
  the running the environment tasks. The start server task uses the image `{uri-docker-teamcity-server}[jetbrains/teamcity-server]`
  and the start agent task uses the image `{uri-docker-teamcity-agent}[jetbrains/teamcity-agent]`. The environment
  `version` property is used to select an image by tag. The start server and start agent tasks also set name of the
  containers to `teamcity-server` and `teamcity-agent`.
  
  The default image and container names can be overridden by providing additional configuration to the
  `useDocker` function as shown in the example below.
  
  [source,groovy]
  [subs="attributes"]
  .build.gradle
  ----
      teamcity {
          version = "{example-api-version}"
  
          environments {
              'teamcity2021.2' {
                  version = '2021.2.3'
                  useDocker {
                      serverImage = 'my-teamcity-server'
                      serverName = 'my-server'
                      agentImage = 'my-teamcity-agent'
                      agentName = 'my-agent'
                  }
              }
          }
      }
  