Caused by: org.gradle.internal.resource.transport.http.HttpRequestException: Could not GET 'https://maven.minecraftforge.net/org/projectlombok/lombok/1.18.30/lombok-1.18.30.jar'.
...
Caused by: java.net.SocketTimeoutException: Read timed out
The main problem is, that this repository is not answering.
It probably is down right now I guess and even dependencies that are required from it will fail.
Besides that allprojects { ... } should not be done as it is highly discouraged bad practice,
Repositories are queried in order.
So the MC repository is probably coming before the mavenCentral() you try to define and thus is not asked in time.
You can use Repository Content Filtering to control which dependencies are resolved from which repositories. But as I said, it will probably not help much as long as you need any dependencies from that repository.
You say you added this snippet.
So if you did not define that repository before at all, it is probably defined by one of the plugins you apply - which is bad practice too for public plugins.
If that is the case, you just add another repository with the same URL later, but the original repository is still queried first.
You might be able to clear() the repositories first and then add your desired ones.
Or you could instead use the “exclusive content” setup further down in the docs I linked to not say “this repo does not have X” but instead “X should only be taken from that repo”.