Git Product home page Git Product logo

Comments (6)

SISheogorath avatar SISheogorath commented on July 18, 2024

I just tested it on my private setup, which is also using keycloak + oauth. worked fine with both base images. Could you share your config?

from container.

kjkriegel avatar kjkriegel commented on July 18, 2024

Our instance runs in Kubernetes and was migrated from hackmdio/hackmd:2.0.0. All configuration is done via env variables. The Keycloak Config appears to match https://docs.hedgedoc.org/guides/auth/keycloak/. Both HedgeDoc and Keycloak are behind a nginx reverse proxy ingress controller.

apiVersion: apps/v1
kind: Deployment
metadata:
  name: codimd
  namespace: codimd
  labels:
    app: codimd
spec:
  replicas: 1
  selector:
    matchLabels:
      app: codimd
  template:
    metadata:
      labels:
        app: codimd
    spec:
      containers:
      - name: codimd
        image: quay.io/hedgedoc/hedgedoc:1.7.1-debian
        imagePullPolicy: Always
        env:
        - name: "CMD_DB_URL"
          valueFrom:
            secretKeyRef:
              name: codimd-cfg
              key: pg_cstr
        - name: "CMD_DOMAIN"
          value: "codimd.<redacted>"
        - name: "CMD_USECDN"
          value: "false"
        - name: "CMD_PROTOCOL_USESSL"
          value: "true"
        - name: "CMD_EMAIL"
          value: "true"
        - name: "CMD_URL_ADDPORT"
          value: "false"
        - name: "CMD_ALLOW_EMAIL_REGISTER"
          value: "false"
        - name: "CMD_ALLOW_ANONYMOUS"
          value: "true"
        - name: "CMD_ALLOW_ANONYMOUS_EDITS"
          value: "false"
        - name: "CMD_OAUTH2_USER_PROFILE_URL"
          value: "https://keycloak.<redacted>/auth/realms/<redacted>/protocol/openid-connect/userinfo"
        - name: "CMD_OAUTH2_USER_PROFILE_USERNAME_ATTR"
          value: "preferred_username"
        - name: "CMD_OAUTH2_USER_PROFILE_DISPLAY_NAME_ATTR"
          value: "name"
        - name: "CMD_OAUTH2_USER_PROFILE_EMAIL_ATTR"
          value: "email"
        - name: "CMD_OAUTH2_TOKEN_URL"
          value: "https://keycloak.<redacted>/auth/realms/<redacted>/protocol/openid-connect/token"
        - name: "CMD_OAUTH2_AUTHORIZATION_URL"
          value: "https://keycloak.<redacted>/auth/realms/<redacted>/protocol/openid-connect/auth"
        - name: "CMD_OAUTH2_CLIENT_ID"
          value: "codimd"
        - name: "CMD_OAUTH2_CLIENT_SECRET"
          value: "<redacted>"
        - name: "CMD_OAUTH2_PROVIDERNAME"
          value: "Keycloak"
        - name: "CMD_SESSION_SECRET"
          value: "<redacted>"
        ports:
        - name: http-codimd
          containerPort: 3000
        volumeMounts:
        - name: uploads
          mountPath: /home/hackmd/app/public/uploads
      volumes:
      - name: uploads
        hostPath:
          path: /srv/codimd/codimd

from container.

SISheogorath avatar SISheogorath commented on July 18, 2024

I'll look into those details later and try to reproduce. But for now, please check the volume mount! This is not where uploads on the hedgedoc image are stored!

from container.

kjkriegel avatar kjkriegel commented on July 18, 2024

Thanks, I totally missed that. Fixed it.

from container.

moxli avatar moxli commented on July 18, 2024

I am facing the same issue.

@kjkriegel Did you manage to fix it it?

from container.

ErikMichelson avatar ErikMichelson commented on July 18, 2024

This issue had no activity for quite some time. I guess the problem was resolved in the meantime. If it persists with current docker images, feel free to re-open.

from container.

Related Issues (20)

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.