Skip to content

Commit 3b685f0

Browse files
committed
Added Workflow job to update CFO image
1 parent 72cace9 commit 3b685f0

File tree

5 files changed

+60
-7
lines changed

5 files changed

+60
-7
lines changed

.github/workflows/tag-and-build.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,11 @@ jobs:
101101
sed -i -E "s/(.*MCAD_REF \?= ).*/\1release-\${MCAD_VERSION}/" Makefile
102102
sed -i -E "s/(.*INSTASCALE_VERSION \?= ).*/\1${{ github.event.inputs.instascale-version }}/" Makefile
103103
104+
- name: Update image version in params.env
105+
run: |
106+
VERSION=${{ github.event.inputs.version }} perl -i -pe 's/:(.*)$/:$ENV{"VERSION"}/' config/manifests/bases/params.env
107+
shell: bash
108+
104109
- name: Login to Quay.io
105110
uses: redhat-actions/podman-login@v1
106111
with:
@@ -146,7 +151,7 @@ jobs:
146151
uses: stefanzweifel/git-auto-commit-action@v4
147152
with:
148153
commit_message: Update dependency versions for release ${{ github.event.inputs.version }}
149-
file_pattern: 'README.md *.yaml Makefile go.mod go.sum'
154+
file_pattern: 'README.md *.yaml Makefile go.mod go.sum *.env'
150155
create_branch: true
151156
branch: ${{ env.PR_BRANCH_NAME }}
152157

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
kind: ImageStream
2+
apiVersion: image.openshift.io/v1
3+
metadata:
4+
name: codeflare-notebook
5+
labels:
6+
opendatahub.io/notebook-image: 'true'
7+
annotations:
8+
opendatahub.io/notebook-image-name: "CodeFlare Notebook"
9+
opendatahub.io/notebook-image-desc: "Custom Jupyter notebook image with codeflare SDK, Python 3.8, Ray 2.1.0 and PyTorch 1.12.1"
10+
spec:
11+
lookupPolicy:
12+
local: true
13+
tags:
14+
- annotations:
15+
openshift.io/imported-from: quay.io/project-codeflare/notebook
16+
name: v0.7.0
17+
from:
18+
kind: DockerImage
19+
name: quay.io/project-codeflare/notebook:v0.7.0
20+
importPolicy:
21+
scheduled: true

config/manifests/bases/params.env

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
namespace=opendatahub
2+
odh-codeflare-operator-controller-image=quay.io/project-codeflare/codeflare-operator:v1.0.0

config/manifests/bases/params.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
varReference:
2+
- path: subjects[]/namespace
3+
kind: ClusterRoleBinding
4+
- path: spec/template/spec/containers[]/image
5+
kind: Deployment

config/manifests/kustomization.yaml

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,28 @@
1-
# These resources constitute the fully configured set of manifests
2-
# used to generate the 'manifests/' directory in a bundle.
3-
resources:
4-
- bases/codeflare-operator.clusterserviceversion.yaml
5-
- ../default
6-
- ../scorecard
71
apiVersion: kustomize.config.k8s.io/v1beta1
82
kind: Kustomization
3+
4+
configMapGenerator:
5+
- name: codeflare-stack-config
6+
envs:
7+
- bases/params.env
8+
configurations:
9+
- bases/params.yaml
10+
11+
vars:
12+
- name: namespace
13+
objref:
14+
kind: ConfigMap
15+
name: codeflare-stack-config
16+
apiVersion: v1
17+
fieldref:
18+
fieldpath: data.namespace
19+
- name: odh_codeflare_operator_controller_image
20+
objref:
21+
kind: ConfigMap
22+
name: codeflare-stack-config
23+
apiVersion: v1
24+
fieldref:
25+
fieldpath: data.odh-codeflare-operator-controller-image
26+
resources:
27+
- ../default
28+
- bases/codeflare-notebook-imagestream.yaml

0 commit comments

Comments
 (0)