“nginx: [warn] the “ssl” directive is deprecated, use the “listen … ssl” directive instead in example.com.nginx.ssl.conf“ adalah peringatan umum di server web dengan konfigurasi nginx lama atau VestaCP.
Cuprin
nginx -t

ini warn paling sering muncul di server yang memiliki VestaCP diinstal beberapa tahun yang lalu, ketika dalam konfigurasi nginx arahan diperlukan"ssl on
".
Bagaimana cara memperbaiki "arahan ssl" tidak digunakan lagi di Nginx / VestaCP
Metode 1. Edit file nginx.conf untuk lapangan
Cara termudah adalah dengan membatalkan direktif "ssl on" dengan # untuk domain tempat kita memiliki nginx warning.
sudo nano /home/vestacpuser/conf/web/example.com.nginx.ssl.conf
# ssl on

Simpan file dan jalankan lagi nginx -t
. Kesalahan nginx: [warn] the “ssl” directive is deprecated…” itu tidak akan hadir lagi.
nginx -t
Dengan metode ini, kesalahan tidak akan diselesaikan secara permanen. Domain baru akan mengikuti file konfigurasi paket yang ditetapkan ke akun di VestaCP.
Metode 2. Sunting VestaCP Web Template untuk Nginx.
Sebelum kita menambahkan pemakai in VestaCP, kita perlu membuat paket. VestaCP Packages. Paket-paket ini berisi beberapa konfigurasi untuk CMS atau skrip yang berbeda. Web Template (Nginx), Backend Template (PHP-FPM), DNS Template (NAMED).
Ketika kita menambahkan daerah sebuah pemakai VestaCP, konfigurasi Nginx default dari domain yang baru ditambahkan akan diberikan oleh Web Template (Nginx) terpilih untuk paket penggunaacquis.

Kami mengambil skenario di mana kami menambahkan Vesta Package Name: Stealth cu Web Template NGINX: wordpress2. Jika template “wordpress2” berisi arahan “ssl on”, domain baru yang ditambahkan dengan template ini akan memiliki arahan yang sudah usang ini dalam konfigurasi. Jadi sebaiknya untuk mengubah Web Template in VestaCP. Sehingga domain baru yang ditambahkan tidak lagi menerima "ssl on" pada konfigurasi Nginx.
Cara mengedit Web Template VestaCP untuk mengeliminasi “ssl” directive is deprecated” ?
Templat yang menulis file konfigurasi dari domain yang ditambahkan terletak di:
/usr/local/vesta/data/templates/web/nginx/php-fpm
Ini memiliki dua ujung. .tpl
untuk domain tanpa SSL dan .stpl
untuk domain dengan SSL diaktifkan.
[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]#
Kami mengambil skenario di atas, di mana kami memiliki template "wordpress2.stpl". Kami mengedit file ini di server web dan menghapus baris dengan arahan "ssl on".
nano /usr/local/vesta/data/templates/web/nginx/php-fpm/wordpress2.stpl

Setelah menghapus baris "ssl on" dari template, simpan file. Domain berikut yang akan ditambahkan dengan templat ini tidak lagi memiliki arahan yang sudah ketinggalan zaman. "arahan ssl" tidak digunakan lagi, tidak akan muncul saat menguji nginx.
Dengan cara yang sama semua template web dapat dimodifikasi VestaCP atau yang baru dapat dibuat untuk menyertakan konfigurasi nginx dan php-fpm khusus.