feat: add artifactapi_local_terraform resource type
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/pr/build Pipeline was successful
ci/woodpecker/pr/test Pipeline was successful

New resource for creating local terraform registries in ArtifactAPI
(repo_type=local, package_type=terraform). These repos host providers
directly rather than proxying an upstream registry.

Schema is minimal: just name and description — no upstream-specific
fields like base_url, caching TTLs, or auth.
This commit is contained in:
2026-06-22 23:30:21 +10:00
parent 7c94f06be6
commit 2653c34f94
6 changed files with 298 additions and 2 deletions
+3 -2
View File
@@ -66,8 +66,8 @@ func TestProvider_Resources(t *testing.T) {
p := &ArtifactAPIProvider{version: "1.0.0"}
resources := p.Resources(context.Background())
// 10 remote resource types + 1 virtual = 11
expectedCount := 11
// 10 remote resource types + 1 virtual + 1 local_terraform = 12
expectedCount := 12
if len(resources) != expectedCount {
t.Fatalf("expected %d resources, got %d", expectedCount, len(resources))
}
@@ -107,6 +107,7 @@ func TestProvider_Resources_ContainsExpectedTypes(t *testing.T) {
"artifactapi_remote_terraform",
"artifactapi_remote_goproxy",
"artifactapi_virtual",
"artifactapi_local_terraform",
}
for _, name := range expected {