istioinaction/book-source-code

Ch 2.3 code example not working

matthewbrahms opened this issue · 0 comments

Environment:

minikube version: v1.2.0
$kubectl version
Client Version: version.Info{Major:"1", Minor:"15", GitVersion:"v1.15.0", GitCommit:"e8462b5b5dc2584fdcd18e6bcfe9f1e4d970a529", GitTreeState:"clean", BuildDate:"2019-06-19T16:40:16Z", GoVersion:"go1.12.5", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"15", GitVersion:"v1.15.0", GitCommit:"e8462b5b5dc2584fdcd18e6bcfe9f1e4d970a529", GitTreeState:"clean", BuildDate:"2019-06-19T16:32:14Z", GoVersion:"go1.12.5", Compiler:"gc", Platform:"linux/amd64"}
$istioctl version
client version: 1.2.0
citadel version: 1.2.0
egressgateway version: 1.2.0
galley version: 1.2.0
ingressgateway version: 1.2.0
pilot version: 1.2.0
policy version: 1.2.0
sidecar-injector version: 1.2.0
telemetry version: 1.2.0

After running the command:

kubectl create -f <(istioctl kube-inject -f install/catalog-service/catalog-all.yaml)

Output I get is:

$kubectl get pods
NAME                       READY   STATUS    RESTARTS   AGE
catalog-7546f55f8c-59th2   1/2     Running   3          13m

Verified spring-boot container is working:

$kubectl logs catalog-7546f55f8c-59th2 -c spring-boot
JSON Server is running

Below is the logs from the istio-proxy container:

kubectl logs catalog-7546f55f8c-59th2 -c istio-proxy
2019-07-01T18:55:04.323900Z	info	FLAG: --applicationPorts="[8080,9779,8778]"
2019-07-01T18:55:04.323958Z	info	FLAG: --binaryPath="/usr/local/bin/envoy"
2019-07-01T18:55:04.323962Z	info	FLAG: --concurrency="2"
2019-07-01T18:55:04.323965Z	info	FLAG: --configPath="/etc/istio/proxy"
2019-07-01T18:55:04.323968Z	info	FLAG: --connectTimeout="10s"
2019-07-01T18:55:04.323970Z	info	FLAG: --controlPlaneAuthPolicy="NONE"
2019-07-01T18:55:04.323972Z	info	FLAG: --controlPlaneBootstrap="true"
2019-07-01T18:55:04.323974Z	info	FLAG: --customConfigFile=""
2019-07-01T18:55:04.323976Z	info	FLAG: --datadogAgentAddress=""
2019-07-01T18:55:04.323978Z	info	FLAG: --disableInternalTelemetry="false"
2019-07-01T18:55:04.323980Z	info	FLAG: --discoveryAddress="istio-pilot.istio-system:15010"
2019-07-01T18:55:04.323982Z	info	FLAG: --dnsRefreshRate="300s"
2019-07-01T18:55:04.323984Z	info	FLAG: --domain="istioinaction.svc.cluster.local"
2019-07-01T18:55:04.323986Z	info	FLAG: --drainDuration="45s"
2019-07-01T18:55:04.323988Z	info	FLAG: --envoyMetricsServiceAddress=""
2019-07-01T18:55:04.323990Z	info	FLAG: --help="false"
2019-07-01T18:55:04.323992Z	info	FLAG: --id=""
2019-07-01T18:55:04.323994Z	info	FLAG: --ip=""
2019-07-01T18:55:04.323995Z	info	FLAG: --lightstepAccessToken=""
2019-07-01T18:55:04.323997Z	info	FLAG: --lightstepAddress=""
2019-07-01T18:55:04.323999Z	info	FLAG: --lightstepCacertPath=""
2019-07-01T18:55:04.324001Z	info	FLAG: --lightstepSecure="false"
2019-07-01T18:55:04.324002Z	info	FLAG: --log_as_json="false"
2019-07-01T18:55:04.324004Z	info	FLAG: --log_caller=""
2019-07-01T18:55:04.324006Z	info	FLAG: --log_output_level="default:info"
2019-07-01T18:55:04.324008Z	info	FLAG: --log_rotate=""
2019-07-01T18:55:04.324010Z	info	FLAG: --log_rotate_max_age="30"
2019-07-01T18:55:04.324012Z	info	FLAG: --log_rotate_max_backups="1000"
2019-07-01T18:55:04.324014Z	info	FLAG: --log_rotate_max_size="104857600"
2019-07-01T18:55:04.324016Z	info	FLAG: --log_stacktrace_level="default:none"
2019-07-01T18:55:04.324020Z	info	FLAG: --log_target="[stdout]"
2019-07-01T18:55:04.324022Z	info	FLAG: --mixerIdentity=""
2019-07-01T18:55:04.324024Z	info	FLAG: --parentShutdownDuration="1m0s"
2019-07-01T18:55:04.324026Z	info	FLAG: --pilotIdentity=""
2019-07-01T18:55:04.324029Z	info	FLAG: --proxyAdminPort="15000"
2019-07-01T18:55:04.324031Z	info	FLAG: --proxyComponentLogLevel="misc:error"
2019-07-01T18:55:04.324033Z	info	FLAG: --proxyLogLevel="warning"
2019-07-01T18:55:04.324035Z	info	FLAG: --serviceCluster="catalog.istioinaction"
2019-07-01T18:55:04.324037Z	info	FLAG: --serviceregistry="Kubernetes"
2019-07-01T18:55:04.324040Z	info	FLAG: --statsdUdpAddress=""
2019-07-01T18:55:04.324042Z	info	FLAG: --statusPort="15020"
2019-07-01T18:55:04.324044Z	info	FLAG: --templateFile=""
2019-07-01T18:55:04.324045Z	info	FLAG: --trust-domain=""
2019-07-01T18:55:04.324047Z	info	FLAG: --zipkinAddress="zipkin.istio-system:9411"
2019-07-01T18:55:04.324064Z	info	Version root@e1b1b59e-920e-11e9-9590-0a580a2c0406-docker.io/istio-1.2.0-f8295503296ec6bae1b1047cc1491469d5e72754-Clean
2019-07-01T18:55:04.324190Z	info	Obtained private IP [172.17.0.17]
2019-07-01T18:55:04.324215Z	info	Proxy role: &model.Proxy{ClusterID:"", Type:"sidecar", IPAddresses:[]string{"172.17.0.17", "172.17.0.17"}, ID:"catalog-7546f55f8c-59th2.istioinaction", Locality:(*core.Locality)(nil), DNSDomain:"istioinaction.svc.cluster.local", TrustDomain:"cluster.local", PilotIdentity:"", MixerIdentity:"", ConfigNamespace:"", Metadata:map[string]string{}, SidecarScope:(*model.SidecarScope)(nil), ServiceInstances:[]*model.ServiceInstance(nil), WorkloadLabels:model.LabelsCollection(nil)}
2019-07-01T18:55:04.324242Z	info	PilotSAN []string(nil)
2019-07-01T18:55:04.324474Z	info	Effective config: binaryPath: /usr/local/bin/envoy
concurrency: 2
configPath: /etc/istio/proxy
connectTimeout: 10s
discoveryAddress: istio-pilot.istio-system:15010
drainDuration: 45s
parentShutdownDuration: 60s
proxyAdminPort: 15000
serviceCluster: catalog.istioinaction
statNameLength: 189
tracing:
  zipkin:
    address: zipkin.istio-system:9411

