113 lines
2.3 KiB
YAML
113 lines
2.3 KiB
YAML
apiVersion: v1
|
|
items:
|
|
- apiVersion: extensions/v1beta1
|
|
kind: Ingress
|
|
metadata:
|
|
name: example-ingress
|
|
labels:
|
|
app: example
|
|
annotations:
|
|
spec:
|
|
rules:
|
|
- host: app.example.com
|
|
http:
|
|
paths:
|
|
- path: /
|
|
backend:
|
|
serviceName: example-svc
|
|
servicePort: 80
|
|
tls:
|
|
- apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: example-svc
|
|
labels:
|
|
app: example
|
|
spec:
|
|
ports:
|
|
- name: http
|
|
port: 80
|
|
targetPort: http
|
|
selector:
|
|
app: example
|
|
type: NodePort
|
|
status:
|
|
loadBalancer: {}
|
|
- apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: example-configmap
|
|
labels:
|
|
app: example
|
|
data:
|
|
application.rb: |-
|
|
- apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: example-data-pvc
|
|
annotations: {}
|
|
labels:
|
|
app: example
|
|
spec:
|
|
accessModes:
|
|
- ReadWriteOnce
|
|
resources:
|
|
requests:
|
|
storage: 100Mi
|
|
status: {}
|
|
- apiVersion: extensions/v1beta1
|
|
kind: Deployment
|
|
metadata:
|
|
name: example-deployment
|
|
labels:
|
|
app: example
|
|
spec:
|
|
replicas: 1
|
|
strategy:
|
|
type: Recreate
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: example
|
|
spec:
|
|
containers:
|
|
- name: example
|
|
image: bitnami/ruby-example:0.0.1
|
|
ports:
|
|
- containerPort: 3000
|
|
name: http
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /welcome/index
|
|
port: http
|
|
httpHeaders:
|
|
- name: Host
|
|
value: app.example.com
|
|
initialDelaySeconds: 15
|
|
readinessProbe:
|
|
httpGet:
|
|
path: /welcome/index
|
|
port: http
|
|
httpHeaders:
|
|
- name: Host
|
|
value: app.example.com
|
|
initialDelaySeconds: 5
|
|
resources: {}
|
|
volumeMounts:
|
|
- mountPath: /app/config/application.rb
|
|
name: example-config
|
|
subPath: application.rb
|
|
- mountPath: /app/data
|
|
name: example-data
|
|
restartPolicy: Always
|
|
volumes:
|
|
- name: example-config
|
|
configMap:
|
|
name: example-configmap
|
|
- name: example-data
|
|
persistentVolumeClaim:
|
|
claimName: example-data-pvc
|
|
status: {}
|
|
kind: List
|
|
metadata: {}
|