Add default agent pool and execution mode support to projects #1822
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Adds new resources to allow agent pools to be scoped to Projects, and to allow projects to declare a default execution mode and agent pool for their workspaces to use.
The new resources are:
tfe_agent_pool_allowed_projects
: maps anagent_pool_id
to a list of project IDs which are allowed to use that agent pooltfe_agent_pool_excluded_workspaces
: maps anagent_pool_id
to a list of workspace IDs which are explicitly not allowed to use that agent pool (even if they belong to a project which can)tfe_project_settings
: a new resource for managing the settings of a specific project, similar to thetfe_workspace_settings
resource. Initially, this just supports setting adefault_execution_mode
and adefault_agent_pool_id
. The resource exposes asetting_overwrites
block which describes whether these settings are being inherited from the org, or overwritten on the project.Also updates the
tfe_agent_pool
data source to expose the allowed project and excluded workspace IDs.Remember to:
Testing plan
External links
Include any links here that might be helpful for people reviewing your PR. If there are none, feel free to delete this section.
Output from acceptance tests
Rollback Plan
If problems are discovered before a release, we will revert the change
Changes to Security Controls
None