immich
immich copied to clipboard
Docker-less Alpine installation
Hi,
The docker-based installation is not convenient for everyone. For example, a docker-less installation would allow LXC/D containers usage, without using tricky tips for using Docker inside of them.
I already successfully installed a standalone Immich. This branch would be used for scripting a command-line interactive installation.
Thanks for your feedback!
FYI, you can run this image to run docker in LXC normally

This is how I run Immich on my Promox/LXC setup
There are some tips to run Docker in LXC containers (playing with nesting option if I remember), although IMO it is not the best way to do.
There are some tips to run Docker in LXC containers (playing with nesting option if I remember), although IMO it is not the best way to do.
What are the reasons?
Allowing a container to go out of its initial scope, even if sometimes it can be convenient, is not the good way just for running applications.
In the same way as in Docker you could use --privilegied, running a LXC container with privilegied rights could lead to some security flaws.
(My) PVE is hosting toons of services, I can't imagine a single one being able to disturb the host system.
Allowing a container to go out of its initial scope, even if sometimes it can be convenient, is not the good way just for running applications.
In the same way as in Docker you could use
--privilegied, running a LXC container with privilegied rights could lead to some security flaws. (My) PVE is hosting toons of services, I can't imagine a single one being able to disturb the host system.It's my point of view, I though it could interest some people. If not, we can close the PR, no problem.
Fair assessment. I was asking for my knowledge. You are welcome to implement the PR. I bet there are people that don't want to use Docker as a mean of deployment the app
Great news, thanks!
There are still a few bugs with Alpine services. I'm working on.
Hey @alextran1502,
I solved last bugs, you can try it yourself. If you encounter anything bad or think things different, please tell me, I'll try to do my best.
I tried to implement machine-learning in Alpine. I better understand why you have not set up machine-learning in an alpine image...
So for the moment, expected for ML, everything seems to work. ML installation is skipped.
Thanks for your feedback.
Hi @Chiogros, your contribution is so interesting. Your scripts are quite readable as well. Would you mind if I give you some questions?
- Can we put
/web/immich-web,/server/immich-server,/server/immich-microservices,/machine-learning/immich-machine-learningininstallationdirectory likealpine.sh? I found that these files may work only with Alpine OS, especially OpenRC. - Can we fetch
alpine_verdirectly from current user's OS? As you can see if user try to run your script on another alpine version, it can cause error from package updating.
I also have a plan to create standalone docker image by using PM2. I hope I can re-use your script.
Hi @panoti,
Can we put /web/immich-web, /server/immich-server, /server/immich-microservices, /machine-learning/immich-machine-learning in installation directory like alpine.sh? I found that these files may work only with Alpine OS, especially OpenRC.
I first thought about the same architecture as you: ./installation/services/openrc/.
In this way, we could then support systemd-based OS by mkdir-ing ./services/systemd/ and translate openrc services to systemd services.
However, every docker images used are alpine images, excepted for ML. Keeping docker/standalone OS the same would certainly be easier to maintain (same packages name, package manager, shell, ...). But it's a way we could try.
Can we fetch alpine_ver directly from current user's OS? As you can see if user try to run your script on another alpine version, it can cause error from package updating.
Yes, it's on my todo-list :)
Thanks!
I first thought about the same architecture as you:
./installation/services/openrc/. In this way, we could then support systemd-based OS by mkdir-ing./services/systemd/and translate openrc services to systemd services.
I really like this organization because it may help us distinguish between service managers.
However, every docker images used are alpine images, excepted for ML. Keeping docker/standalone OS the same would certainly be easier to maintain (same packages name, package manager, shell, ...). But it's a way we could try.
yeah, but I believe that it will make our source code become mess up if we have more kind of service managers like systemd, sysvinit, ....
Yes, it's on my todo-list :)
Sound great, thank you.
Very interesting PR. I'll use it as a basis for a coming Yunohost package 🚀 !
Hi all,
I tried to find a way to run TensorFlow on Alpine, without success.
I've found a packaged glibc for Alpine, but I have a sticky deps/lib/libtensorflow.so.2: __memcpy_chk: symbol not found at runtime.
The only thing we could get for the moment for Alpine is an installation without ML.
However, I'll look for a Debian full installation script. In this way, ML could be installed on the same machine as DB and server.
I also look for an upgrade functionnality.
To be continued...
Debian/Ubuntu may be more popular than alpine. Machine learning service is optional, so if you wanna continue using alpine, just skip it in default.
Thank you for the detail comments in each file. It helps a lot!
I think we want to include an installation script for Debian/Ubuntu as well. What is your plan on this?
What is your plan on this?
I didn't started anything for Debian/Ubuntu, but I'll start as soon as everything will be okay for Alpine (except ML).
There is one thing and a half to do to support another distro:
- find the corresponding packages for its package manager + distro + version
- for systemd family, port OpenRC services files (done once)
The longer will be the first one as you can imagine.
Hi, I finally managed how to upgrade Immich. Everything is okay for me, I let you review what have been done since your last feedback.
Everything looks good to me. Can you write down some words for the testing procedure and the required environment to test? Thank you for your contribution!
Everything looks good to me. Can you write down some words for the testing procedure and the required environment to test? Thank you for your contribution!
Hope it is what you were looking for. If not, please let me know!
@Chiogros Thank you, I will spin up an alpine VM and test then let you know the result. We probably need to move all of the instruction to the WIKI to keep things nice and clean in the readme. It is getting long :P
Hello everybody, I finally convinced myself to start a Docker VM. Good luck to everyone who could want to maintain this script.