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

keto CLI relation-tuple create executed repeatly #1566

Open
3 of 5 tasks
KevinLi-123 opened this issue Aug 13, 2024 · 0 comments
Open
3 of 5 tasks

keto CLI relation-tuple create executed repeatly #1566

KevinLi-123 opened this issue Aug 13, 2024 · 0 comments
Labels
bug Something is not working.

Comments

@KevinLi-123
Copy link

KevinLi-123 commented Aug 13, 2024

Preflight checklist

Ory Network Project

No response

Describe the bug

keto image: oryd/keto:v0.12.0

I built my keto on k8s, and mount relation-tuples folder in pod
I have a folder that contains a relation JSON file.
if I executed the command:
keto relation-tuple create --insecure-disable-transport-security /etc/keto/relation-tuples/myRelaton.json
The command can be executed correctly.

but when i executed the command:
keto relation-tuple create --insecure-disable-transport-security /etc/keto/relation-tuples
This command results in the content of myRelaton.json being generated three times.

Reproducing the bug

apiVersion: batch/v1
kind: Job
metadata:
  name: {{ .Release.Name }}-migrate
  labels:
    app: {{ .Release.Name }}
  annotations:
    helm.sh/hook: post-install,post-upgrade
    helm.sh/hook-delete-policy: before-hook-creation,hook-succeeded
spec:
  template:
    spec:
      containers:
        - name: {{ .Release.Name }}
          image: {{ .Values.image }}
          imagePullPolicy: IfNotPresent
          command: ["sh", "-c", "keto migrate up -c /etc/keto/config.yml -y; keto relation-tuple create --insecure-disable-transport-security /etc/keto/relation-tuples"]
          env:
            - name: KETO_WRITE_REMOTE
              value: keto.ory.svc.cluster.local:4467
          volumeMounts:
            - name: config-vol
              mountPath: /etc/keto
              readOnly: true
            - name: config-relation
              mountPath: /etc/keto/relation-tuples
              readOnly: true

      volumes:
        - name: config-vol
          configMap:
            name: {{ .Release.Name }}

        - name: config-relation
          configMap:
            name: {{ .Release.Name }}-relation
      restartPolicy: Never

Relevant log output

No response

Relevant configuration

serve:
      read:
        host: 0.0.0.0
        port: {{ .Values.mapping.ports.public }}
      write:
        host: 0.0.0.0
        port: {{ .Values.mapping.ports.admin }}

Version

keto image: oryd/keto:v0.12.0

On which operating system are you observing this issue?

None

In which environment are you deploying?

None

Additional Context

No response

@KevinLi-123 KevinLi-123 added the bug Something is not working. label Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is not working.
Projects
None yet
Development

No branches or pull requests

1 participant