Hi all,
I currently have an Immich container, which uses a separate PostgreSQL database in the backend.
Due to a recent update, the server does not boot up because it tries to use the vectors extension in PostgreSQL, which is not installed.
When looking up how to install extensions, the results mostly say I should console into the docker, clone the git repo and install it, but I have some questions whether this is the clean way of doing it.
I always thought that everything done in the docker console command line is a sandboxed environment installed from the docker image, so if I update my docker container in the future, will it also remove the extension I installed with the command line?
I guess the extensions also need to be updated, so if I install it via the container console, I would probably have to manually update it as well?
Is there a way to embed this in the container config so that it will install and update the extension at startup of the container?
This is the step plan I found:
console in the PostgreSQL container and install tools needed to install the extension:
apk add --no-cache git build-base clang llvm15-dev llvm15
clone the git repo of the extension in a temp folder
cd /tmp
git clone --branch v0.5.1 https://github.com/pgvector/pgvector.git
cd pgvector
compile and install the extension
make
make install
after this, the extension should be installed and ready to use in Immich, as that container installs the extension on the database itself on startup
is this correct?