anchor.diff:        after = [ "network-online.target" ];
         wants = [ "network-online.target" ];
   
  -      path  = [ pkgs.curl ];
  +      path  = [ pkgs.wget ];
         script =
           ''
  +          wget="wget --retry-connrefused -t 6 --waitretry=10"
             # Don't download the SSH key if it has already been downloaded
             if ! [ -e /root/.ssh/authorized_keys ]; then
                   echo "obtaining SSH key..."
                   mkdir -p /root/.ssh
  -                curl -o /root/authorized-keys-metadata http://metadata/0.1/meta-data/authorized-keys
  +                $wget -O /root/authorized-keys-metadata http://metadata/0.1/meta-data/authorized-keys
                   if [ $? -eq 0 -a -e /root/authorized-keys-metadata ]; then
                       cat /root/authorized-keys-metadata | cut -d: -f2- > /root/key.pub
                       if ! grep -q -f /root/key.pub /root/.ssh/authorized_keys; then
  
positive.code:           fi
  
            echo "obtaining SSH public host key..."
            curl -o /root/ssh_host_ecdsa_key.pub --retry-max-time 60 http://metadata/0.1/meta-data/attributes/ssh_host_ecdsa_key_pub
            if [ $? -eq 0 -a -e /root/ssh_host_ecdsa_key.pub ]; then
                mv -f /root/ssh_host_ecdsa_key.pub /etc/ssh/ssh_host_ecdsa_key.pub
                echo "downloaded ssh_host_ecdsa_key.pub"
  
negative.code: 
    networking.usePredictableInterfaceNames = false;
  
    systemd.services.fetch-ssh-keys =
      { description = "Fetch host keys and authorized_keys for root user";
  
  