You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* feat: add minimum provider version check for v4→v5 migrations
Add validation to ensure users are running Cloudflare Provider v4.52.5 or higher
before attempting v4→v5 migrations. This version introduced critical state
migration capabilities required for tf-migrate to work correctly.
Features:
- Check .terraform.lock.hcl for installed provider version (primary)
- Fallback to required_providers version constraint in .tf files
- Block migration with clear error messages if version < 4.52.5
- Add --skip-version-check flag for testing/CI scenarios
- Update integration tests to use --skip-version-check
Files changed:
- cmd/tf-migrate/version_check.go (new)
- cmd/tf-migrate/version_check_test.go (new)
- cmd/tf-migrate/main.go
- integration/test_runner.go
- integration/v4_to_v5/phased_migration_test.go
- README.md
* fix e2e v4 version
migrateCmd.Flags().String("target-provider-version", "", "Explicit provider version to set in required_providers (e.g. 5.19.0-beta.3); skips GitHub API lookup")
runCmd.Flags().String("provider", "", "Path to provider source directory (will be built automatically)")
206
209
runCmd.Flags().Int("parallelism", 0, "Terraform parallelism for plan/apply (0 uses Terraform default)")
207
210
runCmd.Flags().Bool("no-refresh-snapshot", false, "Run an additional diagnostic terraform plan with -refresh=false before the authoritative refresh plan")
211
+
runCmd.Flags().String("target-provider-version", "", "Explicit provider version to set in required_providers (e.g. 5.19.0-beta.3); skips GitHub API lookup")
208
212
209
213
// Clean command flags
210
214
cleanCmd.Flags().String("modules", "", "Modules to remove from state (comma-separated)")
0 commit comments