0
0
mirror of https://github.com/bpg/terraform-provider-proxmox.git synced 2025-07-05 05:24:01 +00:00

chore: cleanup and fix linter errors (#290)

This commit is contained in:
Pavel Boldyrev 2023-04-04 20:04:12 -04:00 committed by GitHub
parent ed3dfeae99
commit 2fa922930f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 21 deletions

View File

@ -1,10 +0,0 @@
requestsize:
enabled: true
language:
pullrequest: true
staleness:
pullrequest: true
path:
pullrequest: true
paths:
docs: 'documentation'

View File

@ -101,11 +101,13 @@ resource "proxmox_virtual_environment_vm" "example" {
] ]
} }
initialization { # While overwriting the initialization block when cloning a template is possible, it is not recommended.
dns { # This will cause the coned VM to be reinitialized each time on re-apply.
server = "8.8.8.8" # initialization {
} # dns {
} # server = "8.8.8.8"
# }
# }
} }

View File

@ -4,12 +4,6 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/. * file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/ */
/*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
package proxmoxtf package proxmoxtf
import ( import (

View File

@ -389,6 +389,7 @@ func mapToBaseRule(rule map[string]interface{}) *firewall.BaseRule {
return baseRule return baseRule
} }
func mapToSecurityGroupBaseRule(rule map[string]interface{}) *firewall.BaseRule { func mapToSecurityGroupBaseRule(rule map[string]interface{}) *firewall.BaseRule {
baseRule := &firewall.BaseRule{} baseRule := &firewall.BaseRule{}
@ -440,6 +441,7 @@ func baseRuleToMap(baseRule *firewall.BaseRule, rule map[string]interface{}) {
rule[mkRuleSPort] = *baseRule.SPort rule[mkRuleSPort] = *baseRule.SPort
} }
} }
func securityGroupBaseRuleToMap(baseRule *firewall.BaseRule, rule map[string]interface{}) { func securityGroupBaseRuleToMap(baseRule *firewall.BaseRule, rule map[string]interface{}) {
if baseRule.Comment != nil { if baseRule.Comment != nil {
rule[mkRuleComment] = *baseRule.Comment rule[mkRuleComment] = *baseRule.Comment

View File

@ -24,6 +24,7 @@ func FirewallRate() schema.SchemaValidateDiagFunc {
"Must be a valid rate expression, e.g. '1/second'", "Must be a valid rate expression, e.g. '1/second'",
)) ))
} }
func FirewallIFace() schema.SchemaValidateDiagFunc { func FirewallIFace() schema.SchemaValidateDiagFunc {
return validation.ToDiagFunc(validation.StringMatch( return validation.ToDiagFunc(validation.StringMatch(
ifaceExpression, ifaceExpression,