question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

find a bug about readiness_probe port type error

See original GitHub issue

error:

Reason: Unprocessable Entity
HTTP response headers: HTTPHeaderDict({'Date': 'Fri, 16 Jun 2017 04:24:27 GMT', 'Content-Length': '799', 'Content-Type': 'application/json'})
HTTP response body: {"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"ReplicationController \"657c4cf604e335548521b060887f3cd6\" is invalid: spec.template.spec.containers[0].readinessProbe.httpGet.port: Invalid value: \"80\": must contain at least one letter or number (a-z, 0-9)","reason":"Invalid","details":{"name":"657c4cf604e335548521b060887f3cd6","kind":"ReplicationController","causes":[{"reason":"FieldValueInvalid","message":"Invalid value: \"80\": must contain at least one letter or number (a-z, 0-9)","field":"spec.template.spec.containers[0].readinessProbe.httpGet.port"},{"reason":"FieldValueInvalid","message":"Invalid value: \"80\": must contain at least one letter or number (a-z, 0-9)","field":"spec.template.spec.containers[0].readinessProbe.httpGet.port"}]},"code":422}

code:

rc = client.get_rc(tenant_id, rc_id)
rc.spec.replicas = cur_replicas
client.put_rc(tenant_id, rc_id, rc)

bug reason:

'readiness_probe': {'_exec': None,
                                                                    'failure_threshold': 3,
                                                                    'http_get': {'host': None,
                                                                                 'http_headers': None,
                                                                                 'path': '/wp-admin/install.php',
                                                                                 'port': '80',
                                                                                 'scheme': 'HTTP'},
                                                                    'initial_delay_seconds': 1,
                                                                    'period_seconds': 3,
                                                                    'success_threshold': 1,
                                                                    'tcp_socket': None,
                                                                    'timeout_seconds': 20},

Is printed above the get rc entities, including readiness_probe port field from json python entity type is not correct.[0-9] should be converted to type int, [a-z] should be converted to character.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
barnettZQGcommented, Jun 20, 2017

@mbohlool I know change to '80' to 80, but get the port from ‘get rc’ method show port is ‘port’.

0reactions
barnettZQGcommented, Jun 21, 2017

@mbohlool yeah,thank you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Configure Liveness, Readiness and Startup Probes
Another kind of liveness probe uses an HTTP GET request. ... to the server that is running in the container and listening on...
Read more >
Troubleshooting RTF error Readiness probe failed: 409
An application deployed to a Runtime Fabric cluster fails to deploy with the message "Readiness probe failed: 409: <html> <head> <meta http-equiv="Content-Type" ...
Read more >
Kubernetes Readiness Probes | Practical Guide - Komodor
What is a Readiness Probe. Distributed systems are complex. They have many moving parts, and when one part experiences a problem, other parts...
Read more >
Readiness Probe fails but Port-forward to service works [closed]
question is, why pods are serving traffic when readiness probe is failing. PS: I have created cluster on my machine using Kind. kubernetes ......
Read more >
How to use kubernetes probes-part 14 - YouTube
Kubernetes Probes- livenessProbe, readinessProbe, startupProbe |How to use kubernetes ... In this lab session, we are going to see - 1.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found