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

Docker: PHP-Redis extension is missing #10910

Closed
2 tasks done
asassoye opened this issue Apr 6, 2022 · 7 comments
Closed
2 tasks done

Docker: PHP-Redis extension is missing #10910

asassoye opened this issue Apr 6, 2022 · 7 comments

Comments

@asassoye
Copy link

asassoye commented Apr 6, 2022

Debug mode

Describe the bug

Hello,

When i configure Redis in the configuration, i have this error: LogicException Please make sure the PHP Redis extension is installed and enabled. with the https://hub.docker.com/r/snipe/snipe-it docker image with tag v5.4.1 (and also alpine version)

When i install the php-redis package on the container everything works fine and the sessions and cache are stored in Redis.

Reproduction steps

Config:

CACHE_DRIVER: "redis"
SESSION_DRIVER: "redis"
REDIS_HOST: "my-redis-fqdm"
REDIS_PORT: "6379"

Expected behavior

Snipe-it is using Redis for cache and for sessions

Screenshots

image

Snipe-IT Version

v5.4.1

Operating System

Docker

Web Server

Docker (Apache)

PHP Version

7.4.3

@welcome
Copy link

welcome bot commented Apr 6, 2022

👋 Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.

@stavros-k
Copy link

It isn't installed on this version, it should have been added on v6, but I just checked composer file on master and it isn't there..
Relevant discussion:
#10869

@snipe
Copy link
Owner

snipe commented May 15, 2022

We’d happily take a PR for this. Redis is not commonly used with Snipe-IT, so I’m not exactly shocked it wasn’t added to the docker image. There are not many use cases I can think of that would require Redis here.

@stavros-k
Copy link

stavros-k commented May 17, 2022

Well it was there.
Added here #4146
But removed here #7975

@snipe
Copy link
Owner

snipe commented May 17, 2022

Again, we'd welcome a PR for it.

denzfarid pushed a commit to denzfarid/snipe-it that referenced this issue Jun 5, 2022
@denzfarid
Copy link

denzfarid commented Jun 5, 2022

@snipe
please review my pull request
thank you very much 😊🙏


@asassoye @stavros-k
while waiting, you can create a new dockerfile like this

For alpine image Dockerfile.alpine

FROM snipe/snipe-it:latest-alpine
RUN apk add --no-cache \
    php7-redis

this for ubuntu Dockerfile

FROM snipe/snipe-it:latest
RUN apt-get update -qqy \
 && apt-get install -qqy --no-install-recommends \
php7.4-redis

denzfarid pushed a commit to denzfarid/snipe-it that referenced this issue Jun 5, 2022
@snipe snipe closed this as completed in 9770692 Jun 6, 2022
@denzfarid
Copy link

@stavros-k @asassoye
you can use develop branch or develop-alpin to prove this, currently I'm using develop-alpine with redis driver

image

this redis keys
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants