Giter VIP home page Giter VIP logo

redisinsight's People

Contributors

oblakbot avatar seebeen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

redisinsight's Issues

How to Use 'oblakstudio/redisinsight:latest' in Docker Compose

Issue Description:
I am currently using a Docker Compose file to access AWS Elasticache, and I would like to migrate to RedisInsight version 2.X using the 'oblakstudio/redisinsight:latest' Docker image. However, I am encountering issues with this setup. I am seeking assistance on how to properly configure a Docker Compose file for 'oblakstudio/redisinsight:latest' or any documentation that can guide me through the process.

Docker Compose File (existing setup):

version: "3.7"

services:
  nginx:
    build:
      context: .
      dockerfile: Dockerfile
    depends_on:
      - redisinsight
    ports:
      - "8080:80"
    environment:
      - FORWARD_HOST=redisinsight
      - FORWARD_PORT=8001
      - BASIC_USERNAME=app
      - BASIC_PASSWORD=dddX3ddPil84J
    networks:
      - mynetwork

  redisinsight:
    image: redislabs/redisinsight:latest
    expose:
      - "8001"
    ports:
      - "8001:8001"
    environment:
      - RITRUSTEDORIGINS=http://localhost:8001 # Trust the proxy origin
      - RIPROXYENABLE=t
      - RILOGLEVEL=DEBUG
    volumes:
      - redisinsight:/db
    networks:
      - mynetwork

networks:
  mynetwork:

volumes:
  redisinsight:

I would like to transition to using the 'oblakstudio/redisinsight:latest' Docker image to take advantage of RedisInsight version 2.X. If anyone has experience with this image or can provide guidance on how to configure a Docker Compose file for it, I would greatly appreciate it. Additionally, if there are any specific configurations or environment variables required to make this work, please share those details as well.

Thank you for your assistance!

Server not exposed on port 5000

This might be user error, but I have troubleshooted quiet a bit first.

I can't get the server to start on port 5000, I get a connection refused error as if there isn't any thing running. I can run redisinsight v1 fine so I know my docker/OS is working.

Below you can see both containers running and that I can sucessfully request RedisInsight v1

[ec2-user@ip-10-17-1-173 ~]$ docker ps
CONTAINER ID   IMAGE                             COMMAND                  CREATED          STATUS          PORTS                                         NAMES
7ecaceda24e8   oblakstudio/redisinsight:latest   "./docker-entry.sh n…"   21 minutes ago   Up 11 minutes   0.0.0.0:32768->5000/tcp, :::32768->5000/tcp   redisinsight_5000
4f4b25584558   redislabs/redisinsight:latest     "bash ./docker-entry…"   4 hours ago      Up 3 minutes    0.0.0.0:8001->8001/tcp, :::8001->8001/tcp     keen_allen
[ec2-user@ip-10-17-1-173 ~]$ curl localhost:5000
curl: (7) Failed to connect to localhost port 5000 after 0 ms: Couldn't connect to server
[ec2-user@ip-10-17-1-173 ~]$ curl localhost:8001
<!doctype html><html lang="en"><head><title>RedisInsight</title><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no"><link rel="icon" href="/static/images/favicon.ico" type="image/x-icon"><script>var RIPROXYPATH = "";
             window.__RIPROXYPATH__ = RIPROXYPATH;</script><script defer="defer" src="/static/app/bundle.e7efa0031208bf65925b.js"></script></head><body><div id="app"></div><script>// Stub for calls to gtag(). If GA is enabled, this function will
            // be replaced with the actual gtag() function.
            window.gtag = function () {}</script></body></html>[ec2-user@ip-10-17-1-173 ~]$ ^C

I've checked the container logs and from all I can see everything is working correctly and it shows the server is running on localhost:5000

[NestWinston] Info      9/27/2023, 10:16:15 AM [GuidesProvider] Checking for updates... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [TutorialsProvider] Checking for updates... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [ContentProvider] Checking for updates... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Trying to sync features config... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [LocalFeaturesConfigRepository] Getting features config entity - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [ServerService] Checking server info. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Fetching remote config... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Fetching remote config... - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [ServerService] First application launch. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [ServerService] Application started. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [LocalFeaturesConfigRepository] Getting features config entity - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [NestApplication] Nest application successfully started - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [bootstrap] Server is running on http(s)://localhost:5000 - {"value":{"message":"Server is running on http(s)://localhost:5000","context":"bootstrap"},"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisearch] Successfully updated redisearch commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisjson] Successfully updated redisjson commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisai] Successfully updated redisai commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisearch] Successfully updated redisearch commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgears] Successfully updated redisgears commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisbloom] Successfully updated redisbloom commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgraph] Successfully updated redisgraph commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Successfully updated stored remote config - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Recalculating features flags - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgears] Successfully updated redisgears commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redistimeseries] Successfully updated redistimeseries commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redistimeseries] Successfully updated redistimeseries commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:triggers_and_functions] Successfully updated triggers_and_functions commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgears] Successfully updated redisgears commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisjson] Successfully updated redisjson commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisai] Successfully updated redisai commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgraph] Successfully updated redisgraph commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisbloom] Successfully updated redisbloom commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisai] Successfully updated redisai commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:triggers_and_functions] Successfully updated triggers_and_functions commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisearch] Successfully updated redisearch commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:triggers_and_functions] Successfully updated triggers_and_functions commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisjson] Successfully updated redisjson commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisgraph] Successfully updated redisgraph commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:main] Successfully updated main commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:main] Successfully updated main commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [LocalFeaturesConfigRepository] Getting features config entity - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redisbloom] Successfully updated redisbloom commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:redistimeseries] Successfully updated redistimeseries commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [CommandsJsonProvider:main] Successfully updated main commands - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [LocalFeaturesConfigRepository] Getting features config entity - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [SettingsService] Getting application settings. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [SettingsService] Succeed to get application settings. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Features flags recalculated. Updated: 3 deleted: 0 - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [FeaturesConfigService] Getting features list - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [LocalFeaturesConfigRepository] Getting features config entity - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [SettingsService] Getting application settings. - {"stack":[]}
[NestWinston] Info      9/27/2023, 10:16:15 AM [SettingsService] Succeed to get application settings. - {"stack":[]}

How To: Change server listening port

Thank you so much for taking the time to build and maintain this container.

I read that the listen port is fixed to 5000; however, looking at the codebase 5000 is the fallback port if process.env.API_PORT is not available.

I was able to successful get the server to directly listen on various ports by adding an env variable API_PORT set to the desired port number.

Enable Encrypt sensitive information

When starting the first time I'm not able to select Encrypt sensitive information. Do I have to do any additional steps to make it work. Found no information in the docs. Deployed it in kubernetes with this config.

config

---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: redisinsight-pv-claim
  namespace: namespace
  labels:
    app: redisinsight
spec:
  accessModes:
    - ReadWriteOnce
  resources:
    requests:
      storage: 1Gi
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: redisinsight
  namespace: namespace
  labels:
    app: redisinsight
spec:
  replicas: 1
  selector:
    matchLabels:
      app: redisinsight
  template:
    metadata:
      labels:
        app: redisinsight
    spec:
      containers:
        - name:  redisinsight
          image: oblakstudio/redisinsight:latest
          imagePullPolicy: IfNotPresent
          securityContext:
            runAsUser: 0
          ports:
            - containerPort: 5000
              protocol: TCP
---

RIPROXYPATH is not working

Setting environment variable RIPROXYENABLE = t and RIPROXYPATH = /redisinsight does not work. Redisinsight is still working on root path.

Enhance Docker Image Security for Kubernetes Deployment

When deploying this Docker image in a Kubernetes cluster, I've had to disable key security features, namely running as a non-root user and disallowing privilege escalation. To improve security posture, I propose these enhancements:

  1. Modify the Dockerfile to create a non-root user that has read/write access to the working directory.
  2. Remove the necessity for privilege escalation, aligning the image with Kubernetes' best practices.

I often use the following securityContext in my Kubernetes deployments or StatefulSets:

    securityContext:
      runAsUser: 1001
      allowPrivilegeEscalation: false
      capabilities:
        drop:
          - ALL

Implementing these changes will make it easier for users to adhere to security best practices without requiring manual adjustments.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.