Install 2 instances of ERPNext on same server?

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {

server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Hi looks positive. What is gunicorn.conf? I cannot find this file. 

On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>
Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

 www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
See this wiki https://github.com/webnotes/erpnext/wiki/WSGI-Production-Deployment


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file.


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {

server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file. 


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

 www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Yes, the WSGI works much better in performance issues with gunicorn than Apache.


2013/11/13 CJ <jo...@gmail.com>
Thank you, I will take a look. So remove apache and use WSGI is recommended?


On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>

Hi looks positive. What is gunicorn.conf? I cannot find this file.


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {

server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
If I use apache, virtualhost is something I should study and configure to do the same?

On Thursday, 14 November 2013 00:08:37 UTC+8, CJ wrote:
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file. 


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

 www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
I developed a configuration for Apache with mod_wsgi or cgi
There are some stability issues related to the response time of apache, but if you want to move on, follow the settings.


https://gist.github.com/MaxMorais/7187526


Another issue is to perform an installation on a CPanel environment, or shared-hosting, will bring you some headaches, as a means to replace memcached, some servers do not support shared, and some modifications related connections with the base data.



2013/11/13 CJ <jo…@gmail.com>

If I use apache, virtualhost is something I should study and configure to do the same?


On Thursday, 14 November 2013 00:08:37 UTC+8, CJ wrote:
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file.


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {

server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Interesting but fun.

I can't just install 2 copy of erpnext on different directory, modify conf file to use different DB and then configure apache with example:

Server configuration

Listen 80
Listen 8080

NameVirtualHost 172.20.30.40:80
NameVirtualHost 172.20.30.40:8080

<VirtualHost 172.20.30.40:80>
ServerName www.example.com
DocumentRoot /www/domain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.com
DocumentRoot /www/domain-8080
</VirtualHost>

<VirtualHost 172.20.30.40:80>
ServerName www.example.org
DocumentRoot /www/otherdomain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.org
DocumentRoot /www/otherdomain-8080
</VirtualHost>


This is not enough to achieve it?


On Thursday, 14 November 2013 00:21:23 UTC+8, Maxwell wrote:
I developed a configuration for Apache with mod_wsgi or cgi
There are some stability issues related to the response time of apache, but if you want to move on, follow the settings.


Another issue is to perform an installation on a CPanel environment, or shared-hosting, will bring you some headaches, as a means to replace memcached, some servers do not support shared, and some modifications related connections with the base data.


2013/11/13 CJ <jo…@gmail.com>
If I use apache, virtualhost is something I should study and configure to do the same?


On Thursday, 14 November 2013 00:08:37 UTC+8, CJ wrote:
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file. 


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

 www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Yes you can, my folders APP and LIB, are just links to another directory, where all files, I use a custom file conf.py and run "./lib/wnf.py --reinstall" to each new installation.






2013/11/13 CJ <jo…@gmail.com>

Interesting but fun.

I can't just install 2 copy of erpnext on different directory, modify conf file to use different DB and then configure apache with example:

Server configuration

Listen 80
Listen 8080

NameVirtualHost 172.20.30.40:80
NameVirtualHost 172.20.30.40:8080


<VirtualHost 172.20.30.40:80>
ServerName www.example.com

DocumentRoot /www/domain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.com

DocumentRoot /www/domain-8080
</VirtualHost>

<VirtualHost 172.20.30.40:80>
ServerName www.example.org

DocumentRoot /www/otherdomain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.org

DocumentRoot /www/otherdomain-8080
</VirtualHost>


This is not enough to achieve it?


On Thursday, 14 November 2013 00:21:23 UTC+8, Maxwell wrote:

I developed a configuration for Apache with mod_wsgi or cgi
There are some stability issues related to the response time of apache, but if you want to move on, follow the settings.



Another issue is to perform an installation on a CPanel environment, or shared-hosting, will bring you some headaches, as a means to replace memcached, some servers do not support shared, and some modifications related connections with the base data.



2013/11/13 CJ <jo…@gmail.com>

If I use apache, virtualhost is something I should study and configure to do the same?


On Thursday, 14 November 2013 00:08:37 UTC+8, CJ wrote:
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file.


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {

server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:



If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.



    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Thank you, Maxwell.

On Thursday, 14 November 2013 00:47:53 UTC+8, Maxwell wrote:
Yes you can, my folders APP and LIB, are just links to another directory, where all files, I use a custom file conf.py and run "./lib/wnf.py --reinstall" to each new installation.






2013/11/13 CJ <jo…@gmail.com>
Interesting but fun.

I can't just install 2 copy of erpnext on different directory, modify conf file to use different DB and then configure apache with example:

Server configuration

Listen 80
Listen 8080

NameVirtualHost 172.20.30.40:80
NameVirtualHost 172.20.30.40:8080


<VirtualHost 172.20.30.40:80>
ServerName www.example.com

DocumentRoot /www/domain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.com

DocumentRoot /www/domain-8080
</VirtualHost>

<VirtualHost 172.20.30.40:80>
ServerName www.example.org

DocumentRoot /www/otherdomain-80
</VirtualHost>

<VirtualHost 172.20.30.40:8080>
ServerName www.example.org

DocumentRoot /www/otherdomain-8080
</VirtualHost>


This is not enough to achieve it?


On Thursday, 14 November 2013 00:21:23 UTC+8, Maxwell wrote:
I developed a configuration for Apache with mod_wsgi or cgi
There are some stability issues related to the response time of apache, but if you want to move on, follow the settings.


Another issue is to perform an installation on a CPanel environment, or shared-hosting, will bring you some headaches, as a means to replace memcached, some servers do not support shared, and some modifications related connections with the base data.


2013/11/13 CJ <jo…@gmail.com>

If I use apache, virtualhost is something I should study and configure to do the same?


On Thursday, 14 November 2013 00:08:37 UTC+8, CJ wrote:
Thank you, I will take a look. So remove apache and use WSGI is recommended?

On Thursday, 14 November 2013 00:05:36 UTC+8, Maxwell wrote:


2013/11/13 CJ <jo...@gmail.com>
Hi looks positive. What is gunicorn.conf? I cannot find this file. 


On Wednesday, 13 November 2013 19:38:18 UTC+8, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>

Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+unsubscr…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un...@googlegroups.com.

    For more options, visit https://groups.google.com/groups/opt_out.
Hi Maxwell,

We upgrade our Erpnext 3.x to 4.x, but we can't start both instances into latest release. Can someone  explain how to start 2 instance into frappe app?

Best Regards

On Wednesday, November 13, 2013 1:38:18 PM UTC+2, Maxwell wrote:
P

lease, see my configuration

gunicorn.conf for supervisor

[program:gunicorn_mxmo]
command=gunicorn -b 127.0.0.1:7999 -w 2 lib.webnotes.app:application
directory=home/apra/mxmo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_realize]
command=gunicorn -b 127.0.0.1:8000 -w 2 lib.webnotes.app:application
directory=/home/apra/next
user=erpnext
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

[program:gunicorn_demo]
command=gunicorn -b 127.0.0.1:8001 -w 2 lib.webnotes.app:application
directory=/home/apra/demo
process_name=%(program_name)s
autostart=True
autorestart=True
redirect_stderr=True

erpnext-mxmo.conf

upstream erpnextmxmo {
server <a href="http://127.0.0.1:7999/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2F127.0.0.1%3A7999%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNGssQIKVgaMARGaEdQIeI3yIgP32A';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2F127.0.0.1%3A7999%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNGssQIKVgaMARGaEdQIeI3yIgP32A';return true;">127.0.0.1:7999</a> fail_timeout=0;    

}

server {
listen 80;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/mxmo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextmxmo/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextmxmo%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEtZzteTiFQ2RLRMutNT2A7CuGlXQ';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextmxmo%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEtZzteTiFQ2RLRMutNT2A7CuGlXQ';return true;">http://erpnextmxmo</a>;
}

}

erpnext-realize.conf

upstream erpnextrealize {
server 127.0.0.1:8000 fail_timeout=0;
}

server {
listen 8080;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/maxwell/next/public;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextrealize/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextrealize%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEKoGR_xKSSYaJDxi_9UgrFtrWgMA';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextrealize%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEKoGR_xKSSYaJDxi_9UgrFtrWgMA';return true;">http://erpnextrealize</a>;
}

}

erpnext-demo.conf

upstream erpnextdemo {
server 127.0.0.1:8001 fail_timeout=0;
}

server {
listen 8081;
server_name $hostname;
client_max_body_size 4G;
server_name localhost;
keepalive_timeout 5;
root /home/apra/demo;

location / {
    try_files $uri @magic;
}

location @magic {
    proxy_set_header X-Forwaded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect off;
    proxy_pass <a href="http://erpnextdemo/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextdemo%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNGkjguoZWy5G1BeVZWwHhRDi2095A';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Ferpnextdemo%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNGkjguoZWy5G1BeVZWwHhRDi2095A';return true;">http://erpnextdemo</a>;
}

}




2013/11/13 CJ <jo…@gmail.com>
Is this possible? Let's say one for SIT port 8080 and one for production port 8000 with different DB.



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.




--

Maxwell Morais
Tecnologia da Informação
+55 11 3931-1412 Ramal 31

 www.realizemodulados.com.br



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/b3b110af-5b92-448e-9f2a-8204a5490189%40googlegroups.com.

    For more options, visit https://groups.google.com/d/optout.



On Mon, Jul 14, 2014 at 5:00 PM, Sebastian Lungu <se...@gmail.com> wrote:
Hi Maxwell,

We upgrade our Erpnext 3.x to 4.x, but we can't start both instances into latest release. Can someone explain how to start 2 instance into frappe app?

Best Regards

Did you remove old supervisor and nginx config and copy the new config generated in config/ dir?

Also, as you've replied under this thread, are you running two frappe benches?

Thanks,
--
Pratik
erpnext

Hi Pratik,

Thanks for your quick reply.

Actually, we start for testing new virtual box file of Erpnext 4.x and we create 2 sites like in documentation  (https://erpnext.com/download)
We create 2 sites with commands:

frappe site1 --install dbname1
frappe  site2 --install dbname2
Both sites structure&db's was created.

We do the fallowing steps also:
  • cp config/nginx.conf /etc/nginx/conf.d/frappe.conf
  • cp config/supervisor.conf /etc/supervisor/conf.d/frappe.conf

Both files "frappe.conf" are automatically updated by frappe, when we add a new site? Or we need to modify manually?

Thanks in advanced  

On Monday, July 14, 2014 2:33:01 PM UTC+3, Pratik Vyas wrote:



On Mon, Jul 14, 2014 at 5:00 PM, Sebastian Lungu <se...@gmail.com> wrote:
Hi Maxwell,

We upgrade our Erpnext 3.x to 4.x, but we can't start both instances into latest release. Can someone  explain how to start 2 instance into frappe app?

Best Regards

Did you remove old supervisor and nginx config and copy the new config generated in config/ dir?

Also, as you've replied under this thread, are you running two frappe benches?

Thanks,
--
Pratik
erpnext



Note:

 

If you are posting an issue,

  1. We should be able to replicate it at our end. So please give us as much information as you can. Please see it from the point of view of the person receiving the communication.
  2. Paste your code at http://pastebin.com or http://gist.github.com and send only the URL via email
  3. For sending images, use http://imgur.com or other similar services. Do not send images as attachments. Links are good. Same goes for any file you are going to send.

     

    End of Note



    You received this message because you are subscribed to the Google Groups “ERPNext Developer Forum” group.

    To unsubscribe from this group and stop receiving emails from it, send an email to erpnext-developer-forum+un…@googlegroups.com.

    To view this discussion on the web visit https://groups.google.com/d/msgid/erpnext-developer-forum/be8a27dd-c037-4c91-8f0c-b50e44fed4b7%40googlegroups.com.

    For more options, visit https://groups.google.com/d/optout.