Skip to content
This repository was archived by the owner on Sep 15, 2021. It is now read-only.

Commit 441bd5a

Browse files
authored
Move test controller and change liveness probe for coordinator. (#169)
1 parent baa17c2 commit 441bd5a

File tree

10 files changed

+38
-22
lines changed

10 files changed

+38
-22
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ install:
99
- sudo mv skaffold /usr/local/bin
1010

1111
script:
12-
- cd interoptest && skaffold build --profile travis-ci
12+
- cd interoptest && ./build_and_run.sh

interoptest/build_and_run.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/bin/sh
2+
set -e
3+
4+
# First build
5+
echo "Building containers.."
6+
skaffold build --profile travis-ci
7+
8+
# Run the containers
9+
# [TODO:rghetia] invoke skaffold run after minikube issue is sorted out.
10+
# skaffold run
11+
# sleep 60
12+
13+
# Run tests
14+
# cd ./src/testcontroller
15+
# sudo pip install -r requirements.txt
16+
# python run.py

interoptest/kubernetes-manifests/loadbalancer.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ spec:
2222
app: testcoordinator
2323
ports:
2424
- name: http
25-
port: 10000
26-
targetPort: 10000
25+
port: 10003
26+
targetPort: 10003

interoptest/kubernetes-manifests/testcoordinator.yaml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -28,28 +28,28 @@ spec:
2828
image: gcr.io/opencensus-interoptest/testcoordinator
2929
imagePullPolicy: Never
3030
ports:
31-
- containerPort: 10000
31+
- containerPort: 10003
3232
name: testcoordinator
3333
env:
3434
- name: PORT
35-
value: "10000"
35+
value: "10003"
3636
resources:
3737
requests:
3838
cpu: 200m
3939
memory: 180Mi
4040
limits:
4141
cpu: 300m
4242
memory: 300Mi
43-
readinessProbe:
44-
tcpSocket:
45-
port: 10000
46-
initialDelaySeconds: 5
47-
periodSeconds: 10
48-
livenessProbe:
49-
tcpSocket:
50-
port: 10000
51-
initialDelaySeconds: 10
52-
periodSeconds: 10
43+
# readinessProbe:
44+
# tcpSocket:
45+
# port: 10003
46+
# initialDelaySeconds: 5
47+
# periodSeconds: 10
48+
# livenessProbe:
49+
# tcpSocket:
50+
# port: 10003
51+
# initialDelaySeconds: 10
52+
# periodSeconds: 10
5353
---
5454
apiVersion: v1
5555
kind: Service
@@ -61,5 +61,5 @@ spec:
6161
app: testcoordinator
6262
ports:
6363
- name: testcoordinator
64-
port: 10000
65-
targetPort: 10000
64+
port: 10003
65+
targetPort: 10003
File renamed without changes.

interoptest/interoperability_test_pb2_grpc.py renamed to interoptest/src/testcontroller/interoperability_test_pb2_grpc.py

File renamed without changes.
File renamed without changes.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
-v --verbose Verbose output
2626
-t --timeout=<timeout> Seconds to wait for service calls [default: 60]
2727
-o --host=<host> Test service host [default: localhost]
28-
-p --port=<port> Test service port [default: 10000]
28+
-p --port=<port> Test service port [default: 10003]
2929
3030
"""
3131

interoptest/src/testcoordinator/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ FROM alpine as release
1616
RUN apk add --no-cache ca-certificates curl
1717

1818
COPY --from=builder /testcoordinator /testcoordinator
19-
EXPOSE 10000
19+
EXPOSE 10003
2020
ENTRYPOINT ["/testcoordinator"]
2121

interoptest/src/testcoordinator/cmd/main.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,9 @@ func main() {
7373
}
7474

7575
func parseFlags() (regSrvAddr, receiverAddr, interopSrvAddr string) {
76-
regSrvAddrPtr := flag.String("registration_service_address", "localhost:10002", "Address of the registration service")
77-
recieverAddrPtr := flag.String("oc_receiver_address", "localhost:10001", "Address of OC Agent trace receiver")
78-
interopSrvAddrPtr := flag.String("interop_service_address", "localhost:10003", "Address of the interop test service")
76+
regSrvAddrPtr := flag.String("registration_service_address", "0.0.0.0:10002", "Address of the registration service")
77+
recieverAddrPtr := flag.String("oc_receiver_address", "0.0.0.0:10001", "Address of OC Agent trace receiver")
78+
interopSrvAddrPtr := flag.String("interop_service_address", "0.0.0.0:10003", "Address of the interop test service")
7979
flag.Parse()
8080
return *regSrvAddrPtr, *recieverAddrPtr, *interopSrvAddrPtr
8181
}

0 commit comments

Comments
 (0)