2b524051c3cd8f7cc78673c5aefcb0d7841468c0
Mailcatcher Testserver
Mailhog installeren
chmod +x install_mailhog_as_service.sh
./install_mailhog_as_service.sh
Na de installatie
systemctl enable mailhog
reboot server
Nginx configuratie (gebruik template: xxx.BEWAREN.mailcatcher.open2bizz.com.conf)
server {
listen 8025;
server_name 434-mailcatcher.staging.open2bizz.com;
# log
access_log /var/log/nginx/434.access.log;
error_log /var/log/nginx/434.error.log;
gzip_types text/css text/less text/plain text/xml application/xml application/json application/javascript;
gzip on;
location / {
#kantoor Open2bizz 83.84.200.111
allow 83.84.200.111;
allow 83.82.145.237;
allow 45.132.40.125;
allow 86.93.238.87;
allow 80.114.214.241;
allow 94.157.36.155;
allow 145.131.221.238;
deny all;
auth_basic "Administrator Area";
auth_basic_user_file /etc/nginx/.htpasswd;
proxy_redirect off;
proxy_pass http://192.168.78.134:8025;
}
#error pages
error_page 500 501 502 503 504 https://www.open2bizz.tech/503;
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/434-mailcatcher.staging.open2bizz.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/434-mailcatcher.staging.open2bizz.com/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
In de nginx config file een wachtwoord opnemen:
auth_basic "Administrator Area";
auth_basic_user_file /etc/nginx/.htpasswd;
apt-get install apache2-utils
apt update
apt install apache2-utils
ls /etc/apache2
cd /etc
ls
htpasswd -c /etc/nginx/.htpasswd admin
service nginx restart
nano /etc/nginx/.htpasswd
ODOO: Menu maken voor Mailcatcher
Maak een Menu aan met de naam Mailcatcher Hang deze aan de groep 'Internal User' Action: ir.actions.act_url => Thirdparty apps Klik door op 'Thirdparty apps' en verwijs de action URL naar de in nginx opgegeven naam (bijv: https://426-mailcatcher.staging.open2bizz.com/) Zet het target op New Window
Description