For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Open sourceSupportFAQsDocs Home
DocumentationCommand referenceRelease notes
DocumentationCommand referenceRelease notes
  • Command reference
    • iagctl cert-gen
    • iagctl completion
      • hostkeys add
      • hostkeys clear
      • hostkeys remove
      • hostkeys scan
    • iagctl login
    • iagctl runner
    • iagctl server
    • iagctl version
LogoLogo
Open sourceSupportFAQsDocs Home
On this page
  • Syntax
  • Examples
  • Scan a single host
  • Scan multiple hosts
  • Replace mismatched fingerprints
  • Options
  • Options inherited from parent commands
Command referenceiagctl hostkeys

iagctl hostkeys scan

Was this page helpful?
Previous

iagctl inspect cluster

Next
Built with

Scan hosts for their host keys.

The iagctl hostkeys scan command scans one or more hosts for their host keys using the ssh-keyscan utility and adds any keys it finds to the gateway known_hosts file. The known_hosts file is located in the application working directory set by the GATEWAY_APPLICATION_WORKING_DIR configuration variable.

Syntax

$iagctl hostkeys scan <host_or_list_of_hosts> [flags]

Examples

Scan a single host

The following example scans 10.0.0.1 for its host keys and adds them to the gateway known_hosts file:

$iagctl hostkeys scan 10.0.0.1

Scan multiple hosts

The following example scans 10.0.0.1 and 10.0.0.2 for their host keys:

$iagctl hostkeys scan 10.0.0.1 10.0.0.2

Replace mismatched fingerprints

If a host/key type combination already exists but has a different fingerprint, use --replace to update the key. Without --replace, the command returns an error for the mismatch:

$iagctl hostkeys scan 10.0.0.1 --replace

Options

$ -h, --help Help for scan
$ --replace Replace keys with the same host/key type combination but a different fingerprint, instead of returning an error.

Options inherited from parent commands

$ --profile string Specify the client profile to use (case-insensitive, defaults to [client] section)
$ --config string Path to the configuration file
$ --raw Display the result of the command in raw format
$ --verbose Enable verbose output