Skip to content

Commit

Permalink
Add BuildConfiguration objects to build RStudio and CUDA RStudio imag…
Browse files Browse the repository at this point in the history
…es on OCP cluster
  • Loading branch information
atheo89 committed Jan 25, 2024
1 parent a6d02f6 commit 13716f5
Show file tree
Hide file tree
Showing 3 changed files with 304 additions and 0 deletions.
186 changes: 186 additions & 0 deletions manifests/overlays/additional/cuda-rstudio-buildconfig.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,186 @@
---
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
labels:
app: buildchain
component: base-image
name: base-rhel9
spec:
name: latest
lookupPolicy:
local: true
---
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
labels:
app: buildchain
component: cuda-image
name: cuda-rhel9
spec:
name: latest
lookupPolicy:
local: true
---
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
labels:
app: buildchain
component: rstudio-image
name: cuda-rstudio-rhel9
spec:
name: latest
lookupPolicy:
local: true
---
kind: BuildConfig
apiVersion: build.openshift.io/v1
metadata:
name: base-rhel9
labels:
app: buildchain
component: base-image
spec:
source:
type: Git
git:
uri: "https://github.com/red-hat-data-services/notebooks"
ref: f/rstudio-rhel9
strategy:
type: Docker
dockerStrategy:
dockerfilePath: "base/rhel9-python-3.9/Dockerfile"
noCache: true
output:
to:
kind: ImageStreamTag
name: "base-rhel9:latest"
resources:
limits:
cpu: "1"
memory: 768Mi
requests:
cpu: "1"
memory: 768Mi
runPolicy: Serial
triggers:
- imageChange: {}
type: ImageChange
---
kind: BuildConfig
apiVersion: build.openshift.io/v1
metadata:
name: cuda-rhel9
labels:
app: buildchain
component: cuda-rhel9
spec:
source:
type: Git
git:
uri: "https://github.com/red-hat-data-services/notebooks"
ref: f/rstudio-rhel9
strategy:
type: Docker
dockerStrategy:
dockerfilePath: "cuda/rhel9-python-3.9/Dockerfile"
noCache: true
from:
kind: "ImageStreamTag"
name: "base-rhel9:latest"
env:
- name: USERNAME
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: USERNAME
- name: PASSWORD
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: PASSWORD
- name: SERVERURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: SERVERURL
- name: BASEURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: BASEURL
output:
to:
kind: ImageStreamTag
name: "cuda-rhel9:latest"
resources:
limits:
cpu: "1"
memory: 768Mi
requests:
cpu: "1"
memory: 768Mi
runPolicy: Serial
triggers:
- imageChange: {}
type: ImageChange
---
kind: BuildConfig
apiVersion: build.openshift.io/v1
metadata:
name: cuda-rstudio-rhel9
labels:
app: buildchain
component: cuda-rstudio-image
spec:
source:
type: Git
git:
uri: "https://github.com/red-hat-data-services/notebooks"
ref: f/rstudio-rhel9
strategy:
type: Docker
dockerStrategy:
dockerfilePath: "rstudio/rhel9-python-3.9/Dockerfile"
noCache: true
from:
kind: "ImageStreamTag"
name: "cuda-rhel9:latest"
env:
- name: USERNAME
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: USERNAME
- name: PASSWORD
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: PASSWORD
- name: SERVERURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: SERVERURL
- name: BASEURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: BASEURL
output:
to:
kind: ImageStreamTag
name: "cuda-rstudio-rhel9:latest"
resources:
limits:
cpu: "1"
memory: 1Gi
requests:
cpu: "1"
memory: 1Gi
runPolicy: Serial
triggers:
- imageChange: {}
type: ImageChange
2 changes: 2 additions & 0 deletions manifests/overlays/additional/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ kind: Kustomization

resources:
- ../../base
- cuda-rstudio-buildconfig.yaml
- rstudio-buildconfig.yaml

commonLabels:
opendatahub.io/component: "true"
Expand Down
116 changes: 116 additions & 0 deletions manifests/overlays/additional/rstudio-buildconfig.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
---
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
labels:
app: buildchain
component: base-image
name: base-rhel9
spec:
name: latest
lookupPolicy:
local: true
---
kind: ImageStream
apiVersion: image.openshift.io/v1
metadata:
labels:
app: buildchain
component: rstudio-image
name: rstudio-rhel9
spec:
name: latest
lookupPolicy:
local: true
---
kind: BuildConfig
apiVersion: build.openshift.io/v1
metadata:
name: base-rhel9
labels:
app: buildchain
component: base-image
spec:
source:
type: Git
git:
uri: "https://github.com/red-hat-data-services/notebooks"
ref: f/rstudio-rhel9
strategy:
type: Docker
dockerStrategy:
dockerfilePath: "base/rhel9-python-3.9/Dockerfile"
noCache: true
output:
to:
kind: ImageStreamTag
name: "base-rhel9:latest"
resources:
limits:
cpu: "1"
memory: 768Mi
requests:
cpu: "1"
memory: 768Mi
runPolicy: Serial
triggers:
- imageChange: {}
type: ImageChange
---
kind: BuildConfig
apiVersion: build.openshift.io/v1
metadata:
name: rstudio-rhel9
labels:
app: buildchain
component: rstudio-image
spec:
source:
type: Git
git:
uri: "https://github.com/red-hat-data-services/notebooks"
ref: f/rstudio-rhel9
strategy:
type: Docker
dockerStrategy:
from:
kind: "ImageStreamTag"
name: "base-rhel9:latest"
dockerfilePath: "rstudio/rhel9-python-3.9/Dockerfile"
env:
- name: USERNAME
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: USERNAME
- name: PASSWORD
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: PASSWORD
- name: SERVERURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: SERVERURL
- name: BASEURL
valueFrom:
secretKeyRef:
name: rhel-subscription-secret
key: BASEURL
noCache: true
output:
to:
kind: ImageStreamTag
name: "rstudio-rhel9:latest"
runPolicy: Serial
resources:
limits:
cpu: "1"
memory: 768Mi
requests:
cpu: "1"
memory: 768Mi
triggers:
- imageChange: {}
type: ImageChange

0 comments on commit 13716f5

Please sign in to comment.