DSM

NAVIGATION
CATEGORIES
REFERRENCE
LINKS
  • Running 2 instances of Zope on Apache

    8 answers - 388 bytes - related search similar search Add To My Delicious Add To My Stumble Upon Add To My Google Mark Add To My Facebook Add To My Digg Add To My Reddit

    Hi,
    I am having trouble trying to get apache to use sub domains for my 2
    instances of zope.
    I want test.server name for one sub domain adn live.server for the other.
    The first sub domain for test instance of zope.
    The second sub domain for the lvie instance of zope.
    Anyone done this before?
    Can you show me an example of apache config file?
    Thanks
  • No.1 | | 1425 bytes | |

    What's your apache config?
    I suggest that you use ProxyPass. Something like this will work fine:

    <VirtualHost IPF.YUR.SERVER>
    ServerName dev.yoursite.com
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ProxyPass /

    ProxyPassReverse /

    ProxyPass /misc_ http://localhost:9080/misc_
    ProxyPass /p_ http://localhost:9080/p_
    ErrorLog /
    CustomLog / combined
    </VirtualHost>

    <VirtualHost IPF.YUR.SERVER>
    ServerName www.yoursite.com
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ProxyPass /

    ProxyPassReverse /

    ProxyPass /misc_ http://localhost:8080/misc_
    ProxyPass /p_ http://localhost:8080/p_
    ErrorLog /
    CustomLog / combined
    </VirtualHost>

    You'll need to enable mod_proxy for your apache and you'll need to run
    two Zopes on the same server. on port 8080 and one on port 9080.
    All the values I chose are all example values that you can play with.

    Best of luck!

    ianripping wrote:
    Hi,

    I am having trouble trying to get apache to use sub domains for my 2
    instances of zope.

    I want test.server name for one sub domain adn live.server for the other.
    The first sub domain for test instance of zope.
    The second sub domain for the lvie instance of zope.

    Anyone done this before?
    Can you show me an example of apache config file?

    Thanks
  • No.2 | | 443 bytes | |

    ianripping wrote at 2006-7-25 08:37 -0700:
    >I am having trouble trying to get apache to use sub domains for my 2
    >instances of zope.
    >
    >I want test.server name for one sub domain adn live.server for the other.
    >The first sub domain for test instance of zope.
    >The second sub domain for the lvie instance of zope.


    Read about "Named Virtual Hosts" in the Apache documentation.
  • No.3 | | 543 bytes | |

    I have tried using the exaplme provided but having no luck.

    This is my standard config file:

    <VirtualHost *:80>
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>

    I am using rewrite rule and this works for just the internal address
    http://commsg6lds

    How would I configure this for http://live.commsg6lds
    Do I have to enable NameVirtualHost?
    What should I have for listen? Currently:
    Listen 80
  • No.4 | | 778 bytes | |

    What does your RewriteRule Log tell you?

    http://betabug.ch/zope/witch

    Check out that site to help you write it out ;)

    Regards,

    Liew

    7/26/06, ianripping <ian.ripping (AT) cfh (DOT) nhs.ukwrote:

    I have tried using the exaplme provided but having no luck.

    This is my standard config file:

    <VirtualHost *:80>
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>

    I am using rewrite rule and this works for just the internal address
    http://commsg6lds

    How would I configure this for http://live.commsg6lds
    Do I have to enable NameVirtualHost?
    What should I have for listen? Currently:
    Listen 80
  • No.5 | | 1094 bytes | |

    How about something like this::
    <VirtualHost *:80>
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName live.commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>
    <VirtualHost *:80>
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName dev.commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>

    What way live.commsg61ds points to zope on port 8080
    and dev.commsg61ds points to another zope on port 9080

    ianripping wrote:
    I have tried using the exaplme provided but having no luck.

    This is my standard config file:

    <VirtualHost *:80>
    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>

    I am using rewrite rule and this works for just the internal address
    http://commsg6lds

    How would I configure this for http://live.commsg6lds
    Do I have to enable NameVirtualHost?
    What should I have for listen? Currently:
    Listen 80
  • No.6 | | 658 bytes | |

    ianripping wrote at 2006-7-26 01:30 -0700:

    ><VirtualHost *:80>

    ServerAdmin ian.ripping (AT) cfh (DOT) nhs.uk
    ServerName commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    >$1
    >[L,P]
    ></VirtualHost>
    >
    >I am using rewrite rule and this works for just the internal address
    >http://commsg6lds
    >
    >How would I configure this for http://live.commsg6lds
    >Do I have to enable NameVirtualHost?
    >What should I have for listen? Currently:
    >Listen 80


    You really should read Apache's "NameVirtualHost" documentation
  • No.7 | | 151 bytes | |

    I think this might be working but cant tell.
    Do I have to do something with my windows host file on my server to make
    these addresses naviagable?
  • No.8 | | 598 bytes | |

    It works!

    I had to change the <VirtualHost *:80entried to <VirtualHost
    dev.commsg6lds& <VirtualHost live.commsg6lds>

    Also had add IP addresses and domains to windows hosts file.

    Thanks for all the help!

    <VirtualHost dev.commsg6lds>
    ServerAdmin ian.ripping@
    ServerName dev.commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost

    <VirtualHost live.commsg6lds>
    ServerAdmin ian.ripping@
    ServerName live.commsg6lds
    RewriteEngine
    RewriteRule ^/(.*)
    $1
    [L,P]
    </VirtualHost>

Re: Running 2 instances of Zope on Apache


max 4000 letters.
Your nickname that display:
In order to stop the spam: 2 + 1 =
QUESTION ON "DSM"

EMSDN.COM