How did I install Varnish 6.4 to Debian 10?

I have found the solution here:

Step 1

I removed an outdated (6.1.1) Varnish version provided by the official Debian repository:

aptitude remove varnish

Step 2

aptitude update
aptitude install debian-archive-keyring
aptitude install curl gnupg apt-transport-https
curl -L | sudo apt-key add -

Step 3

I added to /etc/apt/sources.list:

deb buster main
deb-src buster main

Step 4

aptitude update
aptitude  install varnish=6.4.0-1~buster

Step 5

Checking the result:

varnishd -V


See also: How did I install Varnish 6.1 to Debian 10?