ADJ網路實驗室
打印

[介紹] 如何在Ubuntu下 安裝跟使用 htpasswd

如何在Ubuntu下 安裝跟使用 htpasswd

If you're trying to use nginx basic auth on a freshly installed Ubuntu server you might find out that you're missing this very important tool, htpasswd. If you're having trouble locating it, don't worry, here is the command you need to run in order to install it.

apt-get install apache2-utils

If you're not logged in as root add sudo in front of the command and you're done.
Here is an example command for using htpasswd for nginx:

htpasswd -c -d /path/to/file username





TOP

ARTERY.cn