Background
Lidarr changed its API protocol values from torrent/usenet to TorrentDownloadProtocol/UsenetDownloadProtocol in a recent release. The devopsarr/lidarr Terraform provider v1.13.0 (latest) cannot parse these new values on READ, causing every plan to fail with:
Error: Client Error
with lidarr_download_client_qbittorrent.qbittorrent
Unable to read download_client_qbittorrent, got error:
TorrentDownloadProtocol is not a valid DownloadProtocol
What was done
infrastructure/terraform/media/lidarr/download-client.tf was updated to use removed { lifecycle { destroy = false } } blocks for both download clients, dropping them from Terraform state without deleting them from Lidarr. The download clients (qBittorrent and NZBGet) remain configured and functional in Lidarr.
What needs to happen
Once devopsarr/terraform-provider-lidarr#255 is resolved and a new provider version is released:
- Update
main.tf provider version constraint to the fixed version
- Restore the resource blocks in
download-client.tf:
resource "lidarr_download_client_qbittorrent" "qbittorrent" {
name = "qBittorrent"
enable = true
priority = 1
host = "qbittorrent.download.svc.cluster.local"
port = 80
music_category = "music"
remove_completed_downloads = true
remove_failed_downloads = true
}
resource "lidarr_download_client_nzbget" "nzbget" {
enable = true
priority = 1
name = "NZBGet"
host = "nzbget.download.svc.cluster.local"
port = 80
music_category = "Music"
remove_completed_downloads = true
remove_failed_downloads = true
}
- Remove the
removed {} blocks
- Re-import the existing resources if needed
Background
Lidarr changed its API protocol values from
torrent/usenettoTorrentDownloadProtocol/UsenetDownloadProtocolin a recent release. Thedevopsarr/lidarrTerraform provider v1.13.0 (latest) cannot parse these new values on READ, causing every plan to fail with:What was done
infrastructure/terraform/media/lidarr/download-client.tfwas updated to useremoved { lifecycle { destroy = false } }blocks for both download clients, dropping them from Terraform state without deleting them from Lidarr. The download clients (qBittorrent and NZBGet) remain configured and functional in Lidarr.What needs to happen
Once devopsarr/terraform-provider-lidarr#255 is resolved and a new provider version is released:
main.tfprovider version constraint to the fixed versiondownload-client.tf:removed {}blocks