Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions resource/attribute.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,10 @@ type BoolAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.BoolValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -179,6 +183,10 @@ type DynamicAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.DynamicValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -218,6 +226,10 @@ type Float64Attribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.Float64Validators `json:"validators,omitempty"`
Expand Down Expand Up @@ -258,6 +270,10 @@ type Int64Attribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.Int64Validators `json:"validators,omitempty"`
Expand Down Expand Up @@ -298,6 +314,10 @@ type ListAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.ListValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -335,6 +355,10 @@ type ListNestedAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.ListValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -375,6 +399,10 @@ type MapAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.MapValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -412,6 +440,10 @@ type MapNestedAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.MapValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -452,6 +484,10 @@ type NumberAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.NumberValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -492,6 +528,10 @@ type ObjectAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.ObjectValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -532,6 +572,10 @@ type SetAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.SetValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -569,6 +613,10 @@ type SetNestedAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.SetValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -609,6 +657,10 @@ type SingleNestedAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.ObjectValidators `json:"validators,omitempty"`
Expand Down Expand Up @@ -645,6 +697,10 @@ type StringAttribute struct {
// be considered sensitive data.
Sensitive *bool `json:"sensitive,omitempty"`

// WriteOnly indicates that Terraform will not store
// this attribute value in the plan or state artifacts.
WriteOnly *bool `json:"write_only,omitempty"`

// Validators define types and functions that provide validation
// functionality for the block.
Validators schema.StringValidators `json:"validators,omitempty"`
Expand Down
44 changes: 43 additions & 1 deletion spec/v0.1/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -2324,6 +2324,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_bool_validators"
}
Expand Down Expand Up @@ -2373,6 +2376,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_dynamic_validators"
}
Expand Down Expand Up @@ -2422,6 +2428,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_float64_validators"
}
Expand Down Expand Up @@ -2471,6 +2480,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_int64_validators"
}
Expand Down Expand Up @@ -2523,6 +2535,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_list_validators"
}
Expand Down Expand Up @@ -2573,6 +2588,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_list_validators"
}
Expand Down Expand Up @@ -2669,6 +2687,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_map_validators"
}
Expand Down Expand Up @@ -2719,6 +2740,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_map_validators"
}
Expand Down Expand Up @@ -2769,6 +2793,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_number_validators"
}
Expand Down Expand Up @@ -2821,6 +2848,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_object_validators"
}
Expand Down Expand Up @@ -2874,6 +2904,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_set_validators"
}
Expand Down Expand Up @@ -2924,6 +2957,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_set_validators"
}
Expand Down Expand Up @@ -3020,6 +3056,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_object_validators"
}
Expand Down Expand Up @@ -3115,6 +3154,9 @@
"sensitive": {
"type": "boolean"
},
"write_only": {
"type": "boolean"
},
"validators": {
"$ref": "#/$defs/schema_string_validators"
}
Expand Down Expand Up @@ -3698,4 +3740,4 @@
"pattern": "^[a-z_][a-z0-9_]*$"
}
}
}
}