Changes

From Amahi Wiki
Jump to: navigation, search
42 bytes removed ,  02:23, 8 August 2019
==== Create the htpasswd File ====
There are two options for creating the <code>htpasswd</code> file:
*Option 1: Navigate to [http://www.webmaster-toolkithtaccesstools.com/htaccesshtpasswd-generator.shtml .htaccess / htpasswd Generator].
<blockquote>
*Enter desired Username, Password, and Path (physical location where <code>.htpasswd</code> will be stored). For example, Username '''''amahi''''', Password '''''amahi''''', and Path '''''/var/hda/web-apps'''''.
==== User Maintenance (Add/Delete) ====
*Add additional users, repeat the previous step ('''NOTE:''' the -c option is only needed the first time you create the file for that web application):
{{Code| htpasswd -b /var/hda/web-apps/htpasswd username password}}
*Delete a user, do the following:
{{Code|htpasswd -D /var/hda/web-apps/htpasswd username}}
==== Copy and Set File permissions: ====
*Copy the <code>.htpasswd</code> file to the web application directory:
{{Code| cp .htpasswd /var/hda/web-apps/htpasswd}}
* Ensure the permissions are correctly set on the two files as follows:
{{Code| chmod 600 /var/hda/web-apps/htpasswd chown apache:apache /var/hda/web-apps/htpasswd}}
==== If you have Webmin installed ====
12,424

edits