Skip to content
This repository has been archived by the owner on May 3, 2022. It is now read-only.

Commit

Permalink
kubernetes: improve shipper's deployments
Browse files Browse the repository at this point in the history
This brings the Shipper you deploy out of the box closer to the way we
deploy it in Booking.

This also fixes a tiny bug where the metrics port was not exposed in the
`shipper` deployment.
  • Loading branch information
juliogreff committed Sep 24, 2019
1 parent a418306 commit 3f75741
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Dockerfile.shipper
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ FROM alpine:3.8
LABEL authors="Parham Doustdar <[email protected]>, Alexey Surikov <[email protected]>, Igor Sutton <[email protected]>, Ben Tyler <[email protected]>"
RUN apk add ca-certificates
ADD build/shipper.linux-amd64 /bin/shipper
ENTRYPOINT ["shipper", "-v", "4", "-logtostderr"]
ENTRYPOINT ["shipper"]
2 changes: 1 addition & 1 deletion Dockerfile.shipper-state-metrics
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ FROM alpine:3.8
LABEL authors="Parham Doustdar <[email protected]>, Alexey Surikov <[email protected]>, Igor Sutton <[email protected]>, Ben Tyler <[email protected]>"
RUN apk add ca-certificates
ADD build/shipper-state-metrics.linux-amd64 /bin/shipper-state-metrics
ENTRYPOINT ["shipper-state-metrics", "-v", "2"]
ENTRYPOINT ["shipper-state-metrics"]
15 changes: 14 additions & 1 deletion kubernetes/shipper-state-metrics.deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@ spec:
selector:
matchLabels:
app: shipper-state-metrics
strategy:
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
type: RollingUpdate
template:
metadata:
labels:
Expand All @@ -18,6 +23,14 @@ spec:
- name: shipper-state-metrics
image: <IMAGE>
imagePullPolicy: Always
args:
- "-v"
- "2"
ports:
- containerPort: 8890
- name: metrics
containerPort: 8890
readinessProbe:
httpGet:
path: /metrics
port: 8890
serviceAccountName: shipper-management-cluster
15 changes: 14 additions & 1 deletion kubernetes/shipper.deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,17 @@ spec:
selector:
matchLabels:
app: shipper
strategy:
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
type: RollingUpdate
template:
metadata:
labels:
app: shipper
annotations:
prometheus.io/scrape_port: '8889'
spec:
containers:
- name: shipper
Expand All @@ -27,8 +34,14 @@ spec:
- "9443"
- "-resync"
- "10m"
- "-v"
- "4"
- "-logtostderr"
ports:
- containerPort: 9443
- name: metrics
containerPort: 8889
- name: webhook
containerPort: 9443
volumeMounts:
- mountPath: /etc/webhook/certs
name: webhook-certs
Expand Down

0 comments on commit 3f75741

Please sign in to comment.