Last active
August 23, 2019 11:15
-
-
Save alex-slynko/f9d51244e3351c40b475568cc560fe18 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Service | |
metadata: | |
labels: | |
k8s-app: springone | |
name: springone | |
spec: | |
ports: | |
- port: 80 | |
targetPort: 8080 | |
selector: | |
k8s-app: springone | |
type: LoadBalancer | |
--- | |
apiVersion: policy/v1beta1 | |
kind: PodDisruptionBudget | |
metadata: | |
name: springone | |
spec: | |
minAvailable: 2 | |
selector: | |
matchLabels: | |
k8s-app: springone | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
annotations: | |
description: Great demo | |
labels: | |
k8s-app: springone | |
name: springone | |
namespace: default | |
spec: | |
progressDeadlineSeconds: 600 | |
replicas: 3 | |
selector: | |
matchLabels: | |
k8s-app: springone | |
strategy: | |
rollingUpdate: | |
maxSurge: 25% | |
maxUnavailable: 25% | |
type: RollingUpdate | |
template: | |
metadata: | |
labels: | |
k8s-app: springone | |
name: springone | |
spec: | |
affinity: | |
podAntiAffinity: | |
requiredDuringSchedulingIgnoredDuringExecution: | |
- labelSelector: | |
matchExpressions: | |
- key: k8s-app | |
operator: In | |
values: | |
- springone | |
topologyKey: "kubernetes.io/hostname" | |
volumes: | |
- name: shared-data | |
emptyDir: {} | |
- name: config-volume | |
configMap: | |
name: springone | |
items: | |
- key: application.properties | |
path: application.properties | |
initContainers: | |
- name: run-migration | |
image: s1pdemo/springmusicmigration:v2 | |
command: ["/bin/run_migration.sh"] | |
containers: | |
- image: s1pdemo/tweet_loader:21fab0554 | |
name: poller | |
volumeMounts: | |
- name: shared-data | |
mountPath: /tweet-info | |
- image: s1pdemo/springmusic:v2 | |
imagePullPolicy: Always | |
name: springone | |
env: | |
- name: SOMETHING | |
value: value | |
securityContext: | |
privileged: false | |
volumeMounts: | |
- name: shared-data | |
mountPath: /data/tweets | |
readOnly: true | |
- name: config-volume | |
mountPath: "/config" | |
readOnly: true | |
readinessProbe: | |
httpGet: | |
path: /actuator/health | |
port: 8080 | |
initialDelaySeconds: 10 | |
periodSeconds: 3 | |
successThreshold: 2 | |
livenessProbe: | |
httpGet: | |
path: /actuator/health | |
port: 8080 | |
initialDelaySeconds: 45 | |
periodSeconds: 3 | |
dnsPolicy: ClusterFirst | |
restartPolicy: Always | |
schedulerName: default-scheduler | |
securityContext: {} | |
terminationGracePeriodSeconds: 30 | |
--- | |
apiVersion: v1 | |
data: | |
application.properties: spring.music=springonedemoCONFIGVALUE | |
kind: ConfigMap | |
metadata: | |
name: springone |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment