![]() |
#1 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Sep 2010
Location: Houston
Device: Kindle
|
content server file location
Hi, I have calibre running on a box that's also already a web server. Rather than also running the content server, I would like to just setup another virtualhost to serve the calibre content. The server is a mac running apache.
Thanks |
![]() |
![]() |
![]() |
#2 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
|
You might want to look at calibre2opds to handle such a scenario? That is how I have my system set up to deliver the content from a machine that is running apache (and that is also not capable or running calibre as it happens).
In theory I think it might also be possible to make the Content server run under apache but I have no idea how easy that would be and it also means the full calibre software install needs to be inlace. Last edited by itimpi; 09-01-2010 at 06:46 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Sep 2010
Location: Houston
Device: Kindle
|
i took a look at calibre2opds, but would much rather use the output provided by the content server which also doesn't require the program to run every time new books are added.
it's not that i don't want the content server running, but the ability to resolve a hostname rather than the ip. so i don't mind running the content server, but would also like to setup a virtual host to it and just would need the path to the output files. |
![]() |
![]() |
![]() |
#4 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
|
Quote:
|
|
![]() |
![]() |
![]() |
#5 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,322
Karma: 8012652
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Quote:
You have three choices: 1) use a different port. All of your server's DNS names will work to access calibre. This is the standard configuration and dead-easy to set up. 2) get a second IP address. Bind apache to the first one, and 'bind' calibre to the second one. Calibre does not support IP binding, so you will need to do port translation in your firewall (2nd-ip:80 -> 2nd-ip:calibre_port). Of course, you will need to set up DNS names for the second IP. 3) Use something like Squid in reverse-proxy mode and vhost directives. See http://wiki.squid-cache.org/SquidFaq/ReverseProxy. Only the vhost(s) configured will be able to access calibre. #3 is probably what you want, but can be complicated to set up. |
|
![]() |
![]() |
Advert | |
|
![]() |
#6 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
|
Quote:
|
|
![]() |
![]() |
![]() |
#7 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,163
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
you can also use apache in reverse proxy mode.
|
![]() |
![]() |
![]() |
#8 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,322
Karma: 8012652
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
|
![]() |
![]() |
![]() |
#9 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,322
Karma: 8012652
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Quote:
calibre2opds generates a slew of static HTML pages. If you copy them into Apache's document space somewhere, then poof, you have a web site. There are no programs required other than apache. You get apache's multithreading, url rewriting, virtual hosting, etc. You can use SSL. I use calibre2opds, and use dropbox to move the pages automatically when I regenerate them. One reason I do this is that I don't want to take the trouble of installing calibre on my production web server (distro too old). Calibre's content server is active. You must install it, with all its dependencies, and then run it and maintain it. The library must be visible to it, or probably copied to it. It uses memory, which might be precious on the server (I often run on servers with 512kb total ram). It wants to talk HTTP over TCP, meaning that anything in front of it must act like a client. It doesn't support SSL (authentication is visible) or password-per-user. However, it does give up-to-date answers, which is a very good thing. To run calibre's content server in a single web space with other web servers (one name, one port), you must set up a 'reverse proxy' that knows where to direct the network packets, and knows how to munge them on the way back. I know how to do this with squid (have done), and today learned that apache can also do it. This doesn't solve the other problems such as old distros, but it is a good step forward. |
|
![]() |
![]() |
![]() |
#10 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
|
Quote:
|
|
![]() |
![]() |
![]() |
#11 | ||
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 12,322
Karma: 8012652
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
|
Quote:
Quote:
|
||
![]() |
![]() |
![]() |
#12 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
|
|
![]() |
![]() |
![]() |
#13 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,163
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
That's because the /stanza feed has no rel attribute on its <link> elements. Which means that firefox uses one of them as the link.
|
![]() |
![]() |
![]() |
#14 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
|
Quote:
![]() I have been meaning to try to write up a clear distinction between the two cases with pros and cons for inclusion in the standard calibre2opds documentation ![]() I might also try and provide text to Kovid to see if he is interested in including it in the Calibre User Manual both to clarify the use of the Calibre Content Server, and also to include a link to the calibre2opds site for those who might find it more appropriate. Not sure if he will be interested or not in including it! |
|
![]() |
![]() |
![]() |
#15 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,163
Karma: 27110894
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Documentation is always welcome
![]() |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
File location for eBooks | jgsmith | Sony Reader | 5 | 12-31-2009 10:39 AM |
Kindle Content Location Restrictions | Johan_ZA | Amazon Kindle | 7 | 12-21-2009 08:51 AM |
Content Server | thibaulthalpern | Calibre | 5 | 04-28-2009 12:56 PM |
Sony Reader file location question..... | krighton | Sony Reader | 11 | 07-02-2008 10:05 PM |
Connect File Location? | FrankBlack | Sony Reader | 6 | 03-17-2007 01:54 PM |