Header

Reset a server's stored host key (SSH only)

This method allows you to automate resetting a host key on a particular SSH server.

URL

/project/<project>/servers/<identifier>/reset_host_key
  • Replace <project> with the permalink of the project.
  • Replace <identifier> with the identifier of the server.

HTTP Method

POST

Supported Parameters

None

Example cURL Request

curl -H "Content-type: application/json" \
-H "Accept: application/json" \
--user adam@atechmedia.com:my-api-key \
https://atech.deployhq.com/projects/adam-s-test-project/servers/12341234-5678-5678-12341234/reset_host_key

Example Response

{
  "id":884734,
  "identifier":"12341234-5678-5678-12341234",
  "name":"server",
  "protocol_type":"ssh",
  "server_path":"/home/adam/myserver",
  "last_revision":"eef3b8abaf7a4d63be748d763076dfda6a5d784f",
  "preferred_branch":"master",
  "branch":"",
  "notify_email":"",
  "server_group_identifier":nil,
  "auto_deploy":false, 
  "hostname":"my.server.io",
  "username":"adam",
  "port":"22",
  "use_ssh_keys":true,
"host_key":nil,
  "unlink_before_upload":false
}

Proudly powered by Katapult. Running on 100% renewable energy.