Merge master into closure-size
The kde-5 stuff still didn't merge well. I hand-fixed what I saw, but there may be more problems.
This commit is contained in:
@@ -9,10 +9,10 @@ let
|
||||
waagent = with pkgs; stdenv.mkDerivation rec {
|
||||
name = "waagent-2.0";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "phreedom";
|
||||
owner = "Azure";
|
||||
repo = "WALinuxAgent";
|
||||
rev = "1d31fe8cbc7f842993eed9b33a3d3f5410c364e3";
|
||||
sha256 = "1s53pfmy3azp0rmympmnphyq96sr9jy07pbsfza6mdzpalx1ripl";
|
||||
rev = "1b3a8407a95344d9d12a2a377f64140975f1e8e4";
|
||||
sha256 = "10byzvmpgrmr4d5mdn2kq04aapqb3sgr1admk13wjmy5cd6bwd2x";
|
||||
};
|
||||
buildInputs = [ makeWrapper python pythonPackages.wrapPython ];
|
||||
runtimeDeps = [ findutils gnugrep gawk coreutils openssl openssh
|
||||
@@ -157,12 +157,6 @@ in
|
||||
after = [ "ip-up.target" ];
|
||||
wants = [ "ip-up.target" ];
|
||||
|
||||
environment = {
|
||||
GIT_SSL_CAINFO = "/etc/ssl/certs/ca-certificates.crt";
|
||||
OPENSSL_X509_CERT_FILE = "/etc/ssl/certs/ca-certificates.crt";
|
||||
SSL_CERT_FILE = "/etc/ssl/certs/ca-certificates.crt";
|
||||
};
|
||||
|
||||
path = [ pkgs.e2fsprogs ];
|
||||
description = "Windows Azure Agent Service";
|
||||
unitConfig.ConditionPathExists = "/etc/waagent.conf";
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
{ config, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
# To build the configuration or use nix-env, you need to run
|
||||
# either nixos-rebuild --upgrade or nix-channel --update
|
||||
# to fetch the nixos channel.
|
||||
|
||||
# This configures everything but bootstrap services,
|
||||
# which only need to be run once and have already finished
|
||||
# if you are able to see this comment.
|
||||
imports = [ "${modulesPath}/virtualisation/azure-common.nix" ];
|
||||
}
|
||||
@@ -16,14 +16,14 @@ in
|
||||
cyl=$(((${diskSize}*1024*1024)/(512*63*255)))
|
||||
size=$(($cyl*255*63*512))
|
||||
roundedsize=$((($size/(1024*1024)+1)*(1024*1024)))
|
||||
${pkgs.vmTools.qemu}/bin/qemu-img create -f raw $diskImage $roundedsize
|
||||
${pkgs.vmTools.qemu-220}/bin/qemu-img create -f raw $diskImage $roundedsize
|
||||
mv closure xchg/
|
||||
'';
|
||||
|
||||
postVM =
|
||||
''
|
||||
mkdir -p $out
|
||||
${pkgs.vmTools.qemu}/bin/qemu-img convert -f raw -O vpc $diskImage $out/disk.vhd
|
||||
${pkgs.vmTools.qemu-220}/bin/qemu-img convert -f raw -O vpc -o subformat=fixed $diskImage $out/disk.vhd
|
||||
rm $diskImage
|
||||
'';
|
||||
diskImageBase = "nixos-image-${config.system.nixosLabel}-${pkgs.stdenv.system}.raw";
|
||||
@@ -78,7 +78,7 @@ in
|
||||
|
||||
echo Install a configuration.nix.
|
||||
mkdir -p /mnt/etc/nixos /mnt/boot/grub
|
||||
cp ${./azure-config.nix} /mnt/etc/nixos/configuration.nix
|
||||
cp ${./azure-config-user.nix} /mnt/etc/nixos/configuration.nix
|
||||
|
||||
echo Generate the GRUB menu.
|
||||
ln -s vda /dev/sda
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
diff --git a/Makefile b/Makefile
|
||||
index d6b9dc1..ce7c493 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -384,8 +384,7 @@ install-confdir:
|
||||
install-sysconfig: install-datadir install-confdir
|
||||
$(INSTALL_DATA) $(SRC_PATH)/sysconfigs/target/target-x86_64.conf "$(DESTDIR)$(qemu_confdir)"
|
||||
|
||||
-install: all $(if $(BUILD_DOCS),install-doc) install-sysconfig \
|
||||
-install-datadir install-localstatedir
|
||||
+install: all $(if $(BUILD_DOCS),install-doc) install-datadir
|
||||
ifneq ($(TOOLS),)
|
||||
$(call install-prog,$(TOOLS),$(DESTDIR)$(bindir))
|
||||
endif
|
||||
@@ -43,18 +43,20 @@ with lib;
|
||||
|
||||
mkdir -m 0755 -p /etc/ssh
|
||||
|
||||
key="$(sed 's/|/\n/g; s/SSH_HOST_DSA_KEY://; t; d' $userData)"
|
||||
key_pub="$(sed 's/SSH_HOST_DSA_KEY_PUB://; t; d' $userData)"
|
||||
if [ -n "$key" -a -n "$key_pub" -a ! -e /etc/ssh/ssh_host_dsa_key ]; then
|
||||
(umask 077; echo "$key" > /etc/ssh/ssh_host_dsa_key)
|
||||
echo "$key_pub" > /etc/ssh/ssh_host_dsa_key.pub
|
||||
fi
|
||||
if [ -s "$userData" ]; then
|
||||
key="$(sed 's/|/\n/g; s/SSH_HOST_DSA_KEY://; t; d' $userData)"
|
||||
key_pub="$(sed 's/SSH_HOST_DSA_KEY_PUB://; t; d' $userData)"
|
||||
if [ -n "$key" -a -n "$key_pub" -a ! -e /etc/ssh/ssh_host_dsa_key ]; then
|
||||
(umask 077; echo "$key" > /etc/ssh/ssh_host_dsa_key)
|
||||
echo "$key_pub" > /etc/ssh/ssh_host_dsa_key.pub
|
||||
fi
|
||||
|
||||
key="$(sed 's/|/\n/g; s/SSH_HOST_ED25519_KEY://; t; d' $userData)"
|
||||
key_pub="$(sed 's/SSH_HOST_ED25519_KEY_PUB://; t; d' $userData)"
|
||||
if [ -n "$key" -a -n "$key_pub" -a ! -e /etc/ssh/ssh_host_ed25519_key ]; then
|
||||
(umask 077; echo "$key" > /etc/ssh/ssh_host_ed25519_key)
|
||||
echo "$key_pub" > /etc/ssh/ssh_host_ed25519_key.pub
|
||||
key="$(sed 's/|/\n/g; s/SSH_HOST_ED25519_KEY://; t; d' $userData)"
|
||||
key_pub="$(sed 's/SSH_HOST_ED25519_KEY_PUB://; t; d' $userData)"
|
||||
if [ -n "$key" -a -n "$key_pub" -a ! -e /etc/ssh/ssh_host_ed25519_key ]; then
|
||||
(umask 077; echo "$key" > /etc/ssh/ssh_host_ed25519_key)
|
||||
echo "$key_pub" > /etc/ssh/ssh_host_ed25519_key.pub
|
||||
fi
|
||||
fi
|
||||
'';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user