Authenticated proxy doesn't work for nixos-rebuild

Hi everybody,

I tried to build NixOS Wordpress site with some plugins. On Linode VPS I got the following error:

       last 3 log lines:
       > exporting https://plugins.svn.wordpress.org/hcaptcha-for-forms-and-more/tags/4.4.0 (r3129246) into /nix/store/79dcp4xpqlzphi4bwadzr7b43xhgmvri-hcaptcha-for-forms-and-more-4.4.0-r3129246
       > svn: E170013: Unable to connect to a repository at URL 'https://plugins.svn.wordpress.org/hcaptcha-for-forms-and-more/tags/4.4.0'
       > svn: E175002: Unexpected HTTP status 429 'Too Many Requests' on '/hcaptcha-for-forms-and-more/tags/4.4.0'
       For full logs, run 'nix log /nix/store/vjbx46sfg61iwdamvcdrrz25yp2vyf4b-hcaptcha-for-forms-and-more-4.4.0-r3129246.drv'.

Which tells me that Linode VPS IPs are dropped by plugins.svn.wordpress.org.

I thought to solve it by running the nixos-rebuild via a proxy which I tried before with non-authenticated proxy on LAN and it worked.

But on public internet I need to use authenticated proxy. First I tested it and I know it works:

http_proxy=http://user:pass@1.2.3.4:1234 https_proxy=http://user:pass@1.2.3.4:1234 curl ifconfig.me

but when I export it:

export http_proxy=http://user:pass@1.2.3.4:1234 https_proxy=http://user:pass@1.2.3.4:1234

and run nixos-rebuild

I get:

       > svn: E170013: Unable to connect to a repository at URL 'https://plugins.svn.wordpress.org/hcaptcha-for-forms-and-more/tags/4.4.0'
       > svn: E670002: Could not resolve proxy server 'user:pass@1.2.3.4': Name or service not known

Which tells me that the user:pass@1.2.3.4 is considered a hostname and not a user, password and hostname.

Could you please tell me how to fix that?

Thank you.

More correct you get a http code 429 which tells you that you run into a rate limit. The packets still got to the server but it didn’t want to answer you.

I don’t know, some tool, maybe svn, doesn’t understand that format of proxy. It is probably a good idea to figure out why you are in the rate limit in the first place and try to stop whatever is hammering against their API constantly to get through it without having to rely on a proxy.

Thank you. I’m not really hammering, I assume the Linode subnet where my VPS resides is hammering… So it is a problem that might follow me even if I re-deploy the VPS…

Can you somehow authenticate against the service you try to pull from and with that increase the rate limit or make it account specific instead of IP specific?

I’m just using

services.wordpress.sites."example.org" = {
  plugins = {
    inherit (pkgs.wordpressPackages.plugins)
      merge-minify-refresh;
  };
};

as described in: Wordpress - NixOS Wiki

I was able to rebuild a month ago but it doesn’t work now…