[SearXNG] a free internet metasearch engine (fork of Searx)

Hello everyone,

As I really prefer SearXNG over Searx, I launched myself into packaging it. You can find my progress here. Please note that as of today, this app is NOT ready to use.

I’m posting here to give news about my progress, to ask for help regarding some troubles I run into while packaging and seek advice from more experienced packagers, and to get feedback from testers (once my package will be suitable for testing). I’ll update this post regularly to give feedback about my progress.

I’m using mainly this doc to guide me for packaging, along with a strong inspiration from the YNH Searx package which is obviously very similar to the one I’m creating.

My progress :

  • I’m currently working on making the install script work. I’m stuck trying to run and daemonise uwsgi correctly.

My problems / questions :

  • I’m not sure how to deal with the fact that SearXNG is a rolling-release. Can I automate the packaging process with CI to always keep up with the latest version or am I supposed to do it a different way (for example, plan only one release per month) ?
    Answer here :
  • For now, I’m getting the source using the ynh_setup_source helper to get a tarball. However some functionalities (such as running the app or updating) would be easier using git commands. Is there a specific helper to manage git repos and / or can I do it by myself in the install scripts without impacting the YNH instance ?
    Answer here :

Thanks in advance for your feedback and advices.

2 Likes

i run this now with docker. i don’t know if you’re allowed to package it like this but it would be cool to have like docker ‘apps’ that just work.

docker isn’t that hard, but could really help the newer people to linux. maybe that would be the opposite of what Yunohost is trying to do

Indeed, Docker is an easy way to do this. I saw some attempts like this one to bring Docker to YNH, without success it seems. I don’t know if YNH maintainers have an opinion on this, but I think using Docker images are not the targeted goal when packaging apps.

1 Like

Hi,

Happy to see someone trying to package searxng :slight_smile:

I’m not sure how to deal with the fact that SearXNG is a rolling-release. Can I automate the packaging process with CI to always keep up with the latest version or am I supposed to do it a different way (for example, plan only one release per month) ?

We provide a way to automate the PR creation when a new release appears.

You can find an example of this in limesurvey_ynh/.github at master · YunoHost-Apps/limesurvey_ynh · GitHub

So if you create the samed .github and change a bit updater.sh you will get PR created after each SearXNG release.

Could you elaborate on the advantage to get this as a git repos ?

The normal way for yunohost is the tarball way, and with the sha256 hash. We prefer to stick a specific version (cause we need our CI to test this specific version we publish). So that’s mean that just cloning a repo or git pull it, is a bad practice for us, cause you d’ont know if the upstream (searxng) will make some breaking changes.

Some packages use docker images, others download docker images to extract build arm version. But in your case it’s just a simple python app, so you should keep it simple without docker.

Note: in yunohost 11.1 beta you can test the new app v2 mechanism with manifest.toml. There is a conversion script to convert an app from v1 to v2 format.

Hi @ljf, and thanks for your answers.

I’ll take a look at that then. I don’t know if there is some limitations to the CI/CD time on GitHub, but for this simple usage I suppose that’ll do.

There is two :

  • The app is designed to run as a git repo. This means that Flask, for example, use info stored in the .git folder to run. The app run nevertheless (even if throwing errors), and I haven’t found yet if this is introducing bugs.
  • There are .sh scripts helpers for installing and updating the app, relying on git. I thought about using them to package the app, but they need that the app have been git cloned in the first place.

None of these two issues is a real problem, and I can work around if needed. I was just wondering if it was possible to work from a git repo, if not the tar.gz will do.

I haven’t found if there is a unified version to install / manage docker in YNH. But you’re right, it would be better to skip Docker and to make it work from scratch. However it could be nice as a backup if I’m not able to package (fastly enough) searxng.

Thanks for the tip, I’ll take a look. I haven’t found info on this, will there be a mandatory switch from v1 to v2, and if yes what will be the time frame ?

It’s possible however it’s better to use tar.gz and checksum in order to migrate easily on the new app v2 mechanism (and the future v3).

With Alsace Réseau Neutre we plan to go from searx to searxng, but we have not to much time currently.