--- apiVersion: apps/v1 # for versions before 1.9.0 use apps/v1beta2 kind: Deployment metadata: name: nginx spec: strategy: type: Recreate selector: matchLabels: app: nginx replicas: 3 # tells deployment to run 1 pods matching the template template: # create pods using pod definition in this template metadata: labels: app: nginx annotations: fluentbit.io/parser: nginx # Suggest that the data should be processed using the pre-defined parser called nginx # The parser must be registered already by Fluent Bit. # https://docs.fluentbit.io/manual/filter/kubernetes spec: containers: - name: nginx image: nginx ports: - containerPort: 80 --- apiVersion: v1 kind: Service metadata: name: nginx namespace: default labels: app: nginx annotations: spec: ports: - name: http port: 80 protocol: TCP targetPort: 80 selector: app: nginx