Skip to content

Commit

Permalink
Merge pull request #4 from appuio/feature/create-namespace
Browse files Browse the repository at this point in the history
Manage own Namespace in component
  • Loading branch information
mhutter authored Jun 28, 2022
2 parents 91735cc + 016123d commit 95b0a9d
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
12 changes: 12 additions & 0 deletions component/main.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,17 @@ local inv = kap.inventory();
local params = inv.parameters.openshift4_keepalived;
local image = 'registry.redhat.io/openshift4/ose-keepalived-ipfailover:v' + params.openshift_version;

local namespace =
kube.Namespace(params.namespace)
{
metadata+: {
annotations+: {
// Allow Pods to be scheduled on any Node
'openshift.io/node-selector': '',
},
},
};

local keepalived_groups = std.filter(
function(it) it != null,
[
Expand All @@ -27,6 +38,7 @@ local keepalived_groups = std.filter(
);

{
'00_namespace': namespace,
'00_operator_group': operatorlib.OperatorGroup('cluster-keepalived') {
metadata+: {
namespace: params.namespace,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
kind: Namespace
metadata:
annotations:
openshift.io/node-selector: ''
labels:
name: openshift-keepalived-operator
name: openshift-keepalived-operator

0 comments on commit 95b0a9d

Please sign in to comment.