Lemma 4.20.3 (Urysohn’s Lemma (LCH), [Lemma 4.32, Fol99]). Let $X$ be a LCH space, $K \subset X$ be compact, and $U \in \cn(K)$, then there exists $f \in C_{c}(X; [0, 1])$ such that $\supp{f}\subset U$.
Proof. By Lemma 4.20.2, there exists $V, W \in \cn^{o}(K)$ precompact such that
\[K \subset V \subset \ol{V}\subset W \subset \ol{W}\subset U\]
As $\ol{W}$ is compact, it is normal by Proposition 4.16.4. Since $X$ is Hausdorff, $K \subset \ol{W}$ is closed by Proposition 4.16.3.
By Urysohn’s lemma, there exists $f \in C(\ol{V}; [0, 1])$ such that $f|_{K} = 1$ and $f|_{\ol{W} \setminus V}= 0$. Let
\[F: X \to [0, 1] \quad x \mapsto \begin{cases}f(x) &x \in W \\
0 &x \in X \setminus \ol{V}\end{cases}\]
then by the gluing lemma for continuous functions, $F \in C_{c}(X; [0, 1])$ with $F|_{K}= 1$ and $\supp{f}\subset U$.$\square$