Cache location for gradle plugins?

I’m trying to build on a remote machine that doesn’t have access to an internal artifactory server.
We have a custom plugin that is on that artifactory server.

I rsync’d my ~/.gradle folder and the entire project directory, but when doing an offline build on that machine, it can’t find that gradle plugin.
If I build locally with wifi turned off with gradle --offline, it works fine. So it seems like there’s something I didn’t copy over.