generated from bcgov/quickstart-openshift
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(ci): Update minio deployment. (#174)
- Loading branch information
Showing
6 changed files
with
217 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,15 @@ | ||
FROM minio/minio:RELEASE.2020-11-25T22-36-25Z | ||
|
||
COPY ./minio-entrypoint.sh / | ||
|
||
RUN ["chmod", "+x", "/minio-entrypoint.sh"] | ||
|
||
USER 1001 | ||
|
||
ENTRYPOINT ["/minio-entrypoint.sh"] | ||
|
||
# RUN mkdir -p $MINIO_DATA_DIR/aquifer-docs | ||
# RUN mkdir -p $MINIO_DATA_DIR/driller-docs | ||
# RUN mkdir -p $MINIO_DATA_DIR/gwells | ||
# RUN mkdir -p $MINIO_DATA_DIR/well-docs | ||
# RUN mkdir -p $MINIO_DATA_DIR/gwells-docs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,139 @@ | ||
kind: Template | ||
apiVersion: template.openshift.io/v1 | ||
metadata: | ||
annotations: | ||
description: "Minio deployment" | ||
labels: | ||
app: "${NAME}" | ||
template: "${NAME}-template" | ||
name: "${NAME}" | ||
parameters: | ||
- name: "NAME" | ||
displayName: "App to deploy" | ||
value: "minio" | ||
- name: "SRC_NAMESPACE" | ||
displayName: "Namespace containing the deployment source" | ||
value: "moe-gwells-tools" | ||
- name: "SRC_IMAGE" | ||
displayName: "Name of source image" | ||
value: "minio" | ||
- name: "DEST_PVC_SIZE" | ||
displayName: "PVC size" | ||
value: "1Gi" | ||
- name: "DEST_PVC_ACCESS" | ||
displayName: "PVC access mode" | ||
value: "ReadWriteOnce" | ||
- name: "IMAGE_TAG" | ||
required: true | ||
- name: "MINIO_DATA_DIR" | ||
default: /opt/minio/s3/data | ||
- name: "NAME_SUFFIX" | ||
required: false | ||
objects: | ||
- apiVersion: v1 | ||
kind: PersistentVolumeClaim | ||
metadata: | ||
finalizers: | ||
- kubernetes.io/pvc-protection | ||
name: "gwells-${NAME_SUFFIX}-minio-config-vol-v2" | ||
labels: | ||
app: nr-gwells-${NAME_SUFFIX} | ||
spec: | ||
accessModes: | ||
- ${DEST_PVC_ACCESS} | ||
resources: | ||
requests: | ||
storage: ${DEST_PVC_SIZE} | ||
storageClassName: netapp-file-standard | ||
- apiVersion: v1 | ||
kind: PersistentVolumeClaim | ||
metadata: | ||
finalizers: | ||
- kubernetes.io/pvc-protection | ||
name: "gwells-${NAME_SUFFIX}-minio-data-vol" | ||
labels: | ||
app: nr-gwells-${NAME_SUFFIX} | ||
spec: | ||
accessModes: | ||
- ${DEST_PVC_ACCESS} | ||
resources: | ||
requests: | ||
storage: ${DEST_PVC_SIZE} | ||
storageClassName: netapp-file-standard | ||
- apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
labels: | ||
app: nr-gwells-${NAME_SUFFIX} | ||
name: "gwells-${NAME_SUFFIX}-minio" | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
deployment: "gwells-${NAME_SUFFIX}-minio" | ||
strategy: | ||
activeDeadlineSeconds: 3000 | ||
recreateParams: | ||
timeoutSeconds: 600 | ||
type: Recreate | ||
template: | ||
metadata: | ||
labels: | ||
name: "gwells-${NAME_SUFFIX}-minio" | ||
deployment: "gwells-${NAME_SUFFIX}-minio" | ||
spec: | ||
containers: | ||
- env: | ||
- name: MINIO_ACCESS_KEY | ||
valueFrom: | ||
secretKeyRef: | ||
name: gwells-${NAME_SUFFIX}-minio | ||
key: MINIO_ACCESS_KEY | ||
- name: MINIO_SECRET_KEY | ||
valueFrom: | ||
secretKeyRef: | ||
name: gwells-${NAME_SUFFIX}-minio | ||
key: MINIO_SECRET_KEY | ||
- name: MINIO_DATA_DIR | ||
value: /opt/minio/s3/data | ||
- name: MINIO_CONFIG_DIR | ||
value: /opt/minio/s3/config | ||
image: ghcr.io/bcgov/nr-gwells/minio:${IMAGE_TAG} | ||
imagePullPolicy: Always | ||
name: "gwells-${NAME_SUFFIX}-minio" | ||
ports: | ||
- containerPort: 9000 | ||
protocol: TCP | ||
resources: | ||
limits: | ||
cpu: 150m | ||
requests: | ||
cpu: 100m | ||
terminationMessagePath: /dev/termination-log | ||
terminationMessagePolicy: File | ||
volumeMounts: | ||
- mountPath: /opt/minio/s3/config | ||
name: config-vol | ||
- mountPath: /opt/minio/s3/data | ||
name: data-vol | ||
restartPolicy: Always | ||
terminationGracePeriodSeconds: 30 | ||
volumes: | ||
- name: config-vol | ||
persistentVolumeClaim: | ||
claimName: "gwells-${NAME_SUFFIX}-minio-config-vol-v2" | ||
- name: data-vol | ||
persistentVolumeClaim: | ||
claimName: "gwells-${NAME_SUFFIX}-minio-data-vol" | ||
- kind: Service | ||
apiVersion: v1 | ||
metadata: | ||
labels: | ||
app: nr-gwells-${NAME_SUFFIX} | ||
name: "gwells-${NAME_SUFFIX}-minio" | ||
spec: | ||
ports: | ||
- name: 9000-tcp | ||
port: 9000 | ||
protocol: TCP | ||
targetPort: 9000 |
Oops, something went wrong.