Skip to content
YACReader
Help and support for MacOSX users.

How do start YACReaderLibraryServer on OSX?

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 4 days ago #4293 by cloudy
How do start the headless server in OSX? I guess though a plist, but I can't find one that's working, nor I was able to write one on my own. Any hint?

Please Log in or Create an account to join the conversation.

More
8 years 4 days ago #4295 by Luis Ángel
Replied by Luis Ángel on topic How do start YACReaderLibraryServer on OSX?
Run it from the console, YACReaderLibraryServer is a console app for macos it is bundled so it has all the libraries it needs with the appropriate folders structure.
Code:
./YACReaderLibraryServer/Contents/MacOS/YACReaderLibraryServer start

Contribute to the project becoming a patron: www.patreon.com/yacreader
You can also donate via Pay-Pal: www.paypal.com/donate?business=5TAMNQCDD...e=Support+YACReader\

Please Log in or Create an account to join the conversation.

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 3 days ago #4297 by cloudy
Replied by cloudy on topic How do start YACReaderLibraryServer on OSX?
Well, yes, but no ;)

headless also means I shouldn't be bordered to open a terminal to run it. It should be handled as a service.

On GNU/Linux I should be able to run it through some initi.d script, on Mac OS I should be able to accomplish that through a plist xml file to feed launchctl.

I've created some, but it never starts, almost as if it can only run on foreground. If that's it, then it's not a server, pardon me :evil:

Please Log in or Create an account to join the conversation.

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 3 days ago #4299 by cloudy
Replied by cloudy on topic How do start YACReaderLibraryServer on OSX?
Uhm... never mind what I said earlier today: I've got it to work, though it shows there are 0 libraries configured.

As soon as I figure this out, I'll post the plist.

P.S.: would be nice to add options and commands to the server (options like --set-port --use-library etc.. and commands like show-running-config etc..) which would help with debugging.

Please Log in or Create an account to join the conversation.

More
8 years 3 days ago #4300 by Luis Ángel
Replied by Luis Ángel on topic How do start YACReaderLibraryServer on OSX?
There are instructions in the source code to run the server using systemd as a service in linux.

systemctl is used to enable the service, maybe you can use launchctl in macos.

Since YACReader has to run in multiple platforns choosing the right way to running YACReaderLibraryServer is up to the user.

One limitation is that YACReaderLibrary and YACReaderLibraryServer can't run at the same time. The idea to fix this is that the service should be replaced by YACReaderLibrary when it is running and after it closes the service should start running again. Patches are welcome.

Contribute to the project becoming a patron: www.patreon.com/yacreader
You can also donate via Pay-Pal: www.paypal.com/donate?business=5TAMNQCDD...e=Support+YACReader\

Please Log in or Create an account to join the conversation.

More
8 years 3 days ago #4302 by Luis Ángel
Replied by Luis Ángel on topic How do start YACReaderLibraryServer on OSX?

cloudy wrote: P.S.: would be nice to add options and commands to the server (options like --set-port --use-library etc.. and commands like show-running-config etc..) which would help with debugging.


Sure, implementing additional commands should be pretty straight forward, feel free to send a pull request in github.

Contribute to the project becoming a patron: www.patreon.com/yacreader
You can also donate via Pay-Pal: www.paypal.com/donate?business=5TAMNQCDD...e=Support+YACReader\

Please Log in or Create an account to join the conversation.

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 2 days ago #4305 by cloudy
Replied by cloudy on topic How do start YACReaderLibraryServer on OSX?
I just discovered something.

The plist I quickly draft for running YACReaderLibraryServer as a service with launchctl is actually working fine on Mac OS 10.13.

The problem I had, was due to the fact that I was working on a Mac OS 10.14.

It seems to listen on random ports instead of the one configured in the ini file, when launched on Mojave.

Please Log in or Create an account to join the conversation.

More
8 years 2 days ago #4306 by Luis Ángel
Replied by Luis Ángel on topic How do start YACReaderLibraryServer on OSX?
If the port configured is already being used the server chooses another on randomly.

Contribute to the project becoming a patron: www.patreon.com/yacreader
You can also donate via Pay-Pal: www.paypal.com/donate?business=5TAMNQCDD...e=Support+YACReader\

Please Log in or Create an account to join the conversation.

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
8 years 2 days ago #4307 by cloudy
Replied by cloudy on topic How do start YACReaderLibraryServer on OSX?
Yes, that must be it.

I am sure there was no other service running on that port, but for some reason, every time I started the server it started listening on two different ports: the one set in the ini file, and another one random (never showing the actual library, anyway, just a blank page).

After starting fresh it's now working as expected.

I still don't see anything on Safari for Mojave, though the important thing is I see the content of the library from the iPad.

Please Log in or Create an account to join the conversation.

  • cloudy
  • Topic Author
  • Offline
  • New Member
  • New Member
More
7 years 11 months ago - 7 years 7 months ago #4318 by cloudy
Replied by cloudy on topic How do start YACReaderLibraryServer on OSX?
I attached a couple of launchd plist files.

The first one (

Attachment not found

) serves to start the headless server, and tries to keep it running.
The second one (

Attachment not found


) is meant to auto-update the library database whenever the Library source folder is changed.

Both files should be put in
Code:
~/Library/LaunchAgents/
(just rename them as *.plist).

Pros & Cons:


Pros: never worry about manually starting or updating the library
Cons: YACReaderLibrary cannot run, as it's antagonist to YACReaderLibraryServer

P.S.: Of course you can always run only the second file, and having the library updated on cue, and still have the ability to fire up YACReaderLibrary
Last edit: 7 years 7 months ago by cloudy.
The following user(s) said Thank You: Luis Ángel

Please Log in or Create an account to join the conversation.

Moderators: Luis Ángel
Powered by Kunena Forum

Thanks for downloading YACReader!

Your download is starting.

YACReader for iOS and Android

Connect to YACReaderLibrary to browse, read remotely and import comics. Your reading progress is synchronized across devices.

Download on the App Store Get it on Google Play Available at Amazon Appstore

Discover all the features on the iOS and Android pages, and learn how to use them in the iOS and Android user guides.

Support YACReader

YACReader for desktop and server is free to use, but it is not free to develop: maintaining this website, developer programs, code signing certificates, test devices and, of course, all the time it takes. Less than 0.01% of downloads end in a donation, so any amount counts.

By supporting the project you help keep it regularly updated and, most importantly, alive. Thanks!