appuio / component-openshift4-operators

Component to manage target namespaces for cluster-scoped OLM-managed operators on OpenShift 4

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Operator namespace name label for network policies missing

megian opened this issue · comments

The version v1.0.0 does not set a name label. This is required for the network policies created in openshift4-logging.

The namespace can be manually labeled, in example:

oc label ns openshift-operators-redhat name=openshift-operators-redhat

Steps to Reproduce the Problem

  1. Create a new cluster
  2. Deploy openshift-operators as openshift-operators-redhat
  3. No name label is set

Actual Behavior

No name label is set.

Expected Behavior

There must be a name label name=${name of instance}

Can't reproduce this When compiling the component, the resulting namespace object does have label name:

$ cat catalog/manifests/openshift4-operators/openshift-operators-redhat.yaml 
apiVersion: v1
kind: Namespace
metadata:
  annotations:
    openshift.io/node-selector: ''
  labels:
    name: openshift-operators-redhat
    openshift.io/cluster-monitoring: true
  name: openshift-operators-redhat
---
apiVersion: operators.coreos.com/v1
kind: OperatorGroup
metadata:
  annotations: {}
  labels:
    name: openshift-operators-redhat
  name: openshift-operators-redhat
  namespace: openshift-operators-redhat

edit: However, there's something weird going on here, the labels disappear somewhere between the catalog and the cluster.