JujuTF 2.2.0-rc1 release notes
21 July 2026
Requirements and compatibility
- This release requires a Juju controller of version 3 or higher. Support for Juju 2.9 controllers was dropped in the v2 track and remains unavailable here; 2.9 continues to be supported on the v1 track for security updates and bug fixes.
- If you are using JAAS, this release requires a Juju controller of version 3.6.5 or higher.
- This release builds against the Juju client API code from the Juju 4.0.12 release, and is compatible with both Juju 3 and Juju 4 controllers.
New features
Juju actions support
The headline feature of this release is first-class support for Juju actions. Charms expose actions — operational tasks such as backing up a database, rotating credentials, or fetching connection endpoints — and until now running them meant stepping outside of Terraform to the Juju CLI. This release brings actions into your Terraform plan, so operational steps can be declared, ordered, and their results consumed like any other piece of infrastructure.
-
juju_actionresource — run an action on an application (or a specific unit, including the<application>/leaderform) as part ofterraform apply. The action is enqueued and its result awaited during the resource’s creation, and the action’s output is exposed as a computed field that downstream resources can reference. Action arguments can be passed viaargs.- Implement
juju_actionresource by @SimoneDutto in #1297.
resource "juju_action" "action" { model_uuid = juju_model.development.uuid application_name = juju_application.traefik.name action_name = "show-proxied-endpoints" } # The action output can be used by other resources. For example, to # fetch a nested value from a JSON string result: locals { application_proxied_url = jsondecode(juju_action.action.output.proxied-endpoints)[juju_application.traefik.name].url } - Implement
-
juju_actiondata source — fetch the result of an action by its ID. This allows actions to be run outside of Terraform (for example, from the Juju CLI or by another plan) and their results consumed by other resources.data "juju_action" "action" { model_uuid = juju_model.development.uuid action_id = juju_action.action.action_id } -
unit_numbersexposed onjuju_application— the application resource now exposes the numbers of its deployed units, making it possible to fan an action out across every unit of an application.- Expose unit numbers for an application by @SimoneDutto in #1305.
See the new How to manage actions guide for the full workflow (Add actions documentation by @SimoneDutto in #1309).
Controller and model upgrades
Juju upgrades can now be driven from Terraform:
-
Controller patch upgrades — the
juju_controllerresource now supports in-place patch upgrades by changing itsagent_version.- Allow controller patch upgrades by @kian99 in #1240.
-
Model upgrades — the
juju_modelresource gains anagent_versionfield that tracks the model’s agent version; updating it (after the controller has been upgraded) triggers a model upgrade. Note thatagent_versioncannot be set at model creation time, and against Juju 4 controllers this feature requires Juju 4.0.12 or later.- Add model upgrade support by @kian99 in #1272.
resource "juju_model" "model" { name = "test-model" agent_version = "3.6.24" }
Secret backend management
-
juju_secret_backendresource — configure an external secret backend (for example, Vault) for your models. The backend configuration is a write-only field (config_wowith aconfig_wo_version), so sensitive values such as a Vault admin token are never stored in the Terraform state.- Add
secret_backendby @SimoneDutto in #1312.
resource "juju_secret_backend" "myvault" { name = "myvault" backend_type = "vault" config_wo = { endpoint = "http://10.0.0.1:8200" token = "myroot" } config_wo_version = 1 } resource "juju_model" "dev" { name = "dev" config = { secret-backend = juju_secret_backend.myvault.name } } - Add
Other enhancements
- Write-only secret values — the
juju_secretresource now supports avalue_wofield (with a companionvalue_wo_version), following the Terraform guidance on managing sensitive data, so secret values can be kept out of the Terraform state. Addwofield to secret resource for value by @ale8k in #1284. - IdP groups access (JAAS) — the
juju_jaas_access_*resources now support theidp_grouptag, allowing access to be granted to identity-provider groups. Note that an IdP group cannot be granted membership of a traditional JAAS group. Add IdP groups access by @kian99 in #1275.
Bug fixes
- Credentials and secret values are no longer logged — sensitive information (credentials and secret values) has been removed from provider log output. Stop logging credentials and secret values by @alesstimec in #1254.
- Fixed Juju CLI output parsing — resolved a regression (introduced by the logging fix above and present in v1.5.5) that broke the provider’s ability to read controller details from the local Juju CLI configuration, failing with
Username and password or client id and client secret must be set. Fix CLI output parsing by @kian99 in #1298.
Maintenance
- Documentation migration to canonical.com by @tmihoc in #1265 and #1286, with intersphinx URLs updated in #1289.
- Document how to use the controller model in a Juju deployment by @SimoneDutto in #1301.
- Backport K8s check for private registry Juju secret by @SimoneDutto in #1292.
- Merge v2.1 to main by @kian99 in #1311.
Full changelog: https://github.com/juju/terraform-provider-juju/compare/v2.1.1...v2.2.0