Locking down a deploy key used to mean listing every restriction by hand: no-port-forwarding, no-agent-forwarding, no-X11-forwarding, no-pty, no-user-rc. Any option added to a later OpenSSH release was permitted until someone updated the file, so the deny list silently weakened over time.
OpenSSH 7.2, released in February 2016, added 'restrict', which disables all forwarding and pty allocation and is defined to include future restrictions automatically. Individual capabilities can then be re-enabled after it, so 'restrict,pty' grants a terminal and nothing else, and the order matters because later options override earlier ones on the same line.
Combine it with 'command=' to force a single program regardless of what the client requests, and with 'from=' to limit the source addresses. A typical backup key line begins 'restrict,command="/usr/local/bin/backup-receive",from="203.0.113.0/24"'. Check that the server honours it by connecting and confirming that port forwarding is refused; sshd logs the reason at LogLevel VERBOSE.