I keep getting this error when I run my application in a Docker container in a pod on Kubernetes. These are some important snippets of the files.
class RedditServiceSpinnakerNotifications(object):
def is_healthy(self, request):
return {'status': 200}
controller = RedditServiceSpinnakerNotifications()
configurator.add_route('health', '/health', request_method='GET')
configurator.add_view(controller.is_healthy, route_name="health",
renderer="json")
EXPOSE 8080
WORKDIR /src
VOLUME /src
COPY . /src
CMD python3 setup.py develop && python3 setup.py build && baseplate-serve3 --debug --bind 0.0.0.0:8080 --reload example.ini
livenessProbe:
httpGet:
path: {{ .Values.app.healthcheck.endpoint }}
port: {{ .Values.service.internalPort }}
initialDelaySeconds: {{ .Values.app.healthcheck.initialDelaySeconds }}
timeoutSeconds: 10
app:
healthcheck:
endpoint: /health
type: http
port: 8080
initialDelaySeconds: 10
service:
type: ClusterIP
externalPort: 80
internalPort: 8080
Liveness probe failed: Get http://192.168.9.69:8080/health: read tcp 10.9.44.118:44171->192.168.9.69:8080: read: connection reset by peer
The pod is in a crash loop backoff state, you I cannot exec into it.