Compactness is independent of the metric chosen _among those that define the same topology_ (commonly termed _equivalent metrics_ ).
For instance, the closed interval $[0,1]$ is compact in the topology induced by the usual metric and all equivalent metrics. It is _not_ compact under the _discrete metric_ $\delta(x,y)=1$ if $x\
e y$ and $\delta(x,x)=0$: this metric induces a different topology, namely the discrete topology.
Any set endowed with the indiscrete topology is compact (for lack of infinite open covers), so this says nothing about compactness under different topologies.