friendica / docker

Docker image for Friendica
https://friendi.ca
GNU Affero General Public License v3.0
45 stars 18 forks source link

error in redis configuration - versionning change #196

Closed valvin1 closed 2 years ago

valvin1 commented 2 years ago

hello,

unfortunately 2021.09 isn't very stable and I should remove my imagePullPolicy: Always configuration.

I think this commit introduce a new bug in my configuration.

Configuring Redis as session handler
/entrypoint.sh: 52: Bad substitution

I have net yet seen if I should update my configuration but I think it would be nice to have a sort of versionning in image tag. If I deploy a 2021.09 it should be always the same image. If I want a new feature or a fix it should be 2021.09-1 or something like this?

What do you think of this idea ?

valvin1 commented 2 years ago

i'm looking at the error itself and don't understand what is wrong. It breaks at https://github.com/friendica/docker/blob/stable/docker-entrypoint.sh#L52 and my REDIS_HOST is set to friendica-redis.friendica.svc.cluster.local

when i do the following command on my computer I don't have any issue:

sh-5.1$ export REDIS_HOST=friendica-redis.friendica.svc.cluster.local
sh-5.1$ echo ${REDIS_HOST:0:1}
f

but in the image php:7.4-apache-bullseye

podman run --rm -it --entrypoint="/bin/sh" php:7.4-apache-bullseye
# export REDIS_HOST=friendica-redis.friendica.svc.cluster.local
# echo ${REDIS_HOST:0:1}
/bin/sh: 2: Bad substitution

it looks to be specific to the sh version of the docker image?

valvin1 commented 2 years ago

it looks like ${REDIS_HOST:0:1} is bash but we are using sh

i belive i was on sh but on my computer :

ls -l /usr/bin/sh
lrwxrwxrwx. 1 root root 4 26 janv.  2021 /usr/bin/sh -> bash

so it works with bash not sh.

nupplaphil commented 2 years ago

@valvin1 - Please retry and close this issue after https://github.com/docker-library/official-images/pull/11872 is merged

I have net yet seen if I should update my configuration but I think it would be nice to have a sort of versionning in image tag. If I deploy a 2021.09 it should be always the same image. If I want a new feature or a fix it should be 2021.09-1 or something like this?

What do you think of this idea ?

The problem is that the versioning follows the rules from the upstream branch.. I think it would be better to have a an CI environment here, where we/I can prove that the setup still works .. "just" building it doesn't seem to be enough

and tbh I thought it was a "quick win" because I found this (working) script at Nextcloud as well, so I didn't test it enough.. my bad :-/

valvin1 commented 2 years ago

Thank you for the fix and I let you know when my instance is up again.

The goal of this issue is more about a frozen version of the stable images. New development, quick wins shouldn't be applied to stable version directly. Maybe stable version shouldn't be published from mainstream but from a tag?

You are doing a great work but it is really frustrating having an instance which could stop working at any time when my server pulls again the stable image.

valvin1 commented 2 years ago

My instance has downloaded a new image during the night and is up again.

nupplaphil commented 2 years ago

I opened another issue for the versioning topic #200 and close this issue because the bug per se is fixed :)