TeamCity API bindings
This is a simple wrapper around the TeamCity API.
Sample usage:
package main
import "github.com/ChrisMcKee/teamcity-go-sdk/teamcity"
func main() {
client := teamcity.New("myinstance.example.com", "username", "password")
b, err := client.QueueBuild("Project_build_task", "master", nil)
if err != nil {
fmt.Printf("You're outta luck: %s\n", err)
return
}
fmt.Printf("Build: %#v\n", b)
}
Teamcity Rest API Docs
Starting the Docker Container for Testing
- Change into the
test10
ortest9
depending on which version you are testing
docker-compose up teamcity10
Upgrading Teamcity
Test Data
When Upgrading from one version of Teamcity to Another the Test Data needs to be upgraded as well.
- Change into the
test10
ortest9
depending on which version you are upgrading - Update the docker-compose.yml and Dockerfile's to the new version of teamcity
- run
docker-compose pull
- run
docker-compose rm
cd ..
- run
docker-compose up teamcity10
- run
docker ps
find container ID
docker exec -it ${CONTAINER_ID} bash
cp -r /data/teamcity_server/datadir/config /test-data
cp -r /data/teamcity_server/datadir/system /test-data
Debugging Rest Calls on Teamcity
docker exec -it ${CONTAINER_ID} bash
tail -f /opt/teamcity/logs/teamcity-rest.log