“nginx: [warn] the “ssl” directive is deprecated, use the “listen … ssl” directive instead in example.com.nginx.ssl.conf“ See on veebiserverites levinud hoiatus vanade nginxi või Vestacp konfiguratsioonidega.
sisu
nginx -t

See Warn ilmub kõige sagedamini sevververil, kuhu on installitud mõni aasta tagasi, kui konfiguratsioon on nginx Direktiiv oli vajalik “ssl on“.
Kuidas parandada “ssl” direktiiv on aegunud NGINX / VestaCP -s
1. meetod. Domeeni faili redigeerimine nginx.conf
Kõige käepärasem on tühistada meid # direktiiviga “SSL peal” Valdkonna jaoks on meil Ningin Warn.
sudo nano /home/vestacpuser/conf/web/example.com.nginx.ssl.conf
# ssl on

Salvestame faili ja käivitame siis uuesti nginx -t. Viga nginx: [warn] the “ssl” directive is deprecated…” Seda enam ei ole.
nginx -t
Selle meetodi abil ei lahendata viga püsivalt. Uued väljad vastavad VestaCP -le määratud paketi konfiguratsioonifailile.
2. meetod. Redigeerimine VestaCP Web Template ninxi jaoks.
Enne kui lisame a kasutaja sisse Vestacp, Peame looma pakette. VestaCP Packages. Need paketid sisaldavad erinevate CMS -i või pühakirjade jaoks mitut konfiguratsiooni. Web Template (Nginx), Backend Template (PHP-FPM), DNS Template (NAMED).
Kui lisame a Valdkond ühe peal kasutaja vestacp, uue lisatud domeeni vaikekonfiguratsioon Ningini antakse Web Template (Nginx) valitud Kasutajapaketi jaoksto.

