Skip to content

Commit

Permalink
Deprecated message for embedded config and disk in linode_instance;…
Browse files Browse the repository at this point in the history
… remove depguard linter (linode#1019)
  • Loading branch information
zliang-akamai authored Sep 20, 2023
1 parent fa9603c commit 3746dfc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ linters:
- gocritic
- scopelint

# Not useful because we widely use open-source dependencies.
- depguard

# These ignores have been added to maintain compatibility with the existing codebase.
# These issues should be resolved at a later date.
- wrapcheck
Expand Down
9 changes: 7 additions & 2 deletions linode/instance/schema_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -456,8 +456,10 @@ var resourceSchema = map[string]*schema.Schema{
Elem: resourceConfigInterface(),
},
"config": {
Optional: true,
Computed: true,
Optional: true,
Computed: true,
Deprecated: "The embedded config is deprecated and scheduled to be removed in the next major version." +
"Please consider migrating it to linode_instance_config resource.",
Description: "Configuration profiles define the VM settings and boot behavior of the Linode Instance.",
Type: schema.TypeList,
ConflictsWith: []string{
Expand Down Expand Up @@ -642,6 +644,9 @@ var resourceSchema = map[string]*schema.Schema{
"image", "root_pass", "authorized_keys", "authorized_users", "swap_size",
"backup_id", "stackscript_id", "interface",
},
Deprecated: "The embedded disk block in linode_instance resource is deprecated and " +
"scheduled to be removed in the next major version. Please consider migrating " +
"it to be the linode_instance_disk resource.",
Type: schema.TypeList,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
Expand Down

0 comments on commit 3746dfc

Please sign in to comment.