Page cover

record-update

The dns record-update command updates an existing DNS record in a specific DNS zone. This command requires the DNS zone ID, record ID, and updated record details.

Usage

cldkctl dns record-update [zone_id] [record_id] [flags]

Steps

Follow the steps below to run and view the result of this command:

  1. A DNS record can be updated by running the command with flags:

cldkctl dns record-update [dns-zone-id] [record-id] --type [record-type] --name [record-name] --content [record-content] --ttl [record-ttl]
  1. Replace [dns-zone-id] with the ID of the DNS zone. Refer to dns list section to obtain the DNS zone ID.

  2. Replace [record-id] with the ID of the DNS record. Refer to dns record-list section to obtain the record ID.

  3. Replace [record-type] with the DNS record type.

  4. Replace [record-name] with the record name.

  5. Replace [record-content] with the record value.

  6. Replace [record-ttl] with the desired TTL (time to live) value.

  7. Or alternatively, run the command without flags to update a DNS record interactively using TUI mode:

cldkctl dns record-update [dns-zone-id] [record-id]
  1. The Type field displays the current DNS record type.

  2. The Name field allows editing of the DNS record name.

  3. The IPv4 Address (or record content) field allows editing of the record value.

  4. The TTL field allows editing of the record’s time to live value.

  1. Confirm the record update by pressing y for Confirm or n for Cancel.

  1. Once completed successfully, a message “✓ DNS record updated successfully!” will appear in the terminal.

Flags

This command supports global flags. Refer to the Global Flags section for details.

Flag
Description

-c, --content string

DNS record content.

-h, --help

Help for dns record create command.

-n, --name string

DNS record name.

--ttl int

DNS record TTL (time to live) (default 86400).

-t, --type string

DNS record type.

Last updated