mirror of
https://github.com/nix-community/nixos-generators.git
synced 2024-11-23 02:45:29 +03:00
add make-gce: make Google Compute Engine image
This commit is contained in:
parent
6bf7e8c291
commit
48956192c2
@ -14,8 +14,9 @@ it echoes the path to a iso image, which you then can flash onto an usb-stick or
|
||||
|
||||
we currently have following generators:
|
||||
|
||||
format | script
|
||||
--- | ---
|
||||
format | script | description
|
||||
--- | --- | ---
|
||||
gce | bin/make-gce | Google Compute Image
|
||||
iso | bin/make-iso
|
||||
kexec | bin/make-kexec
|
||||
kexec-bundle | bin/make-kexec-bundle
|
||||
|
5
bin/make-gce
Executable file
5
bin/make-gce
Executable file
@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
CONFIG=${1:-config.nix}
|
||||
shift
|
||||
out=$(nix-build --no-out-link '<nixpkgs/nixos>' -A config.system.build.googleComputeImage -I nixos-config=lib/gce.nix -I nixcfg=${CONFIG} "$@" )
|
||||
echo "$out"/*.tar.gz
|
7
lib/gce.nix
Normal file
7
lib/gce.nix
Normal file
@ -0,0 +1,7 @@
|
||||
{ modulesPath, ... }:
|
||||
{
|
||||
imports = [
|
||||
"${toString modulesPath}/virtualisation/google-compute-image.nix"
|
||||
<nixcfg>
|
||||
];
|
||||
}
|
Loading…
Reference in New Issue
Block a user