NixOS / nixops

NixOps is a tool for deploying to NixOS machines in a network or cloud.
https://nixos.org/nixops
GNU Lesser General Public License v3.0
1.85k stars 365 forks source link

nixops show-physical --backup returns an empty output on GCE #748

Closed AmineChikhaoui closed 6 years ago

AmineChikhaoui commented 7 years ago

It seems GCE backend doesn't implement get_physical_backup_spec as ec2 does for example which makes the nixops show-physical --backup response empty.

AmineChikhaoui commented 7 years ago

It seems also block device mapping option in GCP doesn't really follow the pattern being done in EC2 where the attrs names should be device identifiers which makes backup restore process more easier instead of having the current:

deployment.gce.blockDeviceMapping =  {
        "${gce_dev_prefix}${config.deployment.gce.machineName}-root" = {
            image = config.deployment.gce.bootstrapImage;          
            size = config.deployment.gce.rootDiskSize;
            diskType = config.deployment.gce.rootDiskType;         
            bootDisk = true;
            disk_name = "root";
        }; 
      } // (listToAttrs
        (map (fs: let fsgce = mkDefaultDiskName fs.mountPoint fs.gce; in 
                  nameValuePair "${gce_dev_prefix}${get_disk_name fsgce}" fsgce
          )
         (filter (fs: fs.gce != null) (attrValues config.fileSystems))));

where it sets some kind of default id "scsi-0GooglePersistentDisk$(volume_name)" @Phreedom do you happen to remember why you had to do that ? is there anything that can prevent us from using actual device names as attributes names ?