"Your" notations are a bit confusing, but let us keep them, just adding $m'=m/p^{e_p}$, so that $p \nmid m'$. Then known classical results on cyclotomic extensions assert that $\mathbf Q_p (\zeta_m)/\mathbf Q_p$ is the compositum of the two linearly disjoint extensions $\mathbf Q_p (\zeta_{m'})$ and $\mathbf Q_p (\zeta_{p^{e_p}})$. In the same way,
$L_\mathfrak q=K_\mathfrak p(\zeta_m)$ is the compositum of $\mathbf Q_p (\zeta_{p^{e_p}})$ and $\mathbf Q_p (\zeta_{m''})$ (containing $\mathbf Q_p (\zeta_{m'})$), with $p\nmid m''$. Concerning ramification, the branch $\mathbf Q_p (\zeta_{p^{e_p}})/\mathbf Q_p$ is totally ramified, whereas the branches $\mathbf Q_p (\zeta_{m''})/\mathbf Q_p$ and $L_\mathfrak q/\mathbf Q_p (\zeta_{p^{e_p}})$ are unramified, so that $Gal(L_\mathfrak q /\mathbf Q_p (\zeta_{m''}))\cong Gal(\mathbf Q_p (\zeta_m)/\mathbf Q_p (\zeta_{m'}))\cong Gal(\mathbf Q_p (\zeta_{p^{e_p}})/\mathbf Q_p)$ and the corresponding extensions are totally ramified.
By the above, the inertia subfield $F$ (bad notation, there should be an index indicating that this is a local field) coincides with $\mathbf Q_p (\zeta_{m''})$, and $L_\mathfrak q=F(\zeta_m)=F(\zeta_{p^{e_p}})$ . NB: things get clearer with a Galois diagram.
Now I have nearly clearing everything up. Let me write them as an answer.
Problem: Let $K$ be a number field and $p$ be prime number. Let $M$ be the maximal abelian pro-$p$ extension of $K$ unramified outside $p$. Describe $\mathrm{Gal}(M|K)$ and calculate its $\mathbb{Z}_p$-rank.
For any modulus $\mathfrak{m}$, we have the exact sequence (given in this post)
$$
0 \to (\mathcal O_K/\mathfrak m)^{\times}/\mathcal O_K^{\times} \xrightarrow{\alpha} \mathrm{Cl}_{\mathfrak m} \to \mathrm{Cl}_K \to 0 \quad\quad (\dagger).
$$
Here the map $\alpha$ can be regarded as the composition
$$
\mathcal O_K^{\times} \xrightarrow{\alpha^{\flat}} (\mathcal O_K/\mathfrak m)^{\times} \rightarrow (\mathcal O_K/\mathfrak m)^{\times} / \mathrm{image}(\alpha^{\flat}).
$$
Now consider the modulus $\mathfrak{m}_n := p^n$ in $K$ for each integer $n$. Let $H_{p,n}$ be the class field of $\mathfrak{m}_n$ over $K$. Then $\mathrm{Cl}_{\mathfrak{m}_n} \cong \mathrm{Gal}(H_{p,n} | K)$ and every places outside the ones lying above $p$ in $K$ is unramified in $H_{p,n}$. Hence $(\dagger)$ becomes
$$
0 \to (\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times} \to \mathrm{Gal}(H_{p,n} | K) \to \mathrm{Cl}_K \to 0
$$
Then we take the $p$-primary part of each object in the exact sequence and get
$$
0 \to ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}] \to \mathrm{Gal}(H_{p,n}| K)[p^{\infty}] \to \mathrm{Cl}_K[p^{\infty}] \to 0 \quad\quad (\star)
$$
Here firstly, the functor $[p^{\infty}]$ is left exact since it is the right adjoint of the inclusion functor from the category of $p$-primary abelian groups to the category of abelian groups. Then shrinking the category of abelian groups to torsion abelian groups, we see that it is right exact as well. (This follows from the first comment by @Mindlack, or by the observation that in the category of torsion abelian groups, $-[p^{\infty}] = -\otimes_{\mathbb{Z}} \mathbb{Z}_p$, the latter one is right exact. See this post.)
Then we take the inverse limit in the exact sequence $(\star)$ and get
$$
0 \to \lim ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}] \to \lim (\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]) \to \lim \mathrm{Cl}_K[p^{\infty}] \to 0 \quad\quad (\star\star).
$$
Indeed, the functor $\lim$ is left exact. Moreover, since the leftmost term in $(\star)$ is finite (being included in $\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]$) , it satisfies the Mittag-Leffler condition. Hence $\lim$ is right exact here as well.
And note that $\lim \mathrm{Cl}_K[p^{\infty}] = \mathrm{Cl}_K[p^{\infty}]$, once we write explicity the inverse system out. Hence
$$
0 \to \lim ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}] \to \lim (\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]) \to \mathrm{Cl}_K[p^{\infty}] \to 0 \quad\quad (\star\star).
$$
So it remains to deal with the remaining two terms.
- For the $\lim (\mathrm{Gal}(H_{p,n}| K)[p^{\infty}])$, we break it step by step:
Dealing with $\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]$. Note that $G_n := \mathrm{Gal}(H_{p,n}| K)$ is a finite abelian groups, we can decompose it as
$$
G_n \cong G_n[p^{\infty}] \cup_{\ell \neq p} G_n[\ell^{\infty}],
$$
where in this case, $G_n[p^{\infty}]$ is the $p$-Sylow subgroup of $G_n$. Consider the subextension $M_{p,n}$ of $H_{p,n}$ fixed by $\cup_{\ell \neq p} G_n[\ell^{\infty}]$. Then $M_{p,n} | K$ has Galois group isomorphic to $G_n[p^{\infty}]$. This is then the maximal $p$-subextension of $H_{p,n}$. Then all places in $K$ outside the ones lying over $p$ in $K$ are unramified in $M_{p,n}$ as they are in $H_{p,n}$. In this way, we have obtained a maximal $p$-subectension $M_{p,n}$ of $H_{p,n}$ such that every place outside $p$ is unramified, and its Galois group $\mathrm{Gal}(M_{p,n}|K) = \mathrm{Gal}(H_{p,n}| K)[p^{\infty}]$.
Now we take the limit of $\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]$ with respect to $n$, by Galois theory, we obtain that
$$
\lim (\mathrm{Gal}(H_{p,n}| K)[p^{\infty}]) = \lim \mathrm{Gal}(M_{p,n}|K) = \mathrm{Gal}(M|K).
$$
Therefore, the middle term in $(\star\star)$ is merely $\mathrm{Gal}(M|K)$.
- For the limit $\lim ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}]$, I turn to the following exact sequence first
$$
\mathcal O_K^{\times} \to (\mathcal O_K/(p^n \mathcal{O}_K))^{\times} \to (\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times} \to 1.
$$
Here we have invoked the convention in the shaded part in this answer. So the sequence may not be left exact.
Then tensoring this with $\mathbb{Z}_p$ over $\mathbb{Z}$ we get
$$
\mathcal O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p \to (\mathcal O_K/(p^n \mathcal{O}_K))^{\times}\otimes_{\mathbb{Z}} \mathbb{Z}_p \to ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})\otimes_{\mathbb{Z}} \mathbb{Z}_p \to 1.
$$
Since it is a right exact functor. Again by this post, we see that for torsion groups $M$, $M[p^{\infty}] = M \otimes_{\mathbb{Z}} \mathbb{Z}_p$. So the right two terms can be modified (while $O_K^{\times}$ may not be a torsion group by Dirichlet's unit theorem, it will remain unchanged) as
$$
\mathcal O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p \to (\mathcal O_K/(p^n \mathcal{O}_K))^{\times}[p^{\infty}]\to ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}] \to 1.
$$
And taking inverse limit, we get
$$
\mathcal O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p \to \lim(\mathcal O_K/(p^n \mathcal{O}_K))^{\times}[p^{\infty}] \to \lim ((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}/\mathcal O_K^{\times})[p^{\infty}] \to 1. \quad\quad (\star\star\star)
$$
Again we note that the leftmost term $O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p$ satisfies the Mittag-Leffler condition, since it is finite (as the right two terms are). Hence here taking inverse limit preserves right exactness.
So to describe the third term, we shall compute the second term in $(\star\star\star)$. We claim that
$$\lim((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}[p^{\infty}]) = \prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1}, $$
where $U_{\mathfrak p}^{1}$ is the subgroup of $\mathcal{O}_{K, \mathfrak p}^{\times}$ consisting of elements congruent to $1$ modulo $p$.
Proof of the claim: we compute
\begin{align*}
\lim((\mathcal O_K/(p^n \mathcal{O}_K))^{\times}[p^{\infty}])
&= \lim\left( \prod_{\mathfrak{p} | p} \left((\mathcal O_K/(\mathfrak{p}^{e_{\mathfrak{p}}n}))^{\times}[p^{\infty}] \right) \right) \\
&= \prod_{\mathfrak{p} | p} \lim\left((O_K/(\mathfrak{p}^{e_{\mathfrak{p}}n}))^{\times}[p^{\infty}]\right) \\
&= \prod_{\mathfrak{p} | p} \lim((O_K/(\mathfrak{p}^{e_{\mathfrak{p}}n}))^{\times}) [p^{\infty}] \\
&= \prod_{\mathfrak{p} | p} (\lim (O_K/(\mathfrak{p}^{e_{\mathfrak{p}}n})))^{\times} [p^{\infty}] \\
&= \prod_{\mathfrak{p} | p} (\mathcal{O}_{K,\mathfrak{p}})^{\times} [p^{\infty}] \\
&= \prod_{\mathfrak{p} | p} (1+ \varpi_{\mathfrak{p}} \mathcal{O}_{K,\mathfrak{p}})) \\
&= \prod_{\mathfrak{p} | p} U_{\mathfrak{p}}^{1}.
\end{align*}
Here:
- 1st equality: Use the multiplicative version Chinese remainder theorem and interchange $\prod$ and $[p^{\infty}]$,
- 2nd equality: Interchange $\lim$ and $\prod$,
- 3rd equality: Interchange $\lim$ and $[p^{\infty}]$. Since $[p^{\infty}]$ is right adjoint, this can be done (note that the resulting $\lim$ does not escape from the category of $p$-primary abelian groups),
- 4th equality: Interchange $\lim$ and $(-)^{\times}$. Note that the functor $(-)^{\times}$ from the category of commutative rings to abelian groups is right adjoint to the functor taking any abelian group $A$ to its group ring $\mathbb{Z}[A]$. So it indeed preserves $\lim$,
- 5th equality: From the definition of completion. Note that the ramification index $e_{\mathfrak{p}} := e(\mathfrak{p} | p)$ will not affect the result.
The rest two equalities follow from definitions. So the claim is proved.
So to sum up, we obtain
$$
1 \rightarrow \prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1} / (O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p) \rightarrow \mathrm{Gal}(M|K) \rightarrow \mathrm{Cl}_K[p^{\infty}] \rightarrow 1.
$$
and
$$
O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p \rightarrow \prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1} \rightarrow \mathrm{Gal}(M|K) \rightarrow \mathrm{Cl}_K[p^{\infty}] \rightarrow 1.
$$
There are no major distinction among the two. The first one is neater and the second one is helpful when calculating $\mathbb{Z}_p$-rank and concrete examples.
Calculating $\mathbb{Z}_p$-ranks: It suffices to wandering around the second exact sequence above. Let $r_p$ be the $\mathbb{Z}_p$-rank of the image of $O_K^{\times} \otimes_{\mathbb{Z}} \mathbb{Z}_p$ in $\prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1}$. Then
$$
\mathrm{rank}_{\mathbb{Z}_p}(\mathrm{Gal}(M|K)) = \mathrm{rank}_{\mathbb{Z}_p}(\prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1}) - r_p + \mathrm{rank}_{\mathbb{Z}_p}(\mathrm{Cl}_K[p^{\infty}]).
$$
Now, $\mathrm{rank}_{\mathbb{Z}_p}(\mathrm{Cl}_K[p^{\infty}])=0$ since
$$
\mathrm{Cl}_K[p^{\infty}] \otimes_{\mathbb{Z}_p} \mathbb{Q}_p = 0.
$$
Moreover,
\begin{align*}
\left(\prod_{\mathfrak p \mid p} U_{\mathfrak p}^{1}\right) \otimes_{\mathbb{Z}_p} \mathbb{Q}_p
&= \prod_{\mathfrak p \mid p} \left( (1+ \varpi_{\mathfrak{p}} \mathcal{O}_{K,\mathfrak{p}}) \otimes_{\mathbb{Z}_p} \mathbb{Q}_p \right) \\
&\cong \prod_{\mathfrak p \mid p} \left( \mathcal{O}_{K,\mathfrak{p}} \otimes_{\mathbb{Z}_p} \mathbb{Q}_p \right) \\
&\cong \prod_{\mathfrak p \mid p} \left( \mathbb{Z}_p^{e_{\mathfrak{p}}f_{\mathfrak{p}}} \otimes_{\mathbb{Z}_p} \mathbb{Q}_p \right) \\
&=\mathbb{Q}_p^{\sum_{\mathfrak p \mid p}e_{\mathfrak{p}}f_{\mathfrak{p}}} \\
&=\mathbb{Q}_p^{[K:\mathbb{Q}]}.
\end{align*}
Here in the first line, we interchanged $\prod$ and ${-}_{\mathbb{Z}_p} \mathbb{Q}_p$. In the last line, we used the fundamental equality $\sum_{\mathfrak p \mid p}e_{\mathfrak{p}}f_{\mathfrak{p}} = [K:\mathbb{Q}]$. Hence, to sum up,
$$
\mathrm{rank}_{\mathbb{Z}_p}(\mathrm{Gal}(M|K)) = [K:\mathbb{Q}] - r_p,
$$
as desired!
Best Answer
The idea isn’t too far off, but you need to note that $[-]$ is far from being surjective, so it won’t map norm groups to norm groups… I really hope I got this right.
Clearly, if $L/K$ is finite abelian, any completion of $L$ at a place above $\mathfrak{p}$ is abelian over $K_{\mathfrak{p}}$. So what remains to be proved is that, for any finite abelian $L/K_{\mathfrak{p}}$, there exists an abelian extension $E/K$ such that $L \subset EK_{\mathfrak{p}}$.
Passing to norm subgroups, and using (5.8), what needs to be shown is that for every norm subgroup $N \leq K_{\mathfrak{p}}^{\times}$ (corresponding to $L$) there exists a finite index open subgroup $N’ \leq C_K$ such that $[-]^{-1}(N’) \subset N$. In other words, we have to show that there exists a finite index open subgroup $K^{\times} \leq N’ \leq \mathbb{A}_K^{\times}$ such that $[-]^{-1}(N’) \subset N$.
Assume $N \supset N_1 \cap N_2$ where we know the solution for $N_1$ and $N_2$ – ie we know satisfactory $N’_1$ and $N’_2$. Then $N’=N’_1 \cap N’_2$ clearly works for $N$.
Let $\pi \in K$ be such that $(\pi)$ is a nontrivial power of $\mathfrak{p}$. We know that $N$ contains $\{u\pi^n,\, u \in 1+\mathfrak{p}^{\alpha}, \beta|n\}$ for $\alpha >0$, $\beta >0$. Let $N_1=\pi^{\mathbb{Z}}(1+\mathfrak{p}^{\alpha})$, $N_2=\mathcal{O}_{K_{\mathfrak{p}}}^{\times}\pi^{\beta \mathbb{Z}}$. Then $N \supset N_1 \cap N_2$.
$N_2$ is the norm group of the non-ramified extension $K_{\mathfrak{p}}(\mu_{q^{\nu\beta}-1})$ (where $\pi$ has valuation $\nu$, the order of $\mathfrak{p}$ in the class group and $q$ is the cardinal of the residue field at $\mathfrak{p}$) which clearly comes from a global extension (with the associated $N’_2$). So it’s enough to solve the case $N=N_1$.
In other words, we want to construct a finite index open subgroup $N’$ of $\mathbb{A}_K^{\times}$ containing $K^{\times}$ such that its only elements with support in $K_{\mathfrak{p}}$ are in $\pi^{\mathbb{Z}}(1+\mathfrak{p}^{\alpha})$.
Let $S$ be a finite set of finite places of $K$ containing $\mathfrak{p}$, $S’$ the other finite places, $S_{\infty}$ the infinite places. We will take $N’=K^{\times}F$, where $F=\prod_{v \in S_{\infty}}{K_v^{\times}} \prod_{v \in S’}{\mathcal{O}_{K_v}^{\times}}\prod_{v \in S}{H_v}$ where $H_v \subset \mathcal{O}_{K_v}^{\times}$, which is an open subgroup (then $N’$ is open and finite index essentially because the $\mathcal{O}_v^{\times}$ are compact and the class group is finite).
To show the statement, we need to see that $H_{\mathfrak{p}} \subset (1+\mathfrak{p}^{\alpha})$ and if $x \in K^{\times}$ is in $H_v$ for all $v \in S_0 :=S \backslash \{\mathfrak{p}\}$, then $x \in \pi^{\mathbb{Z}}(1+\mathfrak{p})^{\alpha})$.
Now by the assumption on $\pi$, $\mathcal{O}_K^{\mathfrak{p},\times}$ (the superscript means that we require invertibility everywhere but at $\mathfrak{p}$) is the direct product $\pi^{\mathbb{Z}}\times \mathcal{O}_K^{\times}$. So we want to show that if $x\in \pi^{\mathbb{Z}}\times \mathcal{O}_K^{\times} $ satisfies a certain “non-$\mathfrak{p}$-congruence then $x \in \pi^{\mathbb{Z}}(1+\mathfrak{p}^{\alpha})$.
It is enough to show that, for some integer $f$ (the index of the right subgroup), a non-$\mathfrak{p}$ congruence condition can cut out the set $fG$ of $f$-powers in $G=\pi^{\mathbb{Z}} \times \mathcal{O}_K^{\times}$.
Now, let $P$ be the product of all the unit groups of the residual fields at finite places not $\mathfrak{p}$. By (*) below, $G \rightarrow P$ is injective with a cokernel without $f$-torsion, ie $G/fG \rightarrow P/fP$ is injective, and thus ($G$ has finite rank) there is an injection $G/fG$ to $P’/fP’$ where $P’$ is the product of finitely many multiplicative groups of residue fields at $v\neq\mathfrak{p}$ — and this concludes.
Lemma(*): Let $S$ be a cofinite set of finite places of a number field $K$ and $x \in K^{\times}, f \geq 1$. Assume that $x$ is a $f$-power in every residue field at a place of $S$ – then $x$ is a $f$-th power in $K$.
Proof: We can always assume that $S$ contains only places coprime to $f$ and $x$.
Let $L=K(e^{2i\pi/f},x^{1/f})$. Then $L/K$ is Galois. Each place $w$ of $L$ above some $v \in S$ has a well-defined Frobenius in $Gal(L/K)$ acting on the residue field at $w$, and it fixes one of the roots mod $w$ of the minimal polynomial $\mu$ of $x^{1/f}$. As $L/K$ is unramified at $w$, it means that this Frobenius (acting on the global roots of $\mu$) has a fixed point. By Cebotarev, every element of $Gal(L/K)$ fixes one of the roots of $\mu$. But $Gal(L/K)$ acts transitively on them – and by Burnside lemma it follows that $\mu$ has only a root and $L=K$.