OroCommerce Forums

Covering OroCommerce topics, including community updates and company announcements.

Forums Forums OroCommerce Installation issue – how configure Nginx

This topic contains 4 replies, has 3 voices, and was last updated by  The Jackal 7 years, 3 months ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #31297

    billgates81
    Participant

    Hi, I’ve followed the instructions in your github page even if in some cases I’d have added some mode details.
    Anyway I’m in troubles with Nginx configuration, I always get “502 Bad Gateway” error.
    Do you have some nginx template to suggest?

    This is my actual configuration:

    server {
    listen 80;
    server_name my-ip-server;
    root /usr/share/nginx/web;

    location / {
    try_files $uri /app.php$is_args$args;
    }

    location ~ ^/(app_dev|config)\.php(/|$) {
    fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
    fastcgi_split_path_info ^(.+\.php)(/.*)$;
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
    fastcgi_param DOCUMENT_ROOT $realpath_root;
    }

    location ~ ^/app\.php(/|$) {
    fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
    fastcgi_split_path_info ^(.+\.php)(/.*)$;
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
    fastcgi_param DOCUMENT_ROOT $realpath_root;
    internal;
    }

    location ~ \.php$ {
    return 404;
    }

    error_log /var/log/nginx/project_error.log;
    access_log /var/log/nginx/project_access.log;
    }

Viewing 4 replies - 1 through 4 (of 4 total)
  • Author
    Replies
  • #31298

    Michael
    Keymaster

    The installation section of the Oro Book includes sample configurations for Apache, Nginx, PHP-FPM settings, as well as other useful information.

    The Nginx configuration example is as follows, and I highly recommend to read the entire article at https://www.orocrm.com/doc/current/book/installation

    #31299

    The Jackal
    Participant

    As a side question, what is the preferred web engine for oroCommerce? Nginx, FPM or Apache? Thanks!

    #31300

    Michael
    Keymaster

    There is no preference. You can run either one.

    #31301

    The Jackal
    Participant

    Hi Michael,

    Cool! Thanks for the reply!

Viewing 4 replies - 1 through 4 (of 4 total)

The forum ‘OroCommerce’ is closed to new topics and replies.

Back to top