formatter
This commit is contained in:
parent
d44323b049
commit
a78ead6b40
2 changed files with 3 additions and 57 deletions
54
help.txt
54
help.txt
|
|
@ -1,54 +0,0 @@
|
|||
Pedagogic html static file server
|
||||
|
||||
▌ 🛈 Informations
|
||||
▌
|
||||
▌ This is a complete Ansible playbook to configure Nginx with basic authentication using htpasswd.
|
||||
▌ This playbook installs Nginx, configures a static website, and secures access with basic authentication.
|
||||
▌
|
||||
▌ Steps:.
|
||||
▌
|
||||
▌ - Installation of Nginx: The playbook installs Nginx and ensures it is started and enabled.
|
||||
▌ - Creation of the website directory: A directory is created to host the website files.
|
||||
▌ - Creation of a simple homepage: A simple HTML page is created for the website.
|
||||
▌ - Installation of apache2-utils: This package is necessary to use the htpasswd command.
|
||||
▌ - Creation of the htpasswd file: A .htpasswd file is created with a username and password.
|
||||
▌ - Configuration of the Nginx site: The nginx_site.conf.j2 template is used to configure Nginx with basic authentication.
|
||||
▌ - Activation of the Nginx site: The site is enabled by creating a symbolic link in the sites-enabled directory.
|
||||
▌ - Testing the Nginx configuration: The Nginx configuration is tested before restarting the service.
|
||||
▌ - Restarting Nginx: Nginx is restarted to apply the changes.
|
||||
▌ Path: nginx
|
||||
|
||||
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
||||
┃ Variable ┃ Description ┃
|
||||
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
|
||||
│ nginx.domain_name │ Domain name. │
|
||||
│ domainname mandatory │ Validator: type domainname │
|
||||
│ │ Example: exemple.fr │
|
||||
├──────────────────────────────────────────────────────────────────────────────┼─────────────────────────────────────────────────────────────────────────────┤
|
||||
│ nginx.email │ Email for the domain name. │
|
||||
│ mail mandatory │ This is for certbot. │
|
||||
│ │ Example: contact@exemple.fr │
|
||||
├──────────────────────────────────────────────────────────────────────────────┼─────────────────────────────────────────────────────────────────────────────┤
|
||||
│ nginx.htpasswd_file │ Htpassword file. │
|
||||
│ UNIX filename mandatory │ Validator: file type allowed: "directory" and "file" │
|
||||
│ │ Default: /etc/nginx/.htpasswd │
|
||||
└──────────────────────────────────────────────────────────────────────────────┴─────────────────────────────────────────────────────────────────────────────┘
|
||||
users
|
||||
|
||||
▌ 🛈 Informations
|
||||
▌
|
||||
▌ This family contains lists of variable blocks.
|
||||
▌ Path: nginx.users
|
||||
|
||||
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
|
||||
┃ Variable ┃
|
||||
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
|
||||
│ nginx.users.username │
|
||||
│ UNIX user multiple mandatory unique │
|
||||
├────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┤
|
||||
│ nginx.users.password │
|
||||
│ secret mandatory │
|
||||
└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
|
||||
|
||||
|
||||
|
||||
|
|
@ -27,11 +27,11 @@ nginx:
|
|||
|
||||
domain_name:
|
||||
description: domain name
|
||||
default:
|
||||
variable: __.vps_domain_name
|
||||
examples:
|
||||
- example.fr
|
||||
type: domainname
|
||||
default:
|
||||
variable: __.vps_domain_name
|
||||
|
||||
email:
|
||||
description: email for the domain name
|
||||
|
|
@ -43,10 +43,10 @@ nginx:
|
|||
htpasswd_file:
|
||||
description: htpassword user credential file name
|
||||
type: unix_filename
|
||||
default: /etc/nginx/.htpasswd
|
||||
params:
|
||||
types:
|
||||
- file
|
||||
default: /etc/nginx/.htpasswd
|
||||
|
||||
users:
|
||||
description: nginx authenticated user credentials
|
||||
|
|
|
|||
Loading…
Reference in a new issue