summaryrefslogtreecommitdiffstats
path: root/kubernetes/consul/templates/consul-agent-deployment.yaml
blob: 15318660b5a2de1c1db7c7ef2a9cc0a9d24651a6 (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
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  labels:
    app: consul-agent
  name: consul-agent
  namespace: "{{ .Values.nsPrefix }}-consul"
spec:
  selector:
    matchLabels:
      app: consul-agent
  template:
    metadata:
      labels:
        app: consul-agent
      name: consul-agent
    spec:
      containers:
      - image: "{{ .Values.consulimageRegistry }}:{{ .Values.consuldockerTag }}"
        command: ["/usr/local/bin/docker-entrypoint.sh"]
        args: ["agent","-client","0.0.0.0","-enable-script-checks","-join","consul-server.{{ .Values.nsPrefix }}-consul"]
        name: consul-server
        volumeMounts:
        - mountPath: /consul/config
          name: consul-agent-config
      volumes:
      - hostPath:
          path: {{ .Values.rootHostPath }}/{{ .Values.nsPrefix }}/consul/consul-agent-config
        name: consul-agent-config