Last active
July 13, 2020 22:24
-
-
Save stevenctl/c51503c9f03635914bea1d4c48f4c757 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# sets up a, b, c deployments with services for a and b | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: a | |
labels: | |
app: a | |
spec: | |
ports: | |
- name: tcp | |
port: 9000 | |
- name: tcp-other | |
port: 9001 | |
selector: | |
app: a | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: a | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: a | |
version: v1 | |
template: | |
metadata: | |
labels: | |
app: a | |
version: v1 | |
spec: | |
containers: | |
- name: tcp-echo | |
image: docker.io/istio/tcp-echo-server:1.2 | |
imagePullPolicy: IfNotPresent | |
args: [ "9000,9001", "hello" ] | |
resources: | |
limits: | |
cpu: 100m | |
requests: | |
cpu: 100m | |
ports: | |
- containerPort: 9000 | |
- containerPort: 9001 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: b | |
labels: | |
app: b | |
spec: | |
ports: | |
- name: tcp | |
port: 9000 | |
- name: tcp-other | |
port: 9001 | |
selector: | |
app: b | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: b | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: b | |
version: v1 | |
template: | |
metadata: | |
labels: | |
app: b | |
version: v1 | |
spec: | |
containers: | |
- name: tcp-echo | |
image: docker.io/istio/tcp-echo-server:1.2 | |
imagePullPolicy: IfNotPresent | |
args: [ "9000,9001", "hello" ] | |
ports: | |
- containerPort: 9000 | |
- containerPort: 9001 | |
--- | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: c | |
labels: | |
app: c | |
spec: | |
ports: | |
- name: tcp | |
port: 9000 | |
- name: tcp-other | |
port: 9001 | |
selector: | |
app: c | |
--- | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: c | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: c | |
version: v1 | |
template: | |
metadata: | |
labels: | |
app: c | |
version: v1 | |
spec: | |
containers: | |
- name: tcp-echo | |
image: docker.io/istio/tcp-echo-server:1.2 | |
imagePullPolicy: IfNotPresent | |
args: [ "9000,9001", "hello" ] | |
ports: | |
- containerPort: 9000 | |
- containerPort: 9001 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment