Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request]Enhancing ArozOS with Electron App Integration #115

Closed
Secarian opened this issue Feb 1, 2023 · 5 comments
Closed

[Feature Request]Enhancing ArozOS with Electron App Integration #115

Secarian opened this issue Feb 1, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@Secarian
Copy link
Contributor

Secarian commented Feb 1, 2023

Is your feature request related to a problem? Please describe.
As a user of ArozOS, I would like the ability to install and use Electron apps within the web desktop environment because there are many high-quality Electron apps that would greatly enhance the functionality of ArozOS. Currently, there is no straightforward way to use Electron apps within ArozOS.

Describe the solution you'd like
I would like a feature that allows for the easy installation and use of Electron applications within ArozOS. This would include a streamlined process for embedding Electron apps within ArozOS, as well as the necessary APIs and libraries for communication between the Electron app and ArozOS. The feature should also include a user-friendly interface for managing Electron apps within ArozOS.

Describe alternatives you've considered
I have not found any alternative solutions that would allow me to easily use Electron apps within ArozOS.

Additional context
This feature would greatly improve the functionality and capabilities of ArozOS by allowing users to access and use a wide range of Electron apps. The ability to easily install and use Electron apps within ArozOS would also make it a more attractive option for users who are looking for a web desktop environment.

@Secarian Secarian added the enhancement New feature or request label Feb 1, 2023
@tobychui
Copy link
Owner

tobychui commented Feb 2, 2023

Hi @Secarian ,

Short Answer
It is possible to use Electron Apps (or other webapps that has a web interface) with ArozOS using the subservice interface. Here is an example of such use case with Syncthing
https://github.com/aroz-online/syncthing

What you need is a simple config file and some bash script to glue them together. (Note the .startscript, moduleInfo.json and start.sh file)

Long Answer
The above solution is only design for single user. If you have multiple users using the same server, the setup above will breaks the user environment sandbox design guideline (i.e. you and other users will see the same instance / state of the subservice interface mounted webapp)

There are a few reasons why ArozOS did not support existing webapps (like Electrons, React or others) out of the box. It is because of its complexity in sandbox and user isolated environment where normal webapps cannot be installed without big rewrites.

We did consider solving this in previous development cycles and here is what we had came up with
image
However, in order to maintain sandbox and user isolation requirements, you will need to create a docker container per user per app and keep such FUSE mount connection to the local file server which exposes the virtual file system layer. We think that this is too computational heavy for SBCs and that is why we didn't include it out of the box.

Still, if you are interested to work on this project, feel free to create a subservice just for high power server. We can include them in the official list of WebApps and subservice for others to reference.

If there are no further issue, I will be closing this enhancement request.

@markusbkk
Copy link

I don't think this is feasible the way @Secarian intends this. Not without tons of additional work anyways.
Electron apps bundle Chromium/V8. They aren't just simple PWAs but include an entire render process.

Without introducing a display protocol Chromium understands, there's no way to render those Electron app windows.

I'm currently busy with another project (I'm working on an alternative to node/bun/deno) but my idea to make this (and other GUI apps) work was to implement something like Greenfield.

@Secarian
Copy link
Contributor Author

Secarian commented Feb 3, 2023

I actually have to agree with you, Greenfield seems to be the better option.
Just one more clarification question?
Wouldn't Docker still be required to provide the container for the application runtime environment?

@markusbkk
Copy link

I actually have to agree with you, Greenfield seems to be the better option. Just one more clarification question? Wouldn't Docker still be required to provide the container for the application runtime environment?

Yea. The Docker requirement is accurate. Although I think you'd only need to dockerize the Wayland compositor for most use cases.

@Secarian Secarian changed the title [Enhancing ArozOS with Electron App Integration] [Feature Request]Enhancing ArozOS with Electron App Integration Feb 8, 2023
@tobychui
Copy link
Owner

As for now we don't have plan to support docker based Electron Apps (and WebVNC or X Client). I will close this but keeping #114 just in case someone is interested to add docker support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants