Merge pull request #8078 from satnam6502/fluentd-gcp

Convert Fluentd to Cloud Logging pod specs to YAML
This commit is contained in:
Alex Robinson 2015-05-11 16:55:14 -07:00
commit e2b7ef8d2c
3 changed files with 31 additions and 32 deletions

View File

@ -1,30 +0,0 @@
{
"apiVersion": "v1beta3",
"kind": "Pod",
"metadata": {"name": "fluentd-cloud-logging"},
"spec": {
"containers": [
{ "name": "fluentd-cloud-logging",
"image": "gcr.io/google_containers/fluentd-gcp:1.5",
"env": [
{ "name": "FLUENTD_ARGS",
"value": "-qq"}
],
"volumeMounts": [
{ "name": "varlog",
"mountPath": "/varlog"},
{ "name": "containers",
"mountPath": "/var/lib/docker/containers"}
]
}
],
"volumes": [
{ "name": "varlog",
"hostPath": { "path": "/var/log"}
},
{ "name": "containers",
"hostPath": { "path": "/var/lib/docker/containers"}
}
]
}
}

View File

@ -0,0 +1,29 @@
apiVersion: v1beta3
kind: Pod
metadata:
name: fluentd-cloud-logging
spec:
containers:
- name: fluentd-cloud-logging
image: gcr.io/google_containers/fluentd-gcp:1.5
env:
- name: "FLUENTD_ARGS"
value: "-qq"
volumeMounts:
- name: varlog
mountPath: /varlog
- name: containers
mountPath: /var/lib/docker/containers
- name: token-admin
mountPath: /etc/token-admin
readOnly: true
volumes:
- name: varlog
hostPath:
path: /var/log
- name: containers
hostPath:
path: /var/lib/docker/containers
- name: token-admin
secret:
secretName: token-admin

View File

@ -1,6 +1,6 @@
/etc/kubernetes/manifests/fluentd-gcp.json:
/etc/kubernetes/manifests/fluentd-gcp.yaml:
file.managed:
- source: salt://fluentd-gcp/fluentd-gcp.json
- source: salt://fluentd-gcp/fluentd-gcp.yaml
- user: root
- group: root
- mode: 644