2019-07-01T18:55:04.324481Z	info	Monitored certs: []string{"/etc/certs/cert-chain.pem", "/etc/certs/key.pem", "/etc/certs/root-cert.pem"}
2019-07-01T18:55:04.324511Z	info	PilotSAN []string(nil)
2019-07-01T18:55:04.324555Z	info	Starting proxy agent
2019-07-01T18:55:04.324622Z	info	Opening status port 15020

2019-07-01T18:55:04.324857Z	info	watching /etc/certs for changes
2019-07-01T18:55:04.324865Z	info	Received new config, resetting budget
2019-07-01T18:55:04.324868Z	info	Reconciling retry (budget 10)
2019-07-01T18:55:04.324949Z	info	Epoch 0 starting
2019-07-01T18:55:04.371264Z	info	Envoy command: [-c /etc/istio/proxy/envoy-rev0.json --restart-epoch 0 --drain-time-s 45 --parent-shutdown-time-s 60 --service-cluster catalog.istioinaction --service-node sidecar~172.17.0.17~catalog-7546f55f8c-59th2.istioinaction~istioinaction.svc.cluster.local --max-obj-name-len 189 --local-address-ip-version v4 --allow-unknown-fields -l warning --component-log-level misc:error --concurrency 2]
[2019-07-01 18:55:04.391][17][warning][config] [bazel-out/k8-opt/bin/external/envoy/source/common/config/_virtual_includes/grpc_stream_lib/common/config/grpc_stream.h:86] gRPC config stream closed: 14, no healthy upstream
[2019-07-01 18:55:04.391][17][warning][config] [bazel-out/k8-opt/bin/external/envoy/source/common/config/_virtual_includes/grpc_stream_lib/common/config/grpc_stream.h:49] Unable to establish new stream
[2019-07-01 18:55:05.848][17][warning][filter] [src/envoy/http/authn/http_filter_factory.cc:102] mTLS PERMISSIVE mode is used, connection can be either plaintext or TLS, and client cert can be omitted. Please consider to upgrade to mTLS STRICT mode for more secure configuration that only allows TLS connection with client cert. See https://istio.io/docs/tasks/security/mtls-migration/
[2019-07-01 18:55:05.850][17][warning][filter] [src/envoy/http/authn/http_filter_factory.cc:102] mTLS PERMISSIVE mode is used, connection can be either plaintext or TLS, and client cert can be omitted. Please consider to upgrade to mTLS STRICT mode for more secure configuration that only allows TLS connection with client cert. See https://istio.io/docs/tasks/security/mtls-migration/
2019-07-01T18:55:05.893029Z	info	Envoy proxy is ready
[2019-07-01T18:55:18.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 7 - "-" "kube-probe/1.15" "5756bbc2-b7c9-9bbe-ab56-bcc5d2b17af7" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52280 -
[2019-07-01T18:55:28.903Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 9 - "-" "kube-probe/1.15" "9a976dfd-4f69-9f64-88b2-30470f33d2af" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52396 -
[2019-07-01T18:55:38.479Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "f328c63c-7426-9667-9b7c-8329ae541372" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52516 -
[2019-07-01T18:55:48.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "2c6446d6-6bb0-925c-8080-2bf820bc1bf6" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52624 -
[2019-07-01T18:55:58.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "6f9c808a-9653-9e35-ae62-4c12d03ebd9f" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52736 -
[2019-07-01T18:56:08.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 1 - "-" "kube-probe/1.15" "8fb6c7b7-6167-9138-8619-5bbf6247adb8" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52844 -
[2019-07-01T18:56:18.590Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 8 - "-" "kube-probe/1.15" "e1fb96e5-5ad8-90eb-8702-5599c9db30c6" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:52954 -
[2019-07-01T18:56:28.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "cd488ed3-fbea-987c-9c0d-507ba49f6023" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53064 -
[2019-07-01T18:56:38.479Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 1 - "-" "kube-probe/1.15" "238459a6-1412-9b1e-a85f-c2f598c33017" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53180 -
[2019-07-01T18:56:48.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "e40375ec-d5b6-98ba-9623-8d22907c37f9" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53288 -
[2019-07-01T18:56:58.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "e1bfe862-b914-9c59-a202-a67e826e2bc4" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53398 -
[2019-07-01T18:57:08.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "8b84ab07-cc51-91a4-92d8-87622febbd83" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53506 -
[2019-07-01T18:57:18.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "be3824b6-e114-9518-ab99-f8bbdc61a90c" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53614 -
[2019-07-01T18:57:28.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "174c6d47-22b8-9921-9d30-221aa96f4a13" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53728 -
[2019-07-01T18:57:38.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 4 - "-" "kube-probe/1.15" "b12d5054-f257-987d-88be-6383803fea66" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53842 -
[2019-07-01T18:57:48.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "9b5e0ad4-7959-9887-8cce-588c046935a0" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:53950 -
[2019-07-01T18:57:58.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "72a2c02f-2e8e-9c12-bd43-8caddc287d68" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54060 -
[2019-07-01T18:58:08.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 34 - "-" "kube-probe/1.15" "f3207917-bf5b-941d-a37b-90229e0de5e6" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54168 -
[2019-07-01T18:58:10.826Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "6551817c-4d09-911b-b0ad-4711b9ca2c51" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54196 -
[2019-07-01T18:58:18.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "fbee1157-d358-9dba-a628-0c405daa0407" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54280 -
[2019-07-01T18:58:20.827Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "32490ac5-f04f-93da-82b5-97ac4e66b6b5" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54310 -
[2019-07-01T18:58:28.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "41bacfa4-97f0-9df5-a237-1edff8eaf1d6" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54394 -
[2019-07-01T18:58:30.828Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "83ab61d1-28ae-9147-93e9-aa9a40d0a979" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54430 -
[2019-07-01T18:58:38.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "deeefada-0c71-951e-ad45-ca5671f27c06" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54514 -
[2019-07-01T18:58:48.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "3307c029-4c16-96a4-bdaf-1e7c394cf175" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54622 -
[2019-07-01T18:58:58.479Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 1 - "-" "kube-probe/1.15" "5128d1a2-b3d3-9f35-8403-dc4f9153c4bc" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54732 -
[2019-07-01T18:59:18.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "34868db0-04c2-9974-8f32-c81ff9ddc9d0" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:54944 -
[2019-07-01T18:59:28.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 0 - "-" "kube-probe/1.15" "d150f243-ef62-958a-807c-bd460262abb6" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:55054 -
[2019-07-01T18:59:38.481Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 2 - "-" "kube-probe/1.15" "86a23b34-6a18-9ad2-ad4a-6324253e846f" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:55172 -
[2019-07-01T18:59:48.480Z] "GET /health HTTP/1.1" 503 UF "-" "-" 0 91 2 - "-" "kube-probe/1.15" "b5f4bdb5-4b35-927c-ac88-37509af78307" "172.17.0.17:8080" "127.0.0.1:8080" inbound|8080|http|catalog.istioinaction.svc.cluster.local - 172.17.0.17:8080 172.17.0.1:55282 -