Homec4science

Cache generation of the SSH authentication keyfile for sshd

Authored by epriestley <git@epriestley.com> on Oct 21 2016, 16:23.

Description

Cache generation of the SSH authentication keyfile for sshd

Summary:
Ref T11469. This isn't directly related, but has been on my radar for a while: building SSH keyfiles (particular for installs with a lot of keys, like ours) can be fairly slow.

At least one cluster instance is making multiple clone requests per second. While that should probably be rate limited separately, caching this should mitigate the impact of these requests.

This is pretty straightforward to cache since it's exactly the same every time, and only changes when users modify SSH keys (which is rare).

Test Plan:

  • Ran bin/auth-ssh, saw authfile generate.
  • Ran it again, saw it read from cache.
  • Changed an SSH key.
  • Ran it again, saw it regenerate.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T11469

Differential Revision: https://secure.phabricator.com/D16744

Details

Committed
epriestley <git@epriestley.com>Oct 21 2016, 16:29
Pushed
aubortJan 31 2017, 17:16
Parents
rPHeb80f3fcd529: Fix policy capitalization
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHc21a71f02489: Cache generation of the SSH authentication keyfile for sshd (authored by epriestley <git@epriestley.com>).Oct 21 2016, 16:29