Can one give an example of non-compact space $X$ which satisfies the following conditions:

the countable union of compact subsets is relatively compact,

for every closed noncompact subset $A$ of $X$ there is a positive lower semicontinuous function on $X$ which is bounded on every compact subset of $X$ but unbounded on $A$.

Thanks in advance for any help.