Skip to content

Commit

Permalink
customBuilds: add digitalOcean
Browse files Browse the repository at this point in the history
  • Loading branch information
jwygoda committed Jun 2, 2021
1 parent 7110767 commit 011d3c2
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions doc/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
- [up](./flk/up.md)
- [update](./flk/update.md)
- [get](./flk/get.md)
- [doi](./flk/doi.md)
- [iso](./flk/iso.md)
- [install](./flk/install.md)
- [home](./flk/home.md)
Expand Down
10 changes: 10 additions & 0 deletions doc/flk/doi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# DigitalOcean

Making a DigitalOcean compatible image for `hosts/NixOS.nix` is as simple as:
```sh
flk iso NixOS
```

Now you can [create a droplet](https://cloud.digitalocean.com/droplets/new) using your custom image.

This works for any file matching `hosts/*.nix` excluding `default.nix`.
4 changes: 4 additions & 0 deletions modules/customBuilds.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,9 @@ in
}
];
})).config.home-manager.users;

digitalOcean = (mkBuild ({ modulesPath, ... }: {
imports = [ "${modulesPath}/virtualisation/digital-ocean-image.nix" ];
})).config.system.build.digitalOceanImage;
};
}

0 comments on commit 011d3c2

Please sign in to comment.