Consider $D_{n}$, Dihedral group of order $2n$.
It has the following presentation, $$D_{n}=\;\langle a,b\;|a^{n},\;b^{2},\; b^{-1}ab=a^{-1}\rangle$$
Now consider the cyclic group generated by $b$ and denote it by $C_{2}$, consider the cyclic group generated by $a$ and denote it by $C_{n}$.
It is easy to see that these two generate whole of $D_{n}$
Next observe that $C_{n}$ is normal in $D_{n}$ and $C_{2}\cap C_{n}=\{e\}$.
Above arguments shows that $D_{n}$ is the semi direct product of $C_{2}$ and $C_{n}$
Now coming to the point, Can we define a non trivial action of $C_{2}$ on $C_{n}$.
Often a semi-direct product $N \rtimes_{\varphi} H$ is given in terms of a homomorphism:
$\varphi: H \to \text{Aut}(N)$
In this case, $N = C_n = \langle a\rangle$, and $H = C_2 = \langle b\rangle$.
The (non-trivial) homomorphism $\varphi$ is defined thus:
$\varphi(b) = f$, where $f(a) = a^{-1}$ ($f$ is a homomorphism $C_n \to C_n$ since $C_n$ is abelian, and is clearly bijective, thus an automorphism). It is clear that $f(a^k) = (a^k)^{-1} = (a^{-1})^k$, for all integers $k$.
Since $\varphi \circ \varphi = \text{id}_{C_n}$, it should be clear this is a non-trivial homomorphism of $C_2$ into $\text{Aut}(C_n)$ (it's actually a monomorphism, but that's not that relevant, here).
Note that we can define an action of $C_2$ on $C_n$ by:
$b\cdot a = [\varphi(b)](a) = f(a) = a^{-1}$, and that this is the same action as:
$b\cdot a = a^b = b^{-1}ab = a^{-1}$.