mirror of
https://github.com/minio/minio.git
synced 2024-12-29 00:23:21 -05:00
ba0c7544ea
- Remove hostPort from Kubernetes deployment example docs. Initially hostPort was added to ensure Minio pods are allocated to separate machines, but as per latest Kubernetes documents this is not recommended approach (ref: https://kubernetes.io/docs/concepts/ configuration/overview/#services). To define pod allocations, Affinity and Anti-Affinity concepts are the recommended approach. (ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node) - Add Minio release tag to Docker-Compose example file.
44 lines
1.2 KiB
YAML
44 lines
1.2 KiB
YAML
apiVersion: extensions/v1beta1
|
|
kind: Deployment
|
|
metadata:
|
|
# This name uniquely identifies the Deployment
|
|
name: minio-deployment
|
|
spec:
|
|
strategy:
|
|
type: Recreate
|
|
template:
|
|
metadata:
|
|
labels:
|
|
# Label is used as selector in the service.
|
|
app: minio
|
|
spec:
|
|
# Refer to the secret created earlier
|
|
volumes:
|
|
- name: gcs-credentials
|
|
secret:
|
|
# Name of the Secret created earlier
|
|
secretName: gcs-credentials
|
|
containers:
|
|
- name: minio
|
|
# Pulls the default Minio image from Docker Hub
|
|
image: minio/minio:RELEASE.2018-02-09T22-40-05Z
|
|
args:
|
|
- gateway
|
|
- gcs
|
|
- gcp_project_id
|
|
env:
|
|
# Minio access key and secret key
|
|
- name: MINIO_ACCESS_KEY
|
|
value: "minio"
|
|
- name: MINIO_SECRET_KEY
|
|
value: "minio123"
|
|
# Google Cloud Service uses this variable
|
|
- name: GOOGLE_APPLICATION_CREDENTIALS
|
|
value: "/etc/credentials/application_default_credentials.json"
|
|
ports:
|
|
- containerPort: 9000
|
|
# Mount the volume into the pod
|
|
volumeMounts:
|
|
- name: gcs-credentials
|
|
mountPath: "/etc/credentials"
|
|
readOnly: true |