{"id":9285,"date":"2026-08-22T23:08:25","date_gmt":"2026-08-22T20:08:25","guid":{"rendered":"https:\/\/machinser.com\/?p=9285"},"modified":"2026-08-22T23:09:20","modified_gmt":"2026-08-22T20:09:20","slug":"odoo-deployment-nginx-vs-apache","status":"publish","type":"post","link":"https:\/\/machinser.com\/ar\/odoo-deployment-nginx-vs-apache\/","title":{"rendered":"Nginx vs Apache for Odoo: Which Is Better for Odoo ERP?"},"content":{"rendered":"<article class=\"odoo-blog-post\">When deploying <strong>Odoo in a production environment<\/strong>, choosing the right reverse proxy is an important decision for performance, security, scalability, and reliability.<\/p>\n<p>Two of the most commonly used web servers are <strong>Nginx<\/strong> and <strong>Apache<\/strong>.<\/p>\n<p>For modern Odoo deployments, <strong>Nginx is generally the preferred choice<\/strong>, particularly when you need efficient handling of concurrent connections, HTTPS termination, static assets, and Odoo&#8217;s real-time communication.<\/p>\n<p>In this guide, we&#8217;ll compare <strong>Nginx vs Apache for Odoo<\/strong> and look at a production-ready Nginx configuration.<\/p>\n<hr \/>\n<h2>Why Does Odoo Need a Reverse Proxy?<\/h2>\n<p>Odoo can technically be accessed directly through port <code>8069<\/code>, but exposing Odoo directly to the internet isn&#8217;t the ideal production architecture.<\/p>\n<p>A reverse proxy such as Nginx vs Apache sits between the user and Odoo:<\/p>\n<pre><code>User\r\n  \u2193\r\nHTTPS :443\r\n  \u2193\r\nNginx \/ Apache\r\n  \u2193\r\nOdoo :8069\r\n  \u2193\r\nPostgreSQL<\/code><\/pre>\n<p>A reverse proxy provides several important benefits.<\/p>\n<h3>1. SSL\/TLS Termination<\/h3>\n<p>The reverse proxy handles HTTPS connections and SSL certificates while forwarding requests internally to Odoo.<\/p>\n<p>This makes it easier to manage:<\/p>\n<ul>\n<li>SSL certificates<\/li>\n<li>HTTPS redirects<\/li>\n<li>TLS versions<\/li>\n<li>Security headers<\/li>\n<\/ul>\n<h3>2. Better Traffic Management<\/h3>\n<p>The reverse proxy can control how incoming requests are handled before they reach Odoo.<\/p>\n<p>This becomes especially useful when running Odoo with multiple workers or multiple application instances.<\/p>\n<h3>3. Static Asset Handling<\/h3>\n<p>Odoo serves JavaScript, CSS, images, and other assets. Caching and compression at the reverse-proxy layer can reduce unnecessary load on Odoo workers.<\/p>\n<h3>4. Long-Polling \/ Real-Time Communication<\/h3>\n<p>Odoo uses a separate service for real-time communication in worker-based deployments. Depending on the Odoo version and configuration, this commonly involves port <code>8072<\/code>.<\/p>\n<p>A correctly configured reverse proxy routes those requests separately.<\/p>\n<hr \/>\n<h2>Nginx vs Apache for Odoo<\/h2>\n<table>\n<thead>\n<tr>\n<th>Feature<\/th>\n<th>Nginx<\/th>\n<th>Apache<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Concurrent connections<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Memory efficiency<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Reverse proxy<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Excellent<\/td>\n<\/tr>\n<tr>\n<td>SSL\/TLS<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Excellent<\/td>\n<\/tr>\n<tr>\n<td>Static files<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Excellent<\/td>\n<\/tr>\n<tr>\n<td>Odoo deployment<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Configuration simplicity<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Modern cloud deployments<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Real-time Odoo routing<\/td>\n<td><strong>Excellent<\/strong><\/td>\n<td>Good<\/td>\n<\/tr>\n<tr>\n<td>Recommended for new Odoo deployments<\/td>\n<td><strong>Yes<\/strong><\/td>\n<td>Possible<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h2>Why Choose Nginx?<\/h2>\n<p>Nginx uses an asynchronous, event-driven architecture that allows it to handle a large number of concurrent connections efficiently.<\/p>\n<p>For Odoo environments, this can be particularly useful when you have:<\/p>\n<ul>\n<li>Multiple users<\/li>\n<li>Large databases<\/li>\n<li>Heavy web traffic<\/li>\n<li>Multiple Odoo workers<\/li>\n<li>Real-time notifications<\/li>\n<li>Large file uploads<\/li>\n<li>Multiple Odoo instances<\/li>\n<\/ul>\n<p>Apache can also work perfectly well with Odoo, but for a <strong>new production deployment<\/strong>, Nginx is often the simpler and more efficient choice.<\/p>\n<hr \/>\n<h2>Production-Ready Nginx Configuration for Odoo<\/h2>\n<p>Below is an example configuration covering:<\/p>\n<ul>\n<li>HTTPS<\/li>\n<li>HTTP \u2192 HTTPS redirect<\/li>\n<li>SSL\/TLS<\/li>\n<li>Odoo reverse proxy<\/li>\n<li>Long-polling<\/li>\n<li>Large uploads<\/li>\n<li>Extended timeouts<\/li>\n<li>Proxy buffers<\/li>\n<li>Gzip compression<\/li>\n<li>Static asset caching<\/li>\n<li>Security headers<\/li>\n<\/ul>\n<div class=\"odoo-note\"><strong>Important:<\/strong> Replace <code>yourdomain.com<\/code> with your actual domain and adjust the SSL certificate paths and Odoo ports according to your environment.<\/div>\n<h2>Step 1 \u2014 Define Odoo Upstreams<\/h2>\n<p>The first upstream points to the main Odoo service, while the second is used for real-time communication when your Odoo deployment is configured to use port <code>8072<\/code>.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>upstream odoo {\r\n    server 127.0.0.1:8069;\r\n}\r\n\r\nupstream odoo-chat {\r\n    server 127.0.0.1:8072;\r\n}<\/code><\/pre>\n<\/div>\n<h2>Step 2 \u2014 Redirect HTTP to HTTPS<\/h2>\n<p>This automatically redirects visitors from HTTP to HTTPS.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>server {\r\n    listen 80;\r\n    server_name yourdomain.com www.yourdomain.com;\r\n\r\n    return 301 https:\/\/$host$request_uri;\r\n}<\/code><\/pre>\n<\/div>\n<h2>Step 3 \u2014 Configure the HTTPS Server<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>server {\r\n    listen 443 ssl http2;\r\n    server_name yourdomain.com www.yourdomain.com;\r\n\r\n    # SSL Certificate paths\r\n    ssl_certificate \/etc\/letsencrypt\/live\/yourdomain.com\/fullchain.pem;\r\n    ssl_certificate_key \/etc\/letsencrypt\/live\/yourdomain.com\/privkey.pem;\r\n\r\n    ssl_protocols TLSv1.2 TLSv1.3;\r\n    ssl_ciphers HIGH:!aNULL:!MD5;<\/code><\/pre>\n<\/div>\n<p>If you&#8217;re using Let&#8217;s Encrypt with Certbot, Certbot normally manages these certificate files for you.<\/p>\n<h2>Step 4 \u2014 Configure Logging<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>access_log \/var\/log\/nginx\/odoo.access.log;\r\nerror_log \/var\/log\/nginx\/odoo.error.log;<\/code><\/pre>\n<\/div>\n<p>Keeping separate Odoo logs makes troubleshooting considerably easier.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>sudo tail -f \/var\/log\/nginx\/odoo.error.log<\/code><\/pre>\n<\/div>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>sudo tail -f \/var\/log\/nginx\/odoo.access.log<\/code><\/pre>\n<\/div>\n<h2>Step 5 \u2014 Configure Production Timeouts<\/h2>\n<p>Odoo can generate large reports, process imports, upload attachments, and perform long-running operations.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>proxy_read_timeout 720s;\r\nproxy_connect_timeout 720s;\r\nproxy_send_timeout 720s;\r\n\r\nclient_max_body_size 100M;<\/code><\/pre>\n<\/div>\n<p>The <code>client_max_body_size<\/code> setting is particularly useful when users need to upload large files or backups.<\/p>\n<h2>Step 6 \u2014 Configure Proxy Buffers<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>proxy_buffers 16 64k;\r\nproxy_buffer_size 128k;<\/code><\/pre>\n<\/div>\n<p>These settings control how Nginx buffers responses received from Odoo.<\/p>\n<h2>Step 7 \u2014 Enable Gzip Compression<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>gzip on;\r\n\r\ngzip_types\r\n    text\/css\r\n    text\/less\r\n    text\/plain\r\n    text\/xml\r\n    application\/xml\r\n    application\/json\r\n    application\/javascript;\r\n\r\ngzip_min_length 1000;\r\n\r\ngzip_proxied expired no-cache no-store private auth;<\/code><\/pre>\n<\/div>\n<p>Compression can reduce the amount of data transferred between the server and the browser.<\/p>\n<h2>Step 8 \u2014 Configure Odoo Long-Polling<\/h2>\n<p>For deployments using Odoo&#8217;s long-polling service, route the appropriate requests to port <code>8072<\/code>.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>location \/longpolling {\r\n    proxy_pass http:\/\/odoo-chat;\r\n\r\n    proxy_next_upstream error timeout invalid_header\r\n        http_500 http_502 http_503;\r\n\r\n    proxy_set_header Host $host;\r\n    proxy_set_header X-Real-IP $remote_addr;\r\n    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\r\n    proxy_set_header X-Forwarded-Proto https;\r\n}<\/code><\/pre>\n<\/div>\n<p>This helps support Odoo features that depend on real-time communication, such as notifications and chat.<\/p>\n<div class=\"odoo-note\"><strong>Note:<\/strong> The exact real-time route and worker configuration can vary by Odoo version and deployment architecture. Always verify the configuration against the Odoo version you&#8217;re running.<\/div>\n<h2>Step 9 \u2014 Configure Main Odoo Traffic<\/h2>\n<p>All other requests can be forwarded to the Odoo application running on port <code>8069<\/code>.<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>location \/ {\r\n    proxy_pass http:\/\/odoo;\r\n\r\n    proxy_next_upstream error timeout invalid_header\r\n        http_500 http_502 http_503;\r\n\r\n    proxy_set_header Host $host;\r\n    proxy_set_header X-Real-IP $remote_addr;\r\n    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\r\n    proxy_set_header X-Forwarded-Proto https;\r\n\r\n    proxy_http_version 1.1;\r\n\r\n    proxy_set_header Upgrade $http_upgrade;\r\n    proxy_set_header Connection \"\";\r\n}<\/code><\/pre>\n<\/div>\n<p>The forwarded headers allow Odoo to understand information about the original client request and protocol.<\/p>\n<h2>Step 10 \u2014 Cache Odoo Static Assets<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>location ~* \/web\/static\/ {\r\n    proxy_cache_valid 200 60m;\r\n\r\n    proxy_pass http:\/\/odoo;\r\n\r\n    proxy_http_version 1.1;\r\n    proxy_set_header Connection \"\";\r\n    proxy_set_header Host $host;\r\n\r\n    expires 86400s;\r\n\r\n    add_header Cache-Control \"public, no-transform\";\r\n}<\/code><\/pre>\n<\/div>\n<p>This can help reduce unnecessary traffic between the browser, Nginx, and Odoo.<\/p>\n<h2>Step 11 \u2014 Add Security Headers<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Code<\/button><\/p>\n<pre><code>add_header X-Frame-Options \"SAMEORIGIN\";\r\nadd_header X-XSS-Protection \"1; mode=block\";\r\nadd_header X-Content-Type-Options \"nosniff\";<\/code><\/pre>\n<\/div>\n<p>These headers provide additional browser-level security controls.<\/p>\n<hr \/>\n<h2>Complete Nginx Configuration for Odoo<\/h2>\n<p>If you want the complete configuration in one place, use the following:<\/p>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Full Configuration<\/button><\/p>\n<pre><code>upstream odoo {\r\n    server 127.0.0.1:8069;\r\n}\r\n\r\nupstream odoo-chat {\r\n    server 127.0.0.1:8072;\r\n}\r\n\r\n# Redirect HTTP to HTTPS\r\nserver {\r\n    listen 80;\r\n    server_name yourdomain.com www.yourdomain.com;\r\n\r\n    return 301 https:\/\/$host$request_uri;\r\n}\r\n\r\nserver {\r\n    listen 443 ssl http2;\r\n    server_name yourdomain.com www.yourdomain.com;\r\n\r\n    # SSL Certificate\r\n    ssl_certificate \/etc\/letsencrypt\/live\/yourdomain.com\/fullchain.pem;\r\n    ssl_certificate_key \/etc\/letsencrypt\/live\/yourdomain.com\/privkey.pem;\r\n\r\n    ssl_protocols TLSv1.2 TLSv1.3;\r\n    ssl_ciphers HIGH:!aNULL:!MD5;\r\n\r\n    # Logging\r\n    access_log \/var\/log\/nginx\/odoo.access.log;\r\n    error_log \/var\/log\/nginx\/odoo.error.log;\r\n\r\n    # Production timeout &amp; size limits\r\n    proxy_read_timeout 720s;\r\n    proxy_connect_timeout 720s;\r\n    proxy_send_timeout 720s;\r\n\r\n    client_max_body_size 100M;\r\n\r\n    # Proxy buffering\r\n    proxy_buffers 16 64k;\r\n    proxy_buffer_size 128k;\r\n\r\n    # Gzip\r\n    gzip on;\r\n\r\n    gzip_types\r\n        text\/css\r\n        text\/less\r\n        text\/plain\r\n        text\/xml\r\n        application\/xml\r\n        application\/json\r\n        application\/javascript;\r\n\r\n    gzip_min_length 1000;\r\n    gzip_proxied expired no-cache no-store private auth;\r\n\r\n    # Long-polling \/ real-time communication\r\n    location \/longpolling {\r\n        proxy_pass http:\/\/odoo-chat;\r\n\r\n        proxy_next_upstream error timeout invalid_header\r\n            http_500 http_502 http_503;\r\n\r\n        proxy_set_header Host $host;\r\n        proxy_set_header X-Real-IP $remote_addr;\r\n        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\r\n        proxy_set_header X-Forwarded-Proto https;\r\n    }\r\n\r\n    # Main Odoo routing\r\n    location \/ {\r\n        proxy_pass http:\/\/odoo;\r\n\r\n        proxy_next_upstream error timeout invalid_header\r\n            http_500 http_502 http_503;\r\n\r\n        proxy_set_header Host $host;\r\n        proxy_set_header X-Real-IP $remote_addr;\r\n        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\r\n        proxy_set_header X-Forwarded-Proto https;\r\n\r\n        proxy_http_version 1.1;\r\n        proxy_set_header Upgrade $http_upgrade;\r\n        proxy_set_header Connection \"\";\r\n    }\r\n\r\n    # Static assets\r\n    location ~* \/web\/static\/ {\r\n        proxy_cache_valid 200 60m;\r\n\r\n        proxy_pass http:\/\/odoo;\r\n\r\n        proxy_http_version 1.1;\r\n        proxy_set_header Connection \"\";\r\n        proxy_set_header Host $host;\r\n\r\n        expires 86400s;\r\n\r\n        add_header Cache-Control \"public, no-transform\";\r\n    }\r\n\r\n    # Security headers\r\n    add_header X-Frame-Options \"SAMEORIGIN\";\r\n    add_header X-XSS-Protection \"1; mode=block\";\r\n    add_header X-Content-Type-Options \"nosniff\";\r\n}<\/code><\/pre>\n<\/div>\n<hr \/>\n<h2>Nginx vs Apache: Final Verdict<\/h2>\n<h3>\ud83e\udd47 Nginx<\/h3>\n<p>Choose Nginx when you want:<\/p>\n<ul>\n<li>High concurrent connection handling<\/li>\n<li>Efficient resource usage<\/li>\n<li>Easy SSL management<\/li>\n<li>Reverse proxy functionality<\/li>\n<li>Odoo real-time routing<\/li>\n<li>Static asset caching<\/li>\n<li>A modern production architecture<\/li>\n<\/ul>\n<h3>\ud83e\udd48 Apache<\/h3>\n<p>Apache remains a capable choice and can absolutely be used with Odoo, especially when your infrastructure already relies heavily on Apache or its existing modules and configuration.<\/p>\n<p>But if you&#8217;re starting from scratch, <strong>Nginx is usually the more straightforward choice for an Odoo production stack.<\/strong><\/p>\n<hr \/>\n<h2>Recommended Odoo Production Architecture<\/h2>\n<div class=\"code-wrapper\"><button class=\"copy-code\">Copy Diagram<\/button><\/p>\n<pre><code>                    INTERNET\r\n                        \u2502\r\n                        \u25bc\r\n                 \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\r\n                 \u2502    Nginx    \u2502\r\n                 \u2502   HTTPS     \u2502\r\n                 \u2502   :443      \u2502\r\n                 \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2518\r\n                        \u2502\r\n             \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2534\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\r\n             \u2502                     \u2502\r\n             \u25bc                     \u25bc\r\n       Odoo Workers          Real-Time Service\r\n          :8069                  :8072\r\n             \u2502                     \u2502\r\n             \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u252c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518\r\n                        \u25bc\r\n                 \u250c\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510\r\n                 \u2502 PostgreSQL  \u2502\r\n                 \u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518<\/code><\/pre>\n<\/div>\n<p>This architecture provides a clean separation between the <strong>public-facing web layer<\/strong> and the <strong>Odoo application layer<\/strong>.<\/p>\n<h2>Conclusion<\/h2>\n<p><strong>Nginx vs Apache isn&#8217;t really about whether Apache can run Odoo\u2014it can.<\/strong><\/p>\n<p>The more important question is which architecture gives you the best combination of <strong>performance, security, maintainability, and scalability<\/strong> for your Odoo deployment.<\/p>\n<p>For most new Odoo production environments, <strong>Nginx + Odoo + PostgreSQL<\/strong> is a strong and practical starting point.<\/p>\n<div class=\"odoo-cta\">\n<h3>Looking for Professional Odoo Implementation?<\/h3>\n<p>Need help with Odoo deployment, server configuration, customization, migration, or production optimization?<\/p>\n<p><strong>Get professional Odoo ERP implementation and support for your business.<\/strong><\/p>\n<\/div>\n<\/article>\n<style>\n.odoo-blog-post {<br \/>\n    max-width: 900px;<br \/>\n    margin: 0 auto;<br \/>\n    line-height: 1.75;<br \/>\n    font-size: 17px;<br \/>\n}<\/p>\n<p>.odoo-blog-post h1 {<br \/>\n    font-size: 36px;<br \/>\n    line-height: 1.25;<br \/>\n    margin-bottom: 25px;<br \/>\n}<\/p>\n<p>.odoo-blog-post h2 {<br \/>\n    font-size: 29px;<br \/>\n    margin-top: 45px;<br \/>\n    margin-bottom: 18px;<br \/>\n}<\/p>\n<p>.odoo-blog-post h3 {<br \/>\n    font-size: 22px;<br \/>\n    margin-top: 30px;<br \/>\n}<\/p>\n<p>.odoo-blog-post p {<br \/>\n    margin: 16px 0;<br \/>\n}<\/p>\n<p>.odoo-blog-post ul {<br \/>\n    margin: 15px 0 25px 25px;<br \/>\n}<\/p>\n<p>.odoo-blog-post li {<br \/>\n    margin-bottom: 7px;<br \/>\n}<\/p>\n<p>.odoo-blog-post table {<br \/>\n    width: 100%;<br \/>\n    border-collapse: collapse;<br \/>\n    margin: 25px 0;<br \/>\n    overflow: hidden;<br \/>\n}<\/p>\n<p>.odoo-blog-post th,<br \/>\n.odoo-blog-post td {<br \/>\n    border: 1px solid #ddd;<br \/>\n    padding: 12px 14px;<br \/>\n    text-align: left;<br \/>\n}<\/p>\n<p>.odoo-blog-post th {<br \/>\n    font-weight: 700;<br \/>\n}<\/p>\n<p>.odoo-blog-post code {<br \/>\n    font-family: \"SFMono-Regular\", Consolas, \"Liberation Mono\", monospace;<br \/>\n    font-size: 0.9em;<br \/>\n}<\/p>\n<p>.odoo-blog-post pre {<br \/>\n    background: #111827;<br \/>\n    color: #f9fafb;<br \/>\n    padding: 22px;<br \/>\n    border-radius: 10px;<br \/>\n    overflow-x: auto;<br \/>\n    line-height: 1.55;<br \/>\n    font-size: 14px;<br \/>\n    margin: 20px 0 30px;<br \/>\n}<\/p>\n<p>.odoo-blog-post pre code {<br \/>\n    color: inherit;<br \/>\n    background: transparent;<br \/>\n    font-size: inherit;<br \/>\n}<\/p>\n<p>.code-wrapper {<br \/>\n    position: relative;<br \/>\n    margin: 25px 0;<br \/>\n}<\/p>\n<p>.code-wrapper pre {<br \/>\n    margin-top: 0;<br \/>\n    padding-top: 55px;<br \/>\n}<\/p>\n<p>.copy-code {<br \/>\n    position: absolute;<br \/>\n    top: 10px;<br \/>\n    right: 10px;<br \/>\n    z-index: 5;<br \/>\n    border: 0;<br \/>\n    border-radius: 6px;<br \/>\n    padding: 8px 14px;<br \/>\n    cursor: pointer;<br \/>\n    font-size: 13px;<br \/>\n    font-weight: 600;<br \/>\n    background: #ffffff;<br \/>\n    color: #111827;<br \/>\n}<\/p>\n<p>.copy-code:hover {<br \/>\n    opacity: 0.85;<br \/>\n}<\/p>\n<p>.odoo-note {<br \/>\n    border-left: 4px solid #714B67;<br \/>\n    background: #f7f3f6;<br \/>\n    padding: 16px 20px;<br \/>\n    margin: 25px 0;<br \/>\n    border-radius: 4px;<br \/>\n}<\/p>\n<p>.odoo-cta {<br \/>\n    margin: 45px 0;<br \/>\n    padding: 30px;<br \/>\n    border-radius: 12px;<br \/>\n    background: #f5f5f5;<br \/>\n    text-align: center;<br \/>\n}<\/p>\n<p>.odoo-cta h3 {<br \/>\n    margin-top: 0;<br \/>\n}<\/p>\n<p>@media (max-width: 768px) {<br \/>\n    .odoo-blog-post {<br \/>\n        font-size: 16px;<br \/>\n    }<\/p>\n<p>    .odoo-blog-post h1 {<br \/>\n        font-size: 29px;<br \/>\n    }<\/p>\n<p>    .odoo-blog-post h2 {<br \/>\n        font-size: 25px;<br \/>\n    }<\/p>\n<p>    .odoo-blog-post table {<br \/>\n        display: block;<br \/>\n        overflow-x: auto;<br \/>\n        white-space: nowrap;<br \/>\n    }<\/p>\n<p>    .odoo-blog-post pre {<br \/>\n        font-size: 13px;<br \/>\n        padding: 18px;<br \/>\n        padding-top: 52px;<br \/>\n    }<br \/>\n}<br \/>\n<\/style>\n<p><script>\nfunction copyCode(button) {\n    const wrapper = button.closest('.code-wrapper');\n    const code = wrapper.querySelector('pre code').innerText;<\/p>\n<p>    navigator.clipboard.writeText(code).then(function() {\n        const originalText = button.innerText;\n        button.innerText = 'Copied!';<\/p>\n<p>        setTimeout(function() {\n            button.innerText = originalText;\n        }, 2000);\n    }).catch(function() {\n        const textarea = document.createElement('textarea');\n        textarea.value = code;\n        document.body.appendChild(textarea);\n        textarea.select();\n        document.execCommand('copy');\n        document.body.removeChild(textarea);<\/p>\n<p>        const originalText = button.innerText;\n        button.innerText = 'Copied!';<\/p>\n<p>        setTimeout(function() {\n            button.innerText = originalText;\n        }, 2000);\n    });\n}\n<\/script><\/p>","protected":false},"excerpt":{"rendered":"<p>When deploying Odoo in a production environment, choosing the right reverse proxy is an important decision for performance, security, scalability, and reliability. Two of the most commonly used web servers are Nginx and Apache. For modern Odoo deployments, Nginx is generally the preferred choice, particularly when you need efficient handling of concurrent connections, HTTPS termination, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":9362,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[314],"tags":[251,252],"class_list":["post-9285","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-odoo-server","tag-odoo-community","tag-odoo-enterprise"],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"https:\/\/machinser.com\/wp-content\/uploads\/2026\/08\/Nginx-vs-Apache-for-Odoo-Which-Is-Better-for-Odoo-ERP.png","_links":{"self":[{"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/posts\/9285","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/comments?post=9285"}],"version-history":[{"count":4,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/posts\/9285\/revisions"}],"predecessor-version":[{"id":9363,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/posts\/9285\/revisions\/9363"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/media\/9362"}],"wp:attachment":[{"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/media?parent=9285"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/categories?post=9285"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/machinser.com\/ar\/wp-json\/wp\/v2\/tags?post=9285"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}