Skip to content
Snippets Groups Projects
Commit 38be5c11 authored by Cattani Luca's avatar Cattani Luca
Browse files

Added PostgreSQL files

parent b5eec912
No related branches found
No related tags found
No related merge requests found
gitlab-scientificnet-org-registry.yaml
postgresql-secret.yaml
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
annotations:
volume.alpha.kubernetes.io/storage-class: default
volume.beta.kubernetes.io/storage-provisioner: kubernetes.io/rbd
labels:
app: dspace-postgresql
chart: postgresql-0.8.1
heritage: Tiller
release: dspace
name: dspace-postgresql
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 8Gi
storageClassName: auto
apiVersion: v1
kind: Service
metadata:
labels:
app: dspace-postgresql
chart: postgresql-0.8.1
heritage: Tiller
release: dspace
name: dspace-postgresql
namespace: dspace
spec:
ports:
- name: postgresql
port: 5432
protocol: TCP
targetPort: postgresql
selector:
app: dspace-postgresql
sessionAffinity: None
type: ClusterIP
status:
loadBalancer: {}
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
generation: 1
labels:
app: dspace-postgresql
chart: postgresql-0.8.1
heritage: Tiller
release: dspace
name: dspace-postgresql
spec:
replicas: 1
selector:
matchLabels:
app: dspace-postgresql
strategy:
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
type: RollingUpdate
template:
metadata:
labels:
app: dspace-postgresql
spec:
containers:
- env:
- name: POSTGRES_USER
value: dspace
- name: PGUSER
value: dspace
- name: POSTGRES_DB
- name: POSTGRES_INITDB_ARGS
- name: dspaceuser
value: dbuser
- name: dspacepassword
valueFrom:
secretKeyRef:
key: dspace.password
name: dspace-secrets
- name: dspacedbname
value: dbname
- name: dspaceutilsdbname
value: dbnamespace
- name: PGDATA
value: /var/lib/postgresql/data/pgdata
- name: POSTGRES_PASSWORD
valueFrom:
secretKeyRef:
key: postgres-password
name: dspace-postgresql
- name: POD_IP
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: status.podIP
image: gitlab.scientificnet.org:4567/commul/dspace/postgres:0.3
imagePullPolicy: IfNotPresent
livenessProbe:
exec:
command:
- sh
- -c
- exec pg_isready --host $POD_IP
failureThreshold: 6
initialDelaySeconds: 60
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 5
name: dspace-postgresql
ports:
- containerPort: 5432
name: postgresql
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -c
- exec pg_isready --host $POD_IP
failureThreshold: 3
initialDelaySeconds: 5
periodSeconds: 5
successThreshold: 1
timeoutSeconds: 3
resources:
requests:
cpu: 100m
memory: 256Mi
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
volumeMounts:
- mountPath: /var/lib/postgresql/data/pgdata
name: data
subPath: postgresql-db
dnsPolicy: ClusterFirst
imagePullSecrets:
- name: gitlab-scientificnet-org-registry
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
terminationGracePeriodSeconds: 30
volumes:
- name: data
persistentVolumeClaim:
claimName: dspace-postgresql
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment