From a5682e7991ac0b1cfa38ffd435f05ee4a56845fa Mon Sep 17 00:00:00 2001 From: flbla Date: Mon, 21 Aug 2023 15:40:30 +0200 Subject: [PATCH] fix : #360/#361 : import config system and config auth Signed-off-by: flbla --- provider/resource_config_auth.go | 6 ++++++ provider/resource_config_system.go | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/provider/resource_config_auth.go b/provider/resource_config_auth.go index 45d514d5..461e2883 100644 --- a/provider/resource_config_auth.go +++ b/provider/resource_config_auth.go @@ -161,6 +161,12 @@ func resourceConfigAuth() *schema.Resource { Read: resourceConfigAuthRead, Update: resourceConfigAuthCreate, Delete: resourceConfigAuthDelete, + Importer: &schema.ResourceImporter{ + State: func(d *schema.ResourceData, m interface{}) ([]*schema.ResourceData, error) { + resourceConfigAuthRead(d, m) + return []*schema.ResourceData{d}, nil + }, + }, } } diff --git a/provider/resource_config_system.go b/provider/resource_config_system.go index 2ce5b0b6..f7e28403 100644 --- a/provider/resource_config_system.go +++ b/provider/resource_config_system.go @@ -42,6 +42,12 @@ func resourceConfigSystem() *schema.Resource { Read: resourceConfigSystemRead, Update: resourceConfigSystemCreate, Delete: resourceConfigSystemDelete, + Importer: &schema.ResourceImporter{ + State: func(d *schema.ResourceData, m interface{}) ([]*schema.ResourceData, error) { + resourceConfigSystemRead(d, m) + return []*schema.ResourceData{d}, nil + }, + }, } }