It seems the source code does not check by ownerType but rather if found out data or not on the user. When using the ownertype: user and user root. It detects as an org instead of a user. however, when using type as org and owner myorg it tries to find the myorg as a user, instead of an org.
I tried different samples. this is one:
apiVersion: redhatcop.redhat.io/v1alpha1
kind: GitWebhook
metadata:
name: gitwebhook-gitlab
spec:
active: true
webhookSecret:
name: webhook-secret
repositoryOwner: myorg
ownerType: organization
repositoryName: app-name
webhookURL: >-
https://webhook-app-el-cluster
content: json
events:
It seems the source code does not check by ownerType but rather if found out data or not on the user. When using the ownertype: user and user root. It detects as an org instead of a user. however, when using type as org and owner myorg it tries to find the myorg as a user, instead of an org. I tried different samples. this is one: apiVersion: redhatcop.redhat.io/v1alpha1 kind: GitWebhook metadata: name: gitwebhook-gitlab spec: active: true webhookSecret: name: webhook-secret repositoryOwner: myorg ownerType: organization repositoryName: app-name webhookURL: >- https://webhook-app-el-cluster content: json events: