Add backup + optimisation code

This commit is contained in:
Erreur32 2024-07-12 13:18:30 +02:00
parent c6b9bb2982
commit 337231c258

View file

@ -123,12 +123,13 @@ usage() {
echo -e "\n${COLOR_YELLOW}Usage: $0 -d domain -i ip -p port [-f forward_scheme] [-s ssl_forced] [-c caching_enabled] [-b block_exploits] [-w allow_websocket_upgrade] [-h http2_support] [-a advanced_config] [-e lets_encrypt_agree] [-m lets_encrypt_email] [-n dns_challenge] [-t token_expiry] [--create-user username password] [--delete-user username] [--delete-host id] [--list-hosts] [--list-hosts-full] [--list-ssl-certificates] [--list-users] [--search-host hostname] [--enable-host id] [--disable-host id] [--check-token] [--backup] [--help]${COLOR_RESET}" echo -e "\n${COLOR_YELLOW}Usage: $0 -d domain -i ip -p port [-f forward_scheme] [-s ssl_forced] [-c caching_enabled] [-b block_exploits] [-w allow_websocket_upgrade] [-h http2_support] [-a advanced_config] [-e lets_encrypt_agree] [-m lets_encrypt_email] [-n dns_challenge] [-t token_expiry] [--create-user username password] [--delete-user username] [--delete-host id] [--list-hosts] [--list-hosts-full] [--list-ssl-certificates] [--list-users] [--search-host hostname] [--enable-host id] [--disable-host id] [--check-token] [--backup] [--help]${COLOR_RESET}"
echo "" echo ""
echo -e "Examples:" echo -e "Examples:"
echo -e " Backup First before do anything ;)"
echo -e " ./nginx_proxy_manager_cli.sh --backup"
echo -e " Host Creation" echo -e " Host Creation"
echo -e " ./nginx_proxy_manager_cli.sh -d example.com -i 192.168.1.10 -p 8080 -s true" echo -e " ./nginx_proxy_manager_cli.sh -d example.com -i 192.168.1.10 -p 8080 -s true"
echo -e " ./nginx_proxy_manager_cli.sh --create-user newuser password123" echo -e " ./nginx_proxy_manager_cli.sh --create-user newuser password123"
echo -e " ./nginx_proxy_manager_cli.sh --delete-user 'username'" echo -e " ./nginx_proxy_manager_cli.sh --delete-user 'username'"
echo -e " ./nginx_proxy_manager_cli.sh --list-hosts" echo -e " ./nginx_proxy_manager_cli.sh --list-hosts"
echo -e " ./nginx_proxy_manager_cli.sh --backup"
echo -e " Advanced example:" echo -e " Advanced example:"
echo -e " ./nginx_proxy_manager_cli.sh -d example.com -i 192.168.1.10 -p 8080 -a 'proxy_set_header X-Real-IP \$remote_addr; proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for;'" echo -e " ./nginx_proxy_manager_cli.sh -d example.com -i 192.168.1.10 -p 8080 -a 'proxy_set_header X-Real-IP \$remote_addr; proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for;'"
echo "" echo ""