Skip to content

Commit

Permalink
fix for volume mount issue
Browse files Browse the repository at this point in the history
  • Loading branch information
jaise-aot committed Nov 7, 2023
1 parent dbe5240 commit da81763
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 37 deletions.
28 changes: 0 additions & 28 deletions openshift/templates/etl/debezium-postgis.build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,31 +57,3 @@ parameters:
description: The path to the docker file defining the build.
required: false
value: "Dockerfile"
- name: DEBEZIUM_VERSION
displayName: Debezium Version
description: Debezium image version.
required: false
value: "1.9"
- name: ORACLE_JDBC_VERSION
displayName: Oracle JDBC Version
description: Oracle JDBC Version.
required: false
value: "21.6.0.0"
- name: ORACLE_JDBC_MD5
displayName: Oracle JDBC Checksum
description: Oracle JDBC File Checksum.
required: false
value: "312e6f4ec9932bbf74a4461669970c4b"
- name: KAFKA_JDBC_VERSION
displayName: Kafka JDBC Version
description: Kafka Jdbc Version.
required: false
value: "5.3.1"
- name: ORACLE_DB_HOST
displayName: Oracle DB Host
description: Oracle Database Host Name
required: true
- name: ORACLE_DB_PORT
displayName: Oracle DB Port
description: Oracle Database Port.
required: true
53 changes: 44 additions & 9 deletions openshift/templates/etl/debezium-postgis.deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,19 @@ metadata:
tags: "${API_NAME}"
name: "${API_NAME}-deploy"
objects:
- kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: "${API_NAME}"
labels:
app: "${API_NAME}"
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: "${DB_PVC_SIZE}"
storageClassName: netapp-file-standard
- kind: DeploymentConfig
apiVersion: apps.openshift.io/v1
metadata:
Expand Down Expand Up @@ -49,6 +62,10 @@ objects:
template: "${API_NAME}-deploy"
role: api
spec:
volumes:
- name: "${API_NAME}"
persistentVolumeClaim:
claimName: "${API_NAME}"
containers:
- name: "${API_NAME}"
image: "${API_NAME}"
Expand All @@ -62,17 +79,15 @@ objects:
- name: POSTGRES_PASSWORD
value: postgres
- name: POSTGRES_DB
value: postgres
resources:
requests:
cpu: "50m"
memory: "250Mi"
limits:
cpu: "150m"
memory: "500Mi"
value: postgres
- name: PGDATA
value: /var/lib/postgresql/data/pgdata
terminationMessagePath: "/dev/termination-log"
terminationMessagePolicy: File
imagePullPolicy: Always
volumeMounts:
- name: "${API_NAME}"
mountPath: "/var/lib/postgresql/data"
restartPolicy: Always
terminationGracePeriodSeconds: 30
dnsPolicy: ClusterFirst
Expand Down Expand Up @@ -140,4 +155,24 @@ parameters:
displayName: Environment TAG name
description: The TAG name for this environment, e.g., dev, test, prod
required: true
value: latest
value: latest
- description: Starting amount of CPU the container can use.
displayName: CPU REQUEST
name: CPU_REQUEST
value: '250m'
- description: Maximum amount of CPU the container can use.
displayName: CPU Limit
name: CPU_LIMIT
value: '1'
- description: Starting amount of memory the container can use.
displayName: Memory Request
name: MEMORY_REQUEST
value: 512Mi
- description: Maximum amount of memory the container can use.
displayName: Memory Limit
name: MEMORY_LIMIT
value: 512Mi
- description: The size of the persistent volume to create.
displayName: Persistent Volume Size
name: DB_PVC_SIZE
value: 1Gi

0 comments on commit da81763

Please sign in to comment.