manuskript icon indicating copy to clipboard operation
manuskript copied to clipboard

[Feature request] Docker image?

Open janaxhell opened this issue 1 year ago • 10 comments

Any chance to have a docker version of this to install on a server with docker-compose? An ubiquitous instance would be very convenient.

janaxhell avatar May 18 '23 12:05 janaxhell

I think you could just use an Ubuntu docker image and install via snap the latest version on it. If that doesn't work for you, feel free to setup a docker image which fits your needs and share your experience.

TheJackiMonster avatar May 19 '23 09:05 TheJackiMonster

Ok, no, I'm on Open Media Vault, so no snap here and also I'm not a dev, creating an image is totally out of my reach. I was asking just because I'm populating my server with useful tools and wondered if I could deploy this as well. Thanks anyway.

janaxhell avatar May 19 '23 09:05 janaxhell

I might have a go a creating a docker image - because I was wondering if I could use it through WSL.

computamike avatar Jun 05 '23 23:06 computamike

I might have a go a creating a docker image - because I was wondering if I could use it through WSL.

Hope you succeed!

janaxhell avatar Jun 06 '23 07:06 janaxhell

It might not be that straightforward to run a graphical application in a container and to be able to see it as a regular app running on your box. A container might be created per Operating System to be able to make it happen.

Ideally the code would be written in a way where the UI is completely separated from the rest of the code. In such a case a web based UI could be written and accessible via the web browser which would communicate with the rest of the application running locally, in the container or on the server. I know there is a GTK port ongoing but I am not sure how the UI part will be integrated with the rest.

On Tue, 6 Jun 2023 at 08:25, janaxhell @.***> wrote:

I might have a go a creating a docker image - because I was wondering if I could use it through WSL.

Hope you succeed!

— Reply to this email directly, view it on GitHub https://github.com/olivierkes/manuskript/issues/1166#issuecomment-1578071925, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA6DH34KTBUDYHE2REKMJEDXJ3LPNANCNFSM6AAAAAAYGL2IVA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

marosoft avatar Jun 29 '23 19:06 marosoft

hi @marosoft - I think you're right that it will be a challenge. I think I might be able to accomplish it using x-forwarding(?) - but that would mean that it isn't a 100% "only docker" thing (you'd also need to run a xserver on your machine). I also found this document https://www.geeksforgeeks.org/how-to-run-gui-based-applications-inside-docker/ - but I have absolutely no idea about whether it is applicable to Manuskript (honestly - I've only scanned it for a couple of seconds.)- I basically stumbled onto this repository and wondered if this idea would work.

Edit: I read through that article and it appears to be performing x11 forwarding on a linux host - so the same mechanism I was suggesting (as far as I can see)

computamike avatar Jun 30 '23 21:06 computamike

ok -I have had a play - and @marosoft - you were right - it was a pain but I have something that kind of is interesting working. WLS2 has support for x11 forwarding - so if you're running docker desktop on windows and you have docker desktop running, then if you execute the you can pass the DISPLAY environment through to the container and it all links and you end up with something that seems to work : image

wsl2 has a built in x11 server, allowing you to run x11 applications - so that works nice.

Some strangeness - I noticed that the mouse changes based on whether it's interactive with the window chrome, or the interface : image

I haven't had a good play with it yet - so I'll have a look and update further

computamike avatar Jun 30 '23 23:06 computamike

Hi @computamike

This looks great! Well done! Might be good to share the steps it took you to have it up and running. If you can.

Of course this does not make it possible to use for everyone but it can help some for sure.

marosoft avatar Jul 01 '23 14:07 marosoft

For the future it would be pretty interesting how easy it is to setup Linux binaries on Windows via WSL in general. Because we have a much more reliable build process for releases on Linux than for Windows. If there were no practical downsides to users, using a Linux release on Windows via WSL had the advantage of relying on up-to-date packages as well as Python and reproducing issues could be easier as well.

If flatpaks or snap packages would work via WSL, we could even have automatic update cycles on Windows without own infrastructure or mechanisms for that specifically.

So that might become an interesting option besides the Windows binary for Windows users.

TheJackiMonster avatar Jul 01 '23 14:07 TheJackiMonster

I am unsure of the best way to share my workings - so I threw together a repository with them on :

https://github.com/computamike/manuskript-docker

Hopefully that is useful.

I included the example book of acts as a mounted volume.

computamike avatar Jul 18 '23 23:07 computamike