Gravitational field on surface of spherical shell

The above-mentioned shell theorem explains how to calculate the gravitational field inside and outside the shell.

It's not really correct to ask what is the field exactly on the surface of the shell. Because the function $g(r)$ is not continuous at $r = R$.

But it is correct to ask what gravitational force is acting on each part of the shell from the rest of it. If the force acting on a small part of the shell is $g * dm$, then it's natural to say that the gravitational field on the surface is $g$.

So, you take a small part of the shell $dm$ and want to find the gravitational force acting on this part of the shell. Your approach is correct, the force is $ G M dm / 2 R^2$.

I can suggest another approach that gives same result.

Let's calculate the potential energy of the shell. Let's take a very small part of it and pull it out to infinity. We have spend some energy to do it: $G M dm/R$. Then we take another part of the shell, and so on. But we will take the small parts from different sides of the shell, so that the remaining mass still forms a spherical shell. It would be just thinner and thinner until is dissolves to nothing.

The energy we have to spend depends on the remaining mass. $dA(m) = G m dm /R$. This is a linear function and is easy to integrate. Total energy we spent would be $A = G M^2/2R$. And the total gravitation energy of the shell is $W=-GM^2/2R$.

Now let's inflate the sphere by $x$. It's energy would increase by: $$x * dW/dR = x * G M^2/2R^2$$

We can also calculate the energy we spent pulling each piece of the shell up by $x$. The force acting on each small piece $dm$ is proportional to $dm$: $f = g*dm$. So, the total work is $$\sum_{dm} x * g * dm = x*g*M$$

Now compare the work done and increase of energy: $$x * GM^2 / 2R^2 = x * g *M$$ $$g = GM/2R^2$$