Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Data Source/Resource: teamcity_agent_pool & teamcity_agent_pool_project_assignment #80

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

tombuildsstuff
Copy link
Contributor

@tombuildsstuff tombuildsstuff commented Apr 23, 2020

This PR includes a new Data Source & Resource for Agent Pools and a Resource for managing Agent Pool - Project assignments - which can be managed via:

data "teamcity_agent_pool" "test" {
  name = "Default"
}

resource "teamcity_agent_pool" "test" {
  name = "Example"
}

resource "teamcity_agent_pool_project_assignment" "test" {
  agent_pool_id                 = teamcity_agent_pool.test.id
  project_id                    = teamcity_project.test.id
  disassociate_from_other_pools = true
}

Dependent on cvbarros/go-teamcity#79 - but should compile & the tests pass once that's available 😄

```
$ TF_ACC=1 go test -v ./teamcity/ -run="(TestAccDataSourceAgentPool_Basic|TestAccTeamCityAgentPool_)"
=== RUN   TestAccDataSourceAgentPool_Basic
--- PASS: TestAccDataSourceAgentPool_Basic (0.12s)
=== RUN   TestAccTeamCityAgentPool_Basic
--- PASS: TestAccTeamCityAgentPool_Basic (0.20s)
=== RUN   TestAccTeamCityAgentPool_Complete
--- PASS: TestAccTeamCityAgentPool_Complete (0.22s)
PASS
ok  	github.com/cvbarros/terraform-provider-teamcity/teamcity	0.573s
```
This allows managing an assignment between an Agent Pool and a Project
@tombuildsstuff tombuildsstuff changed the title New Data Source/Resource: teamcity_agent_pool New Data Source/Resource: teamcity_agent_pool & teamcity_agent_pool_project_assignment Apr 24, 2020
@cvbarros cvbarros added this to the 1.1 milestone Apr 24, 2020
@cvbarros cvbarros modified the milestones: 1.1, 1.3 Jun 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants