Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Fix] Make secret optional for TSIG Key #17

Merged
merged 9 commits into from
Jan 23, 2025
3 changes: 1 addition & 2 deletions src/dns_config/models/host.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@ class Host(BaseModel):
default=None, description="Host FQDN in punycode.")
provider_id: Optional[StrictStr] = Field(
default=None, description="External provider identifier.")
server: Optional[StrictStr] = Field(default=None,
description="The resource identifier.")
server: Optional[StrictStr] = Field(description="The resource identifier.")
site_id: Optional[StrictStr] = Field(default=None,
description="Host site ID.")
tags: Optional[Dict[str,
Expand Down
4 changes: 1 addition & 3 deletions src/dns_data/models/record.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,7 @@ class Record(BaseModel):
default=None, description="The inheritance configuration.")
ipam_host: Optional[StrictStr] = Field(
default=None, description="The resource identifier.")
name_in_zone: Optional[StrictStr] = Field(
default=None,
description=
name_in_zone: Optional[StrictStr] = Field(description=
"The relative owner name to the zone origin. Must be specified for creating the DNS resource record and is read only for other operations."
)
options: Optional[Dict[str, Any]] = Field(
Expand Down
2 changes: 1 addition & 1 deletion src/keys/docs/TSIGKey.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Name | Type | Description | Notes
**id** | **str** | The resource identifier. | [optional] [readonly]
**name** | **str** | The TSIG key name in the absolute domain name format. |
**protocol_name** | **str** | The TSIG key name supplied during a create/update operation that is converted to canonical form in punycode. | [optional] [readonly]
**secret** | **str** | The TSIG key secret as a Base64 encoded string. |
**secret** | **str** | The TSIG key secret as a Base64 encoded string. | [optional]
**tags** | **object** | The tags for the TSIG key in JSON format. | [optional]
**updated_at** | **datetime** | Time when the object has been updated. Equals to _created_at_ if not updated after creation. | [optional] [readonly]

Expand Down
3 changes: 2 additions & 1 deletion src/keys/models/tsig_key.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ class TSIGKey(BaseModel):
description=
"The TSIG key name supplied during a create/update operation that is converted to canonical form in punycode."
)
secret: StrictStr = Field(
secret: Optional[StrictStr] = Field(
default=None,
mathewab marked this conversation as resolved.
Show resolved Hide resolved
description="The TSIG key secret as a Base64 encoded string.")
tags: Optional[Dict[str, Any]] = Field(
default=None, description="The tags for the TSIG key in JSON format.")
Expand Down
Loading