mirror of https://github.com/minio/minio.git
46 lines
1.4 KiB
YAML
46 lines
1.4 KiB
YAML
|
apiVersion: apps/v1
|
||
|
kind: DaemonSet
|
||
|
metadata:
|
||
|
name: minio
|
||
|
labels:
|
||
|
app: minio
|
||
|
spec:
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app: minio
|
||
|
template:
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: minio
|
||
|
spec:
|
||
|
# We only deploy minio to the specified nodes. select your nodes by using `kubectl label node hostname1 -l minio-server=true`
|
||
|
nodeSelector:
|
||
|
minio-server: "true"
|
||
|
# This is to maximize network performance, the headless service can be used to connect to a random host.
|
||
|
hostNetwork: true
|
||
|
# We're just using a hostpath. This path must be the same on all servers, and should be the largest, fastest block device you can fit.
|
||
|
volumes:
|
||
|
- name: storage
|
||
|
hostPath:
|
||
|
path: /data/minio/
|
||
|
containers:
|
||
|
- name: minio
|
||
|
env:
|
||
|
- name: MINIO_ACCESS_KEY
|
||
|
value: "minio"
|
||
|
- name: MINIO_SECRET_KEY
|
||
|
value: "minio123"
|
||
|
image: minio/minio:RELEASE.2018-04-04T05-20-54Z
|
||
|
# Unfortunately you must manually define each server. Perhaps autodiscovery via DNS can be implemented in the future.
|
||
|
args:
|
||
|
- server
|
||
|
- http://hostname1:9000/data/minio
|
||
|
- http://hostname2:9000/data/minio
|
||
|
- http://hostname3:9000/data/minio
|
||
|
- http://hostname4:9000/data/minio
|
||
|
ports:
|
||
|
- containerPort: 9000
|
||
|
volumeMounts:
|
||
|
- name: storage
|
||
|
mountPath: /data/minio/
|