Distribution of gluons in the nucleus at small x and moderate $Q2$ is studied using the relation with diffraction on nucleons wich arises from Gribov-Regge field theory. We use the recent H1 data on the distribution of gluons in the Pomeron to parametrize and calculate the shadowing in nuclear structure functions. The shadowing due to the gluonic distribution is compared to that of quarks, and is found to be stronger at small x. Comparison to higher-twist approximation is also done showing deviations at $x \leq 10^{-3}$. Consequences regarding particle multiplicities are discussed for p+A and heavy ion collisions at RHIC and, especially, at LHC, where the differences between the model predictions are significant and can be disentagled experimentally. Gluon shadowing at forward rapidities is calculated and compared to experimental data on the nuclear modification factor at RHIC.