I would like to serve the Sage notebook running in a VM on a real
machine that is not the Apache server machine.

I am running into similar issues ...

>> >> Unfortunately, in sage the html links are all absolute rather tha
>> >> relative  so I can redirecthttp://myserver/sageto port 8000 but the
>> >> the links go tohttp://myserver/login(say) rather than http://
>> >> myserver/sage/login.
>
>>
>> > I think you can use apache to be aproxyandreverseproxy, using re-
>> > write rules to map the urls both directions (as well as ports). This
>> > is probably the best bet (correct me if I'm wrong, but doesn't
>> > sagenb.org work this way?).

In /etc/httpd/conf.d/sage.conf I put:

ProxyPass /sage http://172.16.194.129
ProxyPassReverse /sage http://172.16.194.129

The IP address is what sage reported after starting the notebook in
the VM.  I had to set routes and IP forwarding, and the sage notebook
responds now.

I think the absolute links make my sage.conf insufficient to really
serve the content from the Apache server (there are no graphics, some
links don't work, etc.)

>>
>> This is how sagenb.org works.  This is in httpd.conf.  It's maybe even
>> more complicated because the computer serving the page isn't even the
>> same computer where the notebook server is running.
>>
>> <VirtualHost *>
>>   RewriteEngine On
>>   ServerName sagenb.org
>>   ProxyPass    /http://sagenb.org:8000/
>>   ProxyPassReverse /http://sagenb.org:8000/
>>   DocumentRoot /
>>         <Location />
>>            DefaultType text/html
>>         </Location>
>> </VirtualHost>
>
I want to serve the Sage notebook within the tree structure of an
existing Apache server, but also running in a VM on a different
machine.  I.e., http://existing.apache.server/sage would reverse proxy
the sage notebook running in the VM.  Would a simple modification to
the apache config allow this?

I'm a Sage and Apache newbie so any suggestions you may have will be
gratefully received.

Thank you,
Richard Graham

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to