» »

Nginx mail proxy

Nginx mail proxy

poweroff ::

Nginx bi rad na Debianu 11 uporabil kot mail proxy. Namestil sem paket nginx-full, med paketi pa se najde tudi libnginx-mod-mail, ki:

The nginx_mail module adds mail proxy support to nginx.
The module supports proxying all the standard mail protocols such as IMAP, POP3 & SMTP.


Sistem mi pravi, da je zadeva nameščena:

libnginx-mod-mail/stable,now 1.18.0-6.1+deb11u2 amd64 [installed,automatic]
  Mail module for Nginx


Vendar pa mi Nginx ne prepozna mail direktive. Če namreč v config napišem:

mail {
...
}

... mi javi napako.

Mimogrede, Nginx mail proxy ima v različnih primerih napisano tole:
auth_http   localhost:9000/cgi-bin/nginxauth.cgi;


Kaj je ta skripta, kje jo dobim?
sudo poweroff

HotBurek ::

Če daš "mail {}" v /etc/nginx/nginx.conf bo delal.

Kaj je v folderju: /usr/share/nginx

Ter:
apt-get install locate
updatedb
locate nginxauth.cgi
root@debian:/# iptraf-ng
fatal: This program requires a screen size of at least 80 columns by 24 lines
Please resize your window

Zgodovina sprememb…

  • spremenilo: HotBurek ()

poweroff ::

HotBurek je izjavil:

Če daš "mail {}" v /etc/nginx/nginx.conf bo delal.

To ne dela (sem poskusil že prej).

HotBurek je izjavil:


apt-get install locate
updatedb
locate nginxauth.cgi

Ne najde nič.
sudo poweroff

HotBurek ::

Kakšen error ti pa vrne, ko poženeš nginx -t

Še ena: nginx -V bi bojda moral vrniti parametra "--with-mail --with-mail_ssl_module"

In še ena: ne vem, če ima veze, jaz imam nameščen samo nginx, brez -full.

nginx/stable,now 1.23.1-1~buster amd64 [installed]
root@debian:/# iptraf-ng
fatal: This program requires a screen size of at least 80 columns by 24 lines
Please resize your window

HotBurek ::

Pa source za nginx si lahko dodaš, da boš imel zadnjo verzijo.

wget https://nginx.org/keys/nginx_signing.key
apt-key add nginx_signing.key

Ter /etc/apt/sources.list.d/nginx.list
deb http://nginx.org/packages/debian/ buster nginx
deb-src http://nginx.org/packages/debian/ buster nginx

deb http://nginx.org/packages/mainline/debian/ buster nginx
deb-src http://nginx.org/packages/mainline/debian/ buster nginx

Potem pa apt-get update, apt-get upgrade...
root@debian:/# iptraf-ng
fatal: This program requires a screen size of at least 80 columns by 24 lines
Please resize your window

Zgodovina sprememb…

  • spremenilo: HotBurek ()

poweroff ::

nginx -t:

nginx: [emerg] unknown directive "mail" in /etc/nginx/nginx.conf:35
nginx: configuration file /etc/nginx/nginx.conf test failed


Pa še:
configure arguments: --with-cc-opt='-g -O2 -ffile-prefix-map=/build/nginx-QeqwpL/nginx-1.18.0=. -fstack-protector-strong -Wformat -Werror=format-security -fPIC -Wdate-time -D_FORTIFY_SOURCE=2' --with-ld-opt='-Wl,-z,relro -Wl,-z,now -fPIC' --prefix=/usr/share/nginx --conf-path=/etc/nginx/nginx.conf --http-log-path=/var/log/nginx/access.log --error-log-path=/var/log/nginx/error.log --lock-path=/var/lock/nginx.lock --pid-path=/run/nginx.pid --modules-path=/usr/lib/nginx/modules --http-client-body-temp-path=/var/lib/nginx/body --http-fastcgi-temp-path=/var/lib/nginx/fastcgi --http-proxy-temp-path=/var/lib/nginx/proxy --http-scgi-temp-path=/var/lib/nginx/scgi --http-uwsgi-temp-path=/var/lib/nginx/uwsgi --with-compat --with-debug --with-pcre-jit --with-http_ssl_module --with-http_stub_status_module --with-http_realip_module --with-http_auth_request_module --with-http_v2_module --with-http_dav_module --with-http_slice_module --with-threads --with-http_addition_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_sub_module


Sem imel tudi samo nginx namešče (brez -full), pa je bilo isto. Očitno ni preveden s temi mail flagi...
sudo poweroff


Vredno ogleda ...

TemaSporočilaOglediZadnje sporočilo
TemaSporočilaOglediZadnje sporočilo
»

nginx | lokacija default error page html fajlov?

Oddelek: Operacijski sistemi
6492 (400) secops
»

Python - pošlji aplikacijo na server

Oddelek: Programiranje
201524 (759) HotBurek
»

Fix skripte: nginx log + group by user-agent + count + sort desc

Oddelek: Programiranje
5698 (621) Invictus
»

Postavitev mySQL

Oddelek: Programiranje
92200 (1778) M01O
»

Python v Wordpress

Oddelek: Programiranje
81274 (1069) Halfdead987

Več podobnih tem