Skip to content

Commit afae2c6

Browse files
authored
Merge pull request #633 from application-stacks/lcj-sandbox
Update version to 1.3.2, update sample + misc fixes
2 parents 64262a9 + 698fb1d commit afae2c6

12 files changed

+37
-34
lines changed

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ FROM registry.access.redhat.com/ubi8/ubi-minimal:latest
3939
ARG USER_ID=65532
4040
ARG GROUP_ID=65532
4141

42-
ARG VERSION_LABEL=1.3.1
42+
ARG VERSION_LABEL=1.3.2
4343
ARG RELEASE_LABEL=XX
4444
ARG VCS_REF=0123456789012345678901234567890123456789
4545
ARG VCS_URL="https://github.com/application-stacks/runtime-component-operator"

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# To re-generate a bundle for another specific version without changing the standard setup, you can:
44
# - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2)
55
# - use environment variables to overwrite this value (e.g export VERSION=0.0.2)
6-
VERSION ?= 1.3.1
6+
VERSION ?= 1.3.2
77
OPERATOR_SDK_RELEASE_VERSION ?= v1.27.0
88

99
# CHANNELS define the bundle channels used in the bundle.

bundle/manifests/runtime-component.clusterserviceversion.yaml

+8-8
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ metadata:
1111
"name": "runtimecomponent-sample"
1212
},
1313
"spec": {
14-
"applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f",
14+
"applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac",
1515
"expose": true,
1616
"manageTLS": true,
1717
"replicas": 1,
@@ -44,7 +44,7 @@ metadata:
4444
"name": "runtimecomponent-sample"
4545
},
4646
"spec": {
47-
"applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f",
47+
"applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac",
4848
"expose": true,
4949
"replicas": 1,
5050
"service": {
@@ -71,9 +71,9 @@ metadata:
7171
categories: Application Runtime
7272
certified: "true"
7373
containerImage: icr.io/appcafe/runtime-component-operator:daily
74-
createdAt: "2024-05-01T19:22:43Z"
74+
createdAt: "2024-05-07T20:25:49Z"
7575
description: Deploys any runtime component with dynamic and auto-tuning configuration
76-
olm.skipRange: '>=0.8.0 <1.3.1'
76+
olm.skipRange: '>=0.8.0 <1.3.2'
7777
operators.openshift.io/infrastructure-features: '["disconnected"]'
7878
operators.operatorframework.io/builder: operator-sdk-v1.27.0
7979
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
@@ -84,7 +84,7 @@ metadata:
8484
operatorframework.io/arch.ppc64le: supported
8585
operatorframework.io/arch.s390x: supported
8686
operatorframework.io/os.linux: supported
87-
name: runtime-component.v1.3.1
87+
name: runtime-component.v1.3.2
8888
namespace: placeholder
8989
spec:
9090
apiservicedefinitions: {}
@@ -1006,7 +1006,7 @@ spec:
10061006
fieldRef:
10071007
fieldPath: metadata.annotations['olm.targetNamespaces']
10081008
- name: RELATED_IMAGE_LIBERTY_SAMPLE_APP
1009-
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
1009+
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
10101010
- name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR
10111011
value: icr.io/appcafe/runtime-component-operator:daily
10121012
image: icr.io/appcafe/runtime-component-operator:daily
@@ -1289,8 +1289,8 @@ spec:
12891289
provider:
12901290
name: Community
12911291
relatedImages:
1292-
- image: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
1292+
- image: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
12931293
name: liberty-sample-app
12941294
- image: icr.io/appcafe/runtime-component-operator:daily
12951295
name: runtime-component-operator
1296-
version: 1.3.1
1296+
version: 1.3.2

catalog.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ FROM registry.redhat.io/openshift4/ose-operator-registry:v4.14 AS builder
22
FROM registry.redhat.io/ubi8/ubi-minimal
33

44
# Add label for location of Declarative Config root directory & required OpenShift labels
5-
ARG VERSION_LABEL=1.3.1
5+
ARG VERSION_LABEL=1.3.2
66
ARG RELEASE_LABEL=XX
77
ARG VCS_REF=0123456789012345678901234567890123456789
88
ARG VCS_URL="https://github.com/application-stacks/runtime-component-operator"

config/manager/manager.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ spec:
6767
fieldRef:
6868
fieldPath: metadata.annotations['olm.targetNamespaces']
6969
- name: RELATED_IMAGE_LIBERTY_SAMPLE_APP
70-
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
70+
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
7171
- name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR
7272
value: OPERATOR_IMAGE
7373
securityContext:

config/manifests/bases/runtime-component.clusterserviceversion.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ metadata:
99
containerImage: icr.io/appcafe/runtime-component-operator:daily
1010
createdAt: "2022-02-25T09:00:00Z"
1111
description: Deploys any runtime component with dynamic and auto-tuning configuration
12-
olm.skipRange: '>=0.8.0 <1.3.1'
12+
olm.skipRange: '>=0.8.0 <1.3.2'
1313
operators.openshift.io/infrastructure-features: '["disconnected"]'
1414
repository: https://github.com/application-stacks/runtime-component-operator
1515
support: Community

config/samples/rc.app.stacks_v1_runtimecomponent.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ kind: RuntimeComponent
33
metadata:
44
name: runtimecomponent-sample
55
spec:
6-
applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
6+
applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
77
expose: true
88
manageTLS: true
99
replicas: 1

config/samples/rc.app.stacks_v1beta2_runtimecomponent.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ metadata:
44
name: runtimecomponent-sample
55
spec:
66
# Add fields here
7-
applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
7+
applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
88
expose: true
99
replicas: 1
1010
service:

controllers/runtimecomponent_controller.go

+19-16
Original file line numberDiff line numberDiff line change
@@ -205,22 +205,25 @@ func (r *RuntimeComponentReconciler) Reconcile(ctx context.Context, req ctrl.Req
205205
}
206206
}
207207

208-
if appstacksutils.GetServiceAccountName(instance) == "" {
209-
serviceAccount := &corev1.ServiceAccount{ObjectMeta: defaultMeta}
210-
err = r.CreateOrUpdate(serviceAccount, instance, func() error {
211-
return appstacksutils.CustomizeServiceAccount(serviceAccount, instance, r.GetClient())
212-
})
213-
if err != nil {
214-
reqLogger.Error(err, "Failed to reconcile ServiceAccount")
215-
return r.ManageError(err, common.StatusConditionTypeReconciled, instance)
216-
}
217-
} else {
218-
// delete our SA, as one has been specified
219-
serviceAccount := &corev1.ServiceAccount{ObjectMeta: defaultMeta}
220-
err = r.DeleteResource(serviceAccount)
221-
if err != nil {
222-
reqLogger.Error(err, "Failed to delete ServiceAccount")
223-
return r.ManageError(err, common.StatusConditionTypeReconciled, instance)
208+
serviceAccountName := appstacksutils.GetServiceAccountName(instance)
209+
if serviceAccountName != defaultMeta.Name {
210+
if serviceAccountName == "" {
211+
serviceAccount := &corev1.ServiceAccount{ObjectMeta: defaultMeta}
212+
err = r.CreateOrUpdate(serviceAccount, instance, func() error {
213+
return appstacksutils.CustomizeServiceAccount(serviceAccount, instance, r.GetClient())
214+
})
215+
if err != nil {
216+
reqLogger.Error(err, "Failed to reconcile ServiceAccount")
217+
return r.ManageError(err, common.StatusConditionTypeReconciled, instance)
218+
}
219+
} else {
220+
// delete our SA, as one has been specified
221+
serviceAccount := &corev1.ServiceAccount{ObjectMeta: defaultMeta}
222+
err = r.DeleteResource(serviceAccount)
223+
if err != nil {
224+
reqLogger.Error(err, "Failed to delete ServiceAccount")
225+
return r.ManageError(err, common.StatusConditionTypeReconciled, instance)
226+
}
224227
}
225228
}
226229

internal/deploy/kubectl/runtime-component-operator.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ spec:
302302
- name: WATCH_NAMESPACE
303303
value: RUNTIME_COMPONENT_WATCH_NAMESPACE
304304
- name: RELATED_IMAGE_LIBERTY_SAMPLE_APP
305-
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
305+
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
306306
- name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR
307307
value: icr.io/appcafe/runtime-component-operator:daily
308308
image: icr.io/appcafe/runtime-component-operator:daily

internal/deploy/kustomize/daily/base/runtime-component-operator.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ spec:
5050
fieldRef:
5151
fieldPath: metadata.namespace
5252
- name: RELATED_IMAGE_LIBERTY_SAMPLE_APP
53-
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:cd4a9cc586dc371c34df44853abd3301bfd9bfde14efa01170625342a070d14f
53+
value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:b99e5af298a800a7d53217be7b33797cedb1eeadc4d5cd14c0c3aafccf21f1ac
5454
- name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR
5555
value: icr.io/appcafe/runtime-component-operator:daily
5656
image: icr.io/appcafe/runtime-component-operator:daily

utils/utils.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ import (
4141
"sigs.k8s.io/controller-runtime/pkg/reconcile"
4242
)
4343

44-
const RCOOperandVersion = "1.3.1"
44+
const RCOOperandVersion = "1.3.2"
4545

4646
var APIVersionNotFoundError = errors.New("APIVersion is not available")
4747

0 commit comments

Comments
 (0)