summaryrefslogtreecommitdiffstats
path: root/roles/openshift_storage_glusterfs/files/v3.6/glusterfs-template.yml
blob: ab4ca3d373b75f8fc39e81944da675069f1ed2cb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
---
kind: Template
apiVersion: v1
metadata:
  name: glusterfs
  labels:
    glusterfs: template
  annotations:
    description: GlusterFS DaemonSet template
    tags: glusterfs
objects:
- kind: DaemonSet
  apiVersion: extensions/v1beta1
  metadata:
    name: glusterfs
    labels:
      glusterfs: daemonset
    annotations:
      description: GlusterFS DaemonSet
      tags: glusterfs
  spec:
    selector:
      matchLabels:
        glusterfs-node: pod
    template:
      metadata:
        name: glusterfs
        labels:
          glusterfs-node: pod
      spec:
        nodeSelector: "${{NODE_LABELS}}"
        hostNetwork: true
        containers:
        - name: glusterfs
          image: ${IMAGE_NAME}:${IMAGE_VERSION}
          imagePullPolicy: IfNotPresent
          volumeMounts:
          - name: glusterfs-heketi
            mountPath: "/var/lib/heketi"
          - name: glusterfs-run
            mountPath: "/run"
          - name: glusterfs-lvm
            mountPath: "/run/lvm"
          - name: glusterfs-etc
            mountPath: "/etc/glusterfs"
          - name: glusterfs-logs
            mountPath: "/var/log/glusterfs"
          - name: glusterfs-config
            mountPath: "/var/lib/glusterd"
          - name: glusterfs-dev
            mountPath: "/dev"
          - name: glusterfs-misc
            mountPath: "/var/lib/misc/glusterfsd"
          - name: glusterfs-cgroup
            mountPath: "/sys/fs/cgroup"
            readOnly: true
          - name: glusterfs-ssl
            mountPath: "/etc/ssl"
            readOnly: true
          securityContext:
            capabilities: {}
            privileged: true
          readinessProbe:
            timeoutSeconds: 3
            initialDelaySeconds: 100
            exec:
              command:
              - "/bin/bash"
              - "-c"
              - systemctl status glusterd.service
            periodSeconds: 10
            successThreshold: 1
            failureThreshold: 3
          livenessProbe:
            timeoutSeconds: 3
            initialDelaySeconds: 100
            exec:
              command:
              - "/bin/bash"
              - "-c"
              - systemctl status glusterd.service
            periodSeconds: 10
            successThreshold: 1
            failureThreshold: 3
          resources: {}
          terminationMessagePath: "/dev/termination-log"
        volumes:
        - name: glusterfs-heketi
          hostPath:
            path: "/var/lib/heketi"
        - name: glusterfs-run
          emptyDir: {}
        - name: glusterfs-lvm
          hostPath:
            path: "/run/lvm"
        - name: glusterfs-etc
          hostPath:
            path: "/etc/glusterfs"
        - name: glusterfs-logs
          hostPath:
            path: "/var/log/glusterfs"
        - name: glusterfs-config
          hostPath:
            path: "/var/lib/glusterd"
        - name: glusterfs-dev
          hostPath:
            path: "/dev"
        - name: glusterfs-misc
          hostPath:
            path: "/var/lib/misc/glusterfsd"
        - name: glusterfs-cgroup
          hostPath:
            path: "/sys/fs/cgroup"
        - name: glusterfs-ssl
          hostPath:
            path: "/etc/ssl"
        restartPolicy: Always
        terminationGracePeriodSeconds: 30
        dnsPolicy: ClusterFirst
        securityContext: {}
parameters:
- name: NODE_LABELS
  displayName: Daemonset Node Labels
  description: Labels which define the daemonset node selector.
  value: '{ "storagenode": "glusterfs" }'
- name: IMAGE_NAME
  displayName: GlusterFS container name
  required: True
- name: IMAGE_VERSION
  displayName: GlusterFS container versiona
  required: True