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

Use the Conda package management system or AppImage for rootless portable installations #63

Open
ehfd opened this issue Oct 19, 2022 · 6 comments
Labels
CI/CD CI/CD procedures or container usage enhancement New feature or request good first issue Good for newcomers help wanted External contribution is required

Comments

@ehfd
Copy link
Member

ehfd commented Oct 19, 2022

https://docs.conda.io/en/latest/

This is possible. Conda enables installing packages without regard to ABI or OS compatibility, and GStreamer/GST-Python are usually updated to most new stable and development versions. The plugins are also in the repository. Even if the plugins are old, we can request Anaconda to update them to the recent versions.

The CUDA Toolkit is also always available from NVIDIA. Most dependencies including the X related ones will also be ready in an OS agnostic way.

If we create a conda package for Selkies-GStreamer, this will lead to effortless installations of both gst-web and the Python components absolutely without root whatsoever, because it creates its own dependency environment. This is also the most academia way to install a package (lots of support from ML and other related projects), and it will help usage of Selkies in HPC clusters that use batch schedulers such as SLURM.

We have a choice; adding this package to the conda-forge channel and let them compile the project, or to build the package with GitHub Actions and push it to our own channel. In the latter case, we may provide custom GStreamer builds as well.

Contribution from interested parties are welcome, and this is also a good first issue if you are accustomed to conda.

@ehfd ehfd added enhancement New feature or request good first issue Good for newcomers help wanted External contribution is required CI/CD CI/CD procedures or container usage labels Oct 19, 2022
@ehfd
Copy link
Member Author

ehfd commented Oct 29, 2022

This can also enable distro-agnostic ready-to-go distribution of Selkies-GStreamer with GStreamer, gst-web, Python files, and CUDA ready to run anywhere, if we just build and package everything with Conda's own Python interpreter and build environment.

@ehfd
Copy link
Member Author

ehfd commented May 7, 2023

On conda:

From @elgalu:

Cool! so I installed a few gstreamer gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-python gst-libav webrtcvad and now the list of missing plugins is reduced to 3: 'Missing gstreamer plugins:', ['nice', 'webrtc', 'srtp']

Me:

sudo apt-get update && sudo apt-get install --no-install-recommends -y adwaita-icon-theme-full build-essential python3-pip python3-dev python3-gi python3-setuptools python3-wheel tzdata sudo udev xclip x11-utils xdotool wmctrl jq gdebi-core x11-xserver-utils xserver-xorg-core libopus0 libgdk-pixbuf2.0-0 libsrtp2-1 libxdamage1 libxml2-dev libwebrtc-audio-processing1 libcairo-gobject2 pulseaudio libpulse0 libpangocairo-1.0-0 libgirepository1.0-dev libjpeg-dev libvpx-dev zlib1g-dev x264

This was the long list of dependencies, where I believe you might want to find or build 'nice', 'webrtc', 'srtp' manually on Conda. An alternative for apt's libwebrtc-audio-processing1, libsrtp2-1, and gir1.2-nice-0.1 or libnice10 is needed. I see that there is a separate package gstreamer1.0-nice in apt.

I think: pylibsrtp provides srtp.

https://webrtc.googlesource.com/src
https://gitlab.freedesktop.org/libnice/libnice

https://developer.ridgerun.com/wiki/index.php/GStreamer_WebRTC_Wrapper/Getting_the_Code/Building_and_Installation_Guide
https://gitlab.freedesktop.org/libnice/libnice/-/issues/112
https://webrtcmagazine.wordpress.com/tag/libnice/

This is pretty much uncharted territory, and I would really appreciate if you could test things. You could ask on #gstreamer at oftc.org IRC or #_oftc_#gstreamer:matrix.org on Matrix for help from GStreamer devs.

@ehfd
Copy link
Member Author

ehfd commented May 7, 2023

Would be really nice if we knew all the set of dependencies which could be installed with just conda and pip.
In theory, anything can be built using Conda's own toolchain.

https://anaconda.org/anaconda/gcc_linux-64
https://anaconda.org/anaconda/gxx_linux-64

@ehfd
Copy link
Member Author

ehfd commented Nov 9, 2023

This seems easier because the CUDA dependency was reduced to NVRTC only.

@ehfd
Copy link
Member Author

ehfd commented Mar 24, 2024

If anyone does this, make sure to start from Miniconda and enable only conda-forge. anaconda channel is proprietary.

@ehfd ehfd changed the title Use the conda package management system for rootless installations Use the Conda package management system or AppImage for rootless installations Apr 22, 2024
@ehfd ehfd changed the title Use the Conda package management system or AppImage for rootless installations Use the Conda package management system or AppImage for rootless portable installations Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI/CD CI/CD procedures or container usage enhancement New feature or request good first issue Good for newcomers help wanted External contribution is required
Projects
None yet
Development

No branches or pull requests

1 participant