2015-06-10 20:25:54 +00:00
|
|
|
apiVersion: v1
|
2014-10-21 05:44:14 +00:00
|
|
|
kind: Service
|
2015-05-08 00:55:36 +00:00
|
|
|
metadata:
|
2015-07-14 20:03:16 +00:00
|
|
|
name: nginx-service
|
2015-05-08 00:55:36 +00:00
|
|
|
spec:
|
|
|
|
ports:
|
2015-07-20 22:46:20 +00:00
|
|
|
- port: 8000 # the port that this service should serve on
|
|
|
|
# the container on each pod to connect to, can be a name
|
|
|
|
# (e.g. 'www') or a number (e.g. 80)
|
|
|
|
targetPort: 80
|
|
|
|
protocol: TCP
|
2015-05-08 00:55:36 +00:00
|
|
|
# just like the selector in the replication controller,
|
|
|
|
# but this time it identifies the set of pods to load balance
|
|
|
|
# traffic to.
|
|
|
|
selector:
|
2015-07-20 22:46:20 +00:00
|
|
|
app: nginx
|