mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-05 16:10:14 +00:00
attempts to add qcow-efi to get oracle to work
and also adding things from the oci build
This commit is contained in:
@ -215,8 +215,9 @@
|
|||||||
};
|
};
|
||||||
"${name}-qcow" = lib.generateImage {
|
"${name}-qcow" = lib.generateImage {
|
||||||
inherit system module;
|
inherit system module;
|
||||||
format = "qcow";
|
format = "qcow-efi";
|
||||||
specialArgs = { inherit hostnames; };
|
specialArgs = { inherit hostnames; };
|
||||||
|
# extraModules = [ "${nixpkgs}/nixos/modules/virtualisation/oci-image.nix" ];
|
||||||
};
|
};
|
||||||
}) hosts)
|
}) hosts)
|
||||||
) lib.linuxHosts # x86_64-linux = { arrow = ...; swan = ...; }
|
) lib.linuxHosts # x86_64-linux = { arrow = ...; swan = ...; }
|
||||||
@ -235,6 +236,12 @@
|
|||||||
//
|
//
|
||||||
# Share generated images for each relevant host
|
# Share generated images for each relevant host
|
||||||
(if (lib.hasInfix "linux" system) then generators.${system} else { })
|
(if (lib.hasInfix "linux" system) then generators.${system} else { })
|
||||||
|
|
||||||
|
# //
|
||||||
|
# # Oracle
|
||||||
|
# {
|
||||||
|
# flame-oci = nixosConfigurations.flame.config.system.build.OCIImage;
|
||||||
|
# }
|
||||||
);
|
);
|
||||||
|
|
||||||
# Development environments
|
# Development environments
|
||||||
|
@ -58,4 +58,55 @@ rec {
|
|||||||
ca = "ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBK/6oyVqjFGX3Uvrc3VS8J9sphxzAnRzKC85xgkHfYgR3TK6qBGXzHrknEj21xeZrr3G2y1UsGzphWJd9ZfIcdA= open-ssh-ca@cloudflareaccess.org";
|
ca = "ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBK/6oyVqjFGX3Uvrc3VS8J9sphxzAnRzKC85xgkHfYgR3TK6qBGXzHrknEj21xeZrr3G2y1UsGzphWJd9ZfIcdA= open-ssh-ca@cloudflareaccess.org";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Taken from https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/virtualisation/oci-common.nix
|
||||||
|
|
||||||
|
# Taken from /proc/cmdline of Ubuntu 20.04.2 LTS on OCI
|
||||||
|
boot.kernelParams = [
|
||||||
|
"nvme.shutdown_timeout=10"
|
||||||
|
"nvme_core.shutdown_timeout=10"
|
||||||
|
"libiscsi.debug_libiscsi_eh=1"
|
||||||
|
"crash_kexec_post_notifiers"
|
||||||
|
# VNC console
|
||||||
|
"console=tty1"
|
||||||
|
# x86_64-linux
|
||||||
|
"console=ttyS0"
|
||||||
|
# aarch64-linux
|
||||||
|
"console=ttyAMA0,115200"
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.growPartition = true;
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/disk/by-label/nixos";
|
||||||
|
fsType = "ext4";
|
||||||
|
autoResize = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" = {
|
||||||
|
device = "/dev/disk/by-label/ESP";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
boot.loader.efi.canTouchEfiVariables = false;
|
||||||
|
boot.loader.grub = {
|
||||||
|
device = "nodev";
|
||||||
|
splashImage = null;
|
||||||
|
extraConfig = ''
|
||||||
|
serial --unit=0 --speed=115200 --word=8 --parity=no --stop=1
|
||||||
|
terminal_input --append serial
|
||||||
|
terminal_output --append serial
|
||||||
|
'';
|
||||||
|
efiInstallAsRemovable = true;
|
||||||
|
efiSupport = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# https://docs.oracle.com/en-us/iaas/Content/Compute/Tasks/configuringntpservice.htm#Configuring_the_Oracle_Cloud_Infrastructure_NTP_Service_for_an_Instance
|
||||||
|
networking.timeServers = [ "169.254.169.254" ];
|
||||||
|
|
||||||
|
services.openssh.enable = true;
|
||||||
|
|
||||||
|
# Otherwise the instance may not have a working network-online.target,
|
||||||
|
# making the fetch-ssh-keys.service fail
|
||||||
|
networking.useNetworkd = true;
|
||||||
}
|
}
|
||||||
|
@ -193,7 +193,7 @@ lib
|
|||||||
nmasur.profiles.wsl.enable = lib.mkForce false;
|
nmasur.profiles.wsl.enable = lib.mkForce false;
|
||||||
boot.loader.grub.enable = lib.mkForce false;
|
boot.loader.grub.enable = lib.mkForce false;
|
||||||
};
|
};
|
||||||
qcow = {
|
qcow-efi = {
|
||||||
nmasur.profiles.wsl.enable = lib.mkForce false;
|
nmasur.profiles.wsl.enable = lib.mkForce false;
|
||||||
boot.loader.grub.enable = lib.mkForce false;
|
boot.loader.grub.enable = lib.mkForce false;
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user