Editing
HAProxy
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==== Configurare Frontend ==== Fișierele sunt stocate modular în directorul inclus secundar (`conf.d/`). <code class="mw-code mw-highlight plainlinks" style="display:block"><!-- --> # nano /etc/haproxy/conf.d/websites.cfg    # FRONTEND HTTP - Port 80 (Cu suport ACME Challenge integrat dinamic)    frontend fe_http     bind *:80     mode http       # Extrage stringul curat al domeniului (taie portul :80 trimis de unele browsere)     http-request set-var(txn.backend) req.hdr(host),field(1,:),lower,map(/etc/haproxy/maps/web-http.map)       # Detecție trafic ACME Challenge (Let's Encrypt / ISPConfig)     acl is_acme path_beg /.well-known/acme-challenge/       # Securitate: Blocare 403 dacă domeniul nu există în map ȘI nu este o cerere ACME     http-request deny deny_status 403 if ! { var(txn.backend) -m found } !is_acme       # Rutare: Trimite către backend-ul identificat în map     use_backend %[var(txn.backend)] if { var(txn.backend) -m found }       # Fallback obligatoriu pentru procesarea automată a certificatelor ACME generate în ISPConfig     default_backend be_vm1_http    # FRONTEND HTTPS - Port 443 (SSL Passthrough transparent pe bază de SNI)    frontend fe_https     bind *:443     mode tcp       # Inspectează pachetele inițiale TCP pentru a citi header-ul TLS nesecurizat     tcp-request inspect-delay 5s     tcp-request content accept if { req.ssl_hello_type 1 }       # Rutare Layer 4 bazată pe SNI-ul extras din handshake-ul TLS potrivit în map-ul HTTPS     use_backend %[req.ssl_sni,lower,map(/etc/haproxy/maps/web-https.map)]       # Dacă domeniul accesat prin TLS nu există în map, conexiunea este respinsă direct     default_backend be_https_deny   </code>
Summary:
Please note that all contributions to Linux Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Linux Wiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
Edit source
View history
More
Navigation
Main page
Aplicatii Linux
UrBackup
rSyslog
KeepAlived
HAProxy
USB over IP
Pi-hole
DHCP
BIND DNS
Hardware Linux
Adaugare Disk
Extindere Disk
Docker
Instalare Docker CE
Portainer
Container UrBackup
Container PiHole
Raspberry Pi
NTP Server
Snippets
History Command
Access Control List
Troubleshooting
Colectare Info
CPU
RAM
Disk
Tools
What links here
Related changes
Special pages
Page information