# The healthy application serving old configuration

The web Pod is Ready and its Service responds, but the response is an old
release channel. The ConfigMap already contains the desired value. Trace the
configuration to the running application and restore the expected response
without changing the application, the Deployment's configuration reference,
or the desired ConfigMap.

## Before you begin

Use a disposable machine with Bash, Python 3, Docker, kind and kubectl. Docker
may download the kind node and workload images. The lab creates the single-node
cluster `breakfix-apps-04`, a separate kubeconfig and an ownership record under
`~/.kube`. It does not change your default kubeconfig or create cloud
resources. Do not reuse the lab cluster name; setup refuses existing lab files
or nodes and teardown checks the recorded node identity.

## Investigate

```sh
./setup.sh
kubectl --kubeconfig "$HOME/.kube/breakfix-apps-04" -n breakfix-apps-04 get deployment,pods,service,configmap
kubectl --kubeconfig "$HOME/.kube/breakfix-apps-04" -n breakfix-apps-04 describe deployment channel-web
kubectl --kubeconfig "$HOME/.kube/breakfix-apps-04" -n breakfix-apps-04 get configmap app-settings -o yaml
kubectl --kubeconfig "$HOME/.kube/breakfix-apps-04" -n breakfix-apps-04 exec deploy/channel-web -- wget -qO- http://channel-web/
```

The values in this exercise are synthetic and not secrets. Do not print real
Secret values when diagnosing production systems. Keep `settings.yaml` as
the desired source of configuration; refreshing the workload in this
disposable cluster is an operational action, not a substitute for reviewing
changes in a production GitOps workflow.

After repair, run `./verify.sh` and `./teardown.sh`. Verification checks the
desired ConfigMap, the original workload and Service, the ready endpoint, the
running container's configuration and an HTTP response through the Service.
Teardown deletes the cluster only when its node matches the ownership record.

The [related Kubernetes inspection guide and demonstration](https://opsbreakfix.com/devops/inspect-kubernetes-pods-deployments-and-services/#see-it-run)
cover inspecting Deployments, Services and configuration references; the demo
does not depict this stale-environment scenario.
