Skip to content

Instantly share code, notes, and snippets.

@danehans
Created March 1, 2016 21:49
Show Gist options
  • Save danehans/cb744bd10084175ccc44 to your computer and use it in GitHub Desktop.
Save danehans/cb744bd10084175ccc44 to your computer and use it in GitHub Desktop.
kube_test_app
apiVersion: v1
kind: Service
metadata:
labels:
name: web
role: service
name: web
spec:
type: NodePort
ports:
# the port that this service should serve on
- name: web
nodePort: 30302
port: 80
protocol: TCP
selector:
web: "true"
---
apiVersion: v1
kind: ReplicationController
metadata:
name: web
spec:
replicas: 1
selector:
web: "true"
template:
metadata:
labels:
name: web
web: "true"
role: web
spec:
containers:
- name: web
image: larsks/mini-httpd
env:
- name: WEB
value: "true"
ports:
- containerPort: 80
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment