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.78k stars 365 forks source link

`network.storage.legacy.databasefile` setting has not been implemented #1472

Open roberth opened 2 years ago

roberth commented 2 years ago

My flake-based deployment contains

network.storage.legacy = {
  databasefile = "~/.nixops/deployments-nixops-example.nixops";
};

which points to a new path. Yet, I see all my usual legacy deployments in nixops list.

I can't find databasefile anywhere but in the NixOps 1->2 upgrade message.

abbradar commented 2 years ago

Together with the new NixOps way of having explicit network directories this creates confusion and possibility of devastating errors. Consider two deployments, production and development, which use different network directories. On NixOps 1 I would have set different configuration paths and use nixops -d production .... Currently when I'm in development network directory I see this:

+--------------------------------------+-------------+----------------------------------------------+------------+------+
| UUID                                 | Name        | Description                                  | # Machines | Type |
+--------------------------------------+-------------+----------------------------------------------+------------+------+
| e0a78705-3cff-11ea-85a3-8600003a0125 | development | Development deployment                       |          1 | none |
| 9c212957-69f2-11ea-88d6-8600003a0125 | production  | Development deployment                       |          1 | none |
+--------------------------------------+-------------+----------------------------------------------+------------+------+

I could by mistake run nixops deploy -d production here and destroy my servers.