Skip to content

Instantly share code, notes, and snippets.

@mandarjog
Created June 11, 2019 15:58
Show Gist options
  • Save mandarjog/201d3fd0940fe94e0db15df91a6c173e to your computer and use it in GitHub Desktop.
Save mandarjog/201d3fd0940fe94e0db15df91a6c173e to your computer and use it in GitHub Desktop.
Acccess Log service
# Source: twoPodTest/templates/als.yaml
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
labels:
app: accesslog-grpc
name: accesslog-grpc
spec:
selector:
matchLabels:
app: accesslog-grpc
template:
metadata:
annotations:
sidecar.istio.io/inject: "false"
linkerd.io/inject: "false"
prometheus.io/scrape: "true"
labels:
app: accesslog-grpc
spec:
containers:
- name: als
image: gcr.io/mixologist-142215/als:v002
ports:
- containerPort: 18090
name: grpc-accesslog
- containerPort: 18091
name: http-monitoring
resources:
requests:
cpu: "2000m"
memory: "2000m"
---
apiVersion: v1
kind: Service
metadata:
name: accesslog-grpc
spec:
ports:
- name: grpc-accesslog
port: 18090
protocol: TCP
- name: http-monitoring
port: 18091
protocol: TCP
selector:
app: accesslog-grpc
---
# if the access log service receives header["x-sleep"] number of miliseconds.
# This can be used to simulate a slow service.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment