Skip to content
This repository has been archived by the owner on Jan 31, 2024. It is now read-only.

Commit

Permalink
Update TrustyAI Operator to allow for parameterized images
Browse files Browse the repository at this point in the history
  • Loading branch information
RobGeada authored and LaVLaS committed Aug 17, 2023
1 parent bfc8713 commit 03f0416
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 9 deletions.
22 changes: 20 additions & 2 deletions trustyai-service-operator/base/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,12 @@ patchesStrategicMerge:
- manager_auth_proxy_patch.yaml

configMapGenerator:
- name: config
env: params.env
- env: params.env
name: config

configurations:
- params.yaml

generatorOptions:
disableNameSuffixHash: true

Expand All @@ -31,3 +35,17 @@ vars:
apiVersion: v1
fieldref:
fieldpath: data.trustyaiServiceImageTag
- name: trustyaiOperatorImageName
objref:
kind: ConfigMap
name: config
apiVersion: v1
fieldref:
fieldpath: data.trustyaiOperatorImageName
- name: trustyaiOperatorImageTag
objref:
kind: ConfigMap
name: config
apiVersion: v1
fieldref:
fieldpath: data.trustyaiOperatorImageTag
4 changes: 3 additions & 1 deletion trustyai-service-operator/base/params.env
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
trustyaiServiceImageName=quay.io/trustyai/trustyai-service
trustyaiServiceImageTag=v0.2.0
trustyaiServiceImageTag=latest
trustyaiOperatorImageName=quay.io/trustyai/trustyai-service-operator
trustyaiOperatorImageTag=latest
3 changes: 3 additions & 0 deletions trustyai-service-operator/base/params.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
varReference:
- kind: Deployment
path: spec/template/spec/containers[]/image
6 changes: 1 addition & 5 deletions trustyai-service-operator/manager/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
resources:
- manager.yaml
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
images:
- name: controller
newName: quay.io/trustyai/trustyai-service-operator
newTag: v1.8.0
kind: Kustomization
2 changes: 1 addition & 1 deletion trustyai-service-operator/manager/manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ spec:
- /manager
args:
- --leader-elect
image: controller:latest
image: $(trustyaiOperatorImageName):$(trustyaiOperatorImageTag)
name: manager
securityContext:
runAsNonRoot: true
Expand Down

0 comments on commit 03f0416

Please sign in to comment.