Võtame stsenaariumi, mille lisame Vesta Package Name: Stealth koos Web Template NGINX: wordpress2. Kui mall “wordpress2” Sisaldab direktiivi “ssl on”, on selle malliga lisatud uutel väljadel see aegunud direktiiv konfiguratsioonis. Nii et parim on SA modifitseerima Web Template sisse Vestacp. Nii et uued alad lisasid vastuvõtmise lõpetamiseks “SSL peal” Ninxi konfiguratsioonis.
Kui redigeeritud un Web Template VestaCP kõrvaldama “ssl” directive is deprecated” ?
Lisatud domeenide konfiguratsioonifaile kirjutavad mallid asuvad:
/usr/local/vesta/data/templates/web/nginx/php-fpm
Neil on kaks lõpetamist. .tpl jaoks Domeenid ilma SSL -iga Ja.stpl jaoks Domeenid, mille SSL on aktiveeritud.
[root@north php-fpm]# pwd
/usr/local/vesta/data/templates/web/nginx/php-fpm
[root@north php-fpm]# ls -all
total 224
drwxr-xr-x 2 root root 4096 Jul 3 23:51 .
drwxr-xr-x 3 root root 4096 Apr 25 2017 ..
-rwxr-xr-x 1 root root 1737 Feb 27 07:12 cms_made_simple.stpl
-rwxr-xr-x 1 root root 1638 Feb 27 07:12 cms_made_simple.tpl
-rwxr-xr-x 1 root root 1770 Feb 27 07:12 codeigniter2.stpl
-rwxr-xr-x 1 root root 1671 Feb 27 07:12 codeigniter2.tpl
-rwxr-xr-x 1 root root 6528 Feb 27 07:12 datalife_engine.stpl
-rwxr-xr-x 1 root root 6429 Feb 27 07:12 datalife_engine.tpl
-rwxr-xr-x 1 root root 1601 Feb 27 07:12 default.stpl
-rwxr-xr-x 1 root root 1502 Feb 27 07:12 default.tpl
-rwxr-xr-x 1 root root 2176 Feb 27 07:12 dokuwiki.stpl
-rwxr-xr-x 1 root root 2076 Feb 27 07:12 dokuwiki.tpl
-rwxr-xr-x 1 root root 2280 Feb 27 07:12 drupal6.stpl
-rwxr-xr-x 1 root root 2177 Feb 27 07:12 drupal6.tpl
-rwxr-xr-x 1 root root 2508 Feb 27 07:12 drupal8.stpl
-rwxr-xr-x 1 root root 2415 Feb 27 07:12 drupal8.tpl
-rwxr-xr-x 1 root root 1949 Feb 27 07:12 joomla.stpl
-rwxr-xr-x 1 root root 1850 Feb 27 07:12 joomla.tpl
-rwxr-xr-x 1 root root 1667 Feb 27 07:12 laravel.stpl
-rwxr-xr-x 1 root root 1562 Feb 27 07:12 laravel.tpl
-rwxr-xr-x 1 root root 5590 Feb 27 07:12 magento.stpl
-rwxr-xr-x 1 root root 5488 Feb 27 07:12 magento.tpl
-rwxr-xr-x 1 root root 1928 Feb 27 07:12 modx.stpl
-rwxr-xr-x 1 root root 1828 Feb 27 07:12 modx.tpl
-rwxr-xr-x 1 root root 2446 Feb 27 07:12 moodle.stpl
-rwxr-xr-x 1 root root 2411 Feb 27 07:12 moodle.tpl
-rwxr-xr-x 1 root root 1303 Feb 27 07:12 no-php.stpl
-rwxr-xr-x 1 root root 1204 Feb 27 07:12 no-php.tpl
-rwxr-xr-x 1 root root 1990 Feb 27 07:12 odoo.stpl
-rwxr-xr-x 1 root root 1891 Feb 27 07:12 odoo.tpl
-rwxr-xr-x 1 root root 1724 Feb 27 07:12 opencart.stpl
-rwxr-xr-x 1 root root 1624 Feb 27 07:12 opencart.tpl
-rwxr-xr-x 1 root root 2796 Feb 27 07:12 owncloud.stpl
-rwxr-xr-x 1 root root 2701 Feb 27 07:12 owncloud.tpl
-rwxr-xr-x 1 root root 2081 Feb 27 07:12 piwik.stpl
-rwxr-xr-x 1 root root 1982 Feb 27 07:12 piwik.tpl
-rw-r--r-- 1 root root 189 Feb 27 07:12 proxy_ip.tpl
-rwxr-xr-x 1 root root 2124 Feb 27 07:12 pyrocms.stpl
-rwxr-xr-x 1 root root 2021 Feb 27 07:12 pyrocms.tpl
-rwxr-xr-x 1 root root 2478 Feb 27 07:12 sendy.stpl
-rwxr-xr-x 1 root root 2390 Feb 27 07:12 sendy.tpl
-rwxr-xr-x 1 root root 1952 Feb 27 07:12 wordpress2_rewrite.stpl
-rwxr-xr-x 1 root root 1859 Feb 27 07:12 wordpress2_rewrite.tpl
-rwxr-xr-x 1 root root 1842 Feb 27 07:12 wordpress2.stpl
-rwxr-xr-x 1 root root 1743 Feb 27 07:12 wordpress2.tpl
-rwxr-xr-x 1 root root 2701 Feb 27 07:12 wordpress2_wp_super_cache.stpl
-rwxr-xr-x 1 root root 2596 Feb 27 07:12 wordpress2_wp_super_cache.tpl
-rwxr-xr-x 1 root root 1601 Feb 27 07:12 wordpress.stpl
-rwxr-xr-x 1 root root 1502 Feb 27 07:12 wordpress.tpl
[root@north php-fpm]#
Võtame ülaltoodud stsenaariumi, milles meil on mall “wordpress2.stpl”. Redigeerime seda faili veebiserveris ja kustutame rea direktiiviga “SSL peal”.
nano /usr/local/vesta/data/templates/web/nginx/php-fpm/wordpress2.stpl
Pärast liini eemaldamist “SSL peal” Mallilt salvestame faili. Järgmistel valdkondadel, mis selle malliga lisatakse, pole enam silmapaistvat direktiivi. “ssl” direktiiv on aegunud, Ningxi testimisel seda ei ilmu.
Samamoodi saab kõiki vestacpi veebimalle muuta või luua uusi, et lisada isikupärastatud NGINX ja PHP-FPM-i konfiguratsioonid.