In General Relativity the classical solutions are spacetimes $(M,g)$ which are Lorentzian manifolds. I urge you to observe that the topology of the underlying manifold is part of the classical solution. So the unknown is not just the metric tensor!
In gauge theory things are quite similar. Given a compact and semi-simple Lie group $G$ we can construct several principal $G$-bundles over the same base manifold $M$. One of them is the trivial bundle $\pi_1:M\times G\to M$, where $\pi_1$ is the projection onto the first factor, and where the right $G$-action is $$(x,g)\cdot h=(x,gh)\tag{1}.$$
But obviously this isn't everything. We have non-trivial bundles which do not take this simple product form with this simple $G$-action (1). They are topologically different from the trivial bundle.
Now, the gauge field is in fact a connection on a principal $G$-bundle, and what is the specific $G$-bundle is part of the specification of the solution inasmuch as the spacetime topology is part of the specification of the classical GR solution!
It turns out that every principal $G$-bundle is, by definition, locally isomorphic to the trivial bundle. This correspondence is specified by choosing a local section $\sigma : U\subset M\to \pi^{-1}(U)$ and defining $h:U\times M\to \pi^{-1}(U)$ to be $h(x,g)=\sigma(x)\cdot g$. On such a locally trivial open set the connection is codified in a Lie-algebra valued one-form $A : U\to T^\ast U\otimes \mathfrak{g}$. This is the object we are used to in Yang-Mills theory.
But beware! When the principal bundle is not the trivial one then $A$ is not globally defined in the whole spacetime. In that case of non-trivial topology you cannot represent the connection by a single $A$. Rather you must cover the underlying base manifold by open sets $\{U_i\}$ over which the bundle can be trivialized. In each of the $U_i$ then you do have one $A_i$ and in order that they give a well-defined connection in the principal bundle they must obey certain compatibility conditions in the overlaps.
Now compare again to GR. The metric $g$ in each coordinate domain is specified by the components $g_{\mu\nu}$. Often a single chart won't cover the whole manifold and you'll have several in which you have the quantities $g_{\mu\nu}$, which obey compatibility conditions in the overlaps in order for them to give rise to a well-define intrinsic object $g$.
So in summary, the answer to "Does a gauge group G determine the Principal G-bundle?" is that no, there are several topologically inequivalent principal $G$-bundles over the same base manifold and this data is part of the specification of the gauge theory gauge field configuration.