{...}: { services.dockerRegistry = { enable = true; enableGarbageCollect = true; extraConfig = { proxy.remoteurl = "https://registry-1.docker.io"; }; }; services.nginx = { upstreams.docker-hub-registry.servers."localhost:5000" = { }; virtualHosts."docker-hub.pleshevski.ru" = { enableACME = true; forceSSL = true; locations."/v2/".proxyPass = "http://docker-hub-registry"; }; }; }