Browse Source
Fixes eval on darwin after #69072 Resolved conflict in pkgs/tools/security/thc-hydra/default.nix Basically had to reverttrojitaa1c0e10564
which adapts #69210 to master that doesn't yet have329a88efa7
Tested using maintainers/scripts/eval-release.sh before and after to see that the fix works
106 changed files with 2823 additions and 5605 deletions
@ -0,0 +1,37 @@
|
||||
<section xmlns="http://docbook.org/ns/docbook" |
||||
version="5.0" |
||||
xml:id="sec-installing-nspawn-container"> |
||||
<title>Installing into a nspawn container</title> |
||||
|
||||
<para> |
||||
For installing a NixOS into a systemd nspawn container the NixOS installation tools are needed. |
||||
If you run another distribution than NixOS on your host, |
||||
please follow <xref linkend="sec-installing-from-other-distro"/> steps 1, 2, and 3. |
||||
</para> |
||||
|
||||
<para> |
||||
Create a NixOS configuration file <filename>/var/lib/machines/my-container/etc/nixos/configuration.nix</filename>. |
||||
It is important that the container root file system is under <filename>/var/lib/machines</filename>. |
||||
This is the standard location where <command>machinectl</command> will look for containers. |
||||
If you choose place the root into another location you need to start the container directly with <command>systemd-nspawn</command>. |
||||
The file needs to have at least following options enabled: |
||||
<programlisting> |
||||
<xref linkend="opt-boot.isContainer"/> = true; |
||||
<xref linkend="opt-boot.loader.initScript.enable"/> = true; |
||||
</programlisting> |
||||
If your host uses <command>systemd-networkd</command> to configure the network, |
||||
you can also enable <xref linkend="opt-networking.useNetworkd"/> to use networkd default network configuration for your host and container. |
||||
</para> |
||||
|
||||
<para> |
||||
Install the container by running following command: |
||||
<screen>nixos-install --root /var/lib/machines/my-container \ |
||||
--no-channel-copy --no-root-passwd --no-bootloader</screen> |
||||
</para> |
||||
|
||||
<para> |
||||
Start the container by running following command: |
||||
<screen>machinectl start my-container</screen> |
||||
</para> |
||||
|
||||
</section> |
@ -0,0 +1,46 @@
|
||||
{ config, lib, pkgs, ... }: |
||||
|
||||
with lib; |
||||
|
||||
let |
||||
cfg = config.hardware.fancontrol; |
||||
configFile = pkgs.writeText "fan.conf" cfg.config; |
||||
|
||||
in { |
||||
|
||||
options.hardware.fancontrol = { |
||||
enable = mkEnableOption "fancontrol (requires fancontrol.config)"; |
||||
|
||||
config = mkOption { |
||||
type = types.lines; |
||||
default = null; |
||||
example = '' |
||||
# Configuration file generated by pwmconfig |
||||
INTERVAL=1 |
||||
DEVPATH=hwmon0=devices/platform/nct6775.656 hwmon1=devices/pci0000:00/0000:00:18.3 |
||||
DEVNAME=hwmon0=nct6779 hwmon1=k10temp |
||||
FCTEMPS=hwmon0/pwm2=hwmon1/temp1_input |
||||
FCFANS=hwmon0/pwm2=hwmon0/fan2_input |
||||
MINTEMP=hwmon0/pwm2=25 |
||||
MAXTEMP=hwmon0/pwm2=60 |
||||
MINSTART=hwmon0/pwm2=25 |
||||
MINSTOP=hwmon0/pwm2=10 |
||||
MINPWM=hwmon0/pwm2=0 |
||||
MAXPWM=hwmon0/pwm2=255 |
||||
''; |
||||
description = "Contents for configuration file. See <citerefentry><refentrytitle>pwmconfig</refentrytitle><manvolnum>8</manvolnum></citerefentry>."; |
||||
}; |
||||
}; |
||||
|
||||
|
||||
config = mkIf cfg.enable { |
||||
systemd.services.fancontrol = { |
||||
description = "Fan speed control from lm_sensors"; |
||||
wantedBy = [ "multi-user.target" ]; |
||||
serviceConfig = { |
||||
Type = "simple"; |
||||
ExecStart = "${pkgs.lm_sensors}/bin/fancontrol ${configFile}"; |
||||
}; |
||||
}; |
||||
}; |
||||
} |
@ -0,0 +1,52 @@
|
||||
import ./make-test.nix (let |
||||
|
||||
container = { ... }: { |
||||
boot.isContainer = true; |
||||
|
||||
# use networkd to obtain systemd network setup |
||||
networking.useNetworkd = true; |
||||
|
||||
# systemd-nspawn expects /sbin/init |
||||
boot.loader.initScript.enable = true; |
||||
|
||||
imports = [ ../modules/profiles/minimal.nix ]; |
||||
}; |
||||
|
||||
containerSystem = (import ../lib/eval-config.nix { |
||||
modules = [ container ]; |
||||
}).config.system.build.toplevel; |
||||
|
||||
containerName = "container"; |
||||
containerRoot = "/var/lib/machines/${containerName}"; |
||||
|
||||
in { |
||||
name = "systemd-machinectl"; |
||||
|
||||
machine = { lib, ... }: { |
||||
# use networkd to obtain systemd network setup |
||||
networking.useNetworkd = true; |
||||
|
||||
# open DHCP server on interface to container |
||||
networking.firewall.trustedInterfaces = [ "ve-+" ]; |
||||
|
||||
# do not try to access cache.nixos.org |
||||
nix.binaryCaches = lib.mkForce []; |
||||
|
||||
virtualisation.pathsInNixDB = [ containerSystem ]; |
||||
}; |
||||
|
||||
testScript = '' |
||||
startAll; |
||||
|
||||
$machine->waitForUnit("default.target"); |
||||
$machine->succeed("mkdir -p ${containerRoot}"); |
||||
$machine->succeed("nixos-install --root ${containerRoot} --system ${containerSystem} --no-channel-copy --no-root-passwd --no-bootloader"); |
||||
|
||||
$machine->succeed("machinectl start ${containerName}"); |
||||
$machine->waitUntilSucceeds("systemctl -M ${containerName} is-active default.target"); |
||||
$machine->succeed("ping -n -c 1 ${containerName}"); |
||||
$machine->succeed("test `stat ${containerRoot}/var/empty -c %u%g` != 00"); |
||||
|
||||
$machine->succeed("machinectl stop ${containerName}"); |
||||
''; |
||||
}) |
@ -1,33 +1,72 @@
|
||||
{ stdenv, fetchurl, patchelf, makeWrapper, xorg, gcc, gcc-unwrapped }: |
||||
{ stdenv |
||||
, fetchurl |
||||
, makeDesktopItem |
||||
, makeWrapper |
||||
, patchelf |
||||
, fontconfig |
||||
, freetype |
||||
, gcc |
||||
, gcc-unwrapped |
||||
, iputils |
||||
, psmisc |
||||
, xorg }: |
||||
|
||||
stdenv.mkDerivation rec { |
||||
pname = "IPMIView"; |
||||
version = "2.14.0"; |
||||
buildVersion = "180213"; |
||||
pname = "IPMIView"; |
||||
version = "2.16.0"; |
||||
buildVersion = "190815"; |
||||
|
||||
src = fetchurl { |
||||
url = "ftp://ftp.supermicro.com/utility/IPMIView/Linux/IPMIView_${version}_build.${buildVersion}_bundleJRE_Linux_x64.tar.gz"; |
||||
sha256 = "1wp22wm7smlsb25x0cck4p660cycfczxj381930crd1qrf68mw4h"; |
||||
src = fetchurl { |
||||
url = "https://www.supermicro.com/wftp/utility/IPMIView/Linux/IPMIView_${version}_build.${buildVersion}_bundleJRE_Linux_x64.tar.gz"; |
||||
sha256 = "0qw9zfnj0cyvab7ndamlw2y0gpczjhh1jkz8340kl42r2xmhkvpl"; |
||||
}; |
||||
|
||||
nativeBuildInputs = [ patchelf makeWrapper ]; |
||||
nativeBuildInputs = [ patchelf makeWrapper ]; |
||||
buildPhase = with xorg; |
||||
let |
||||
stunnelBinary = if stdenv.hostPlatform.system == "x86_64-linux" then "linux/stunnel64" |
||||
else if stdenv.hostPlatform.system == "i686-linux" then "linux/stunnel32" |
||||
else throw "IPMIView is not supported on this platform"; |
||||
in |
||||
'' |
||||
patchelf --set-rpath "${stdenv.lib.makeLibraryPath [ libX11 libXext libXrender libXtst libXi ]}" ./jre/lib/amd64/libawt_xawt.so |
||||
patchelf --set-rpath "${stdenv.lib.makeLibraryPath [ freetype ]}" ./jre/lib/amd64/libfontmanager.so |
||||
patchelf --set-rpath "${gcc-unwrapped.lib}/lib" ./libiKVM64.so |
||||
patchelf --set-rpath "${gcc.cc}/lib:$out/jre/lib/amd64/jli" --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" ./jre/bin/java |
||||
patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" ./BMCSecurity/${stunnelBinary} |
||||
''; |
||||
|
||||
buildPhase = with xorg; '' |
||||
patchelf --set-rpath "${stdenv.lib.makeLibraryPath [ libX11 libXext libXrender libXtst libXi ]}" ./jre/lib/amd64/xawt/libmawt.so |
||||
patchelf --set-rpath "${gcc-unwrapped.lib}/lib" ./libiKVM64.so |
||||
patchelf --set-rpath "${stdenv.lib.makeLibraryPath [ libXcursor libX11 libXext libXrender libXtst libXi ]}" --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" ./jre/bin/javaws |
||||
patchelf --set-rpath "${gcc.cc}/lib:$out/jre/lib/amd64/jli" --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" ./jre/bin/java |
||||
''; |
||||
desktopItem = makeDesktopItem rec { |
||||
name = "IPMIView"; |
||||
exec = "IPMIView"; |
||||
desktopName = name; |
||||
genericName = "Supermicro BMC manager"; |
||||
categories = "Network;Configuration"; |
||||
}; |
||||
|
||||
installPhase = '' |
||||
mkdir -p $out/bin |
||||
cp -R . $out/ |
||||
|
||||
installPhase = '' |
||||
mkdir -p $out/bin |
||||
cp -R . $out/ |
||||
makeWrapper $out/jre/bin/java $out/bin/IPMIView \ |
||||
--prefix PATH : "$out/jre/bin" \ |
||||
--add-flags "-jar $out/IPMIView20.jar" |
||||
''; |
||||
ln -s ${desktopItem}/share $out/share |
||||
|
||||
meta = with stdenv.lib; { |
||||
# LD_LIBRARY_PATH: fontconfig is used from java code |
||||
# PATH: iputils is used for ping, and psmisc is for killall |
||||
# WORK_DIR: unfortunately the ikvm related binaries are loaded from |
||||
# and user configuration is written to files in the CWD |
||||
makeWrapper $out/jre/bin/java $out/bin/IPMIView \ |
||||
--set LD_LIBRARY_PATH "${stdenv.lib.makeLibraryPath [ fontconfig ]}" \ |
||||
--prefix PATH : "$out/jre/bin:${iputils}/bin:${psmisc}/bin" \ |
||||
--add-flags "-jar $out/IPMIView20.jar" \ |
||||
--run 'WORK_DIR=''${XDG_DATA_HOME:-~/.local/share}/ipmiview |
||||
mkdir -p $WORK_DIR |
||||
ln -snf '$out'/iKVM.jar '$out'/libiKVM* '$out'/libSharedLibrary* $WORK_DIR |
||||
cd $WORK_DIR' |
||||
''; |
||||
|
||||
meta = with stdenv.lib; { |
||||
license = licenses.unfree; |
||||
}; |
||||
} |
||||
maintainers = with maintainers; [ vlaci ]; |
||||
platforms = [ "x86_64-linux" "i686-linux" ]; |
||||
}; |
||||
} |
||||
|
@ -0,0 +1,25 @@
|
||||
{ stdenv, fetchFromGitHub, rustPlatform, Security }: |
||||
|
||||
rustPlatform.buildRustPackage rec { |
||||
pname = "pastel"; |
||||
version = "0.5.3"; |
||||
|
||||
src = fetchFromGitHub { |
||||
owner = "sharkdp"; |
||||
repo = pname; |
||||
rev = "v${version}"; |
||||
sha256 = "0f54p3pzfp7xrwlqn61l7j41vmgcfph3bhq2khxh5apfwwdx9nng"; |
||||
}; |
||||
|
||||
cargoSha256 = "05yvlm7z3zfn8qd8nb9zpch9xsfzidrpyrgg2vij3h3q095mdm66"; |
||||
|
||||
buildInputs = stdenv.lib.optional stdenv.isDarwin Security; |
||||
|
||||
meta = with stdenv.lib; { |
||||
description = "A command-line tool to generate, analyze, convert and manipulate colors"; |
||||
homepage = https://github.com/sharkdp/pastel; |
||||
license = with licenses; [ asl20 /* or */ mit ]; |
||||
maintainers = with maintainers; [ davidtwco ]; |
||||
platforms = platforms.all; |
||||
}; |
||||
} |
@ -1,37 +1,50 @@
|
||||
{ mkDerivation |
||||
, lib |
||||
, fetchurl |
||||
{ akonadi-contacts |
||||
, cmake |
||||
, fetchgit |
||||
, gpgme |
||||
, kcontacts |
||||
, lib |
||||
, mimetic |
||||
, mkDerivation |
||||
, pkgconfig |
||||
, qgpgme |
||||
, qtbase |
||||
, qtwebkit |
||||
, qtkeychain |
||||
, qttools |
||||
, qtwebkit |
||||
}: |
||||
|
||||
mkDerivation rec { |
||||
pname = "trojita"; |
||||
version = "0.7"; |
||||
version = "0.7.20190618"; |
||||
|
||||
src = fetchurl { |
||||
url = "mirror://sourceforge/trojita/trojita/${pname}-${version}.tar.xz"; |
||||
sha256 = "1n9n07md23ny6asyw0xpih37vlwzp7vawbkprl7a1bqwfa0si3g0"; |
||||
src = fetchgit { |
||||
url = "https://anongit.kde.org/trojita.git"; |
||||
rev = "90b417b131853553c94ff93aef62abaf301aa8f1"; |
||||
sha256 = "0xpxq5bzqaa68lkz90wima5q2m0mdcn0rvnigb66lylb4n20mnql"; |
||||
}; |
||||
|
||||
buildInputs = [ |
||||
akonadi-contacts |
||||
gpgme |
||||
kcontacts |
||||
mimetic |
||||
qgpgme |
||||
qtbase |
||||
qtkeychain |
||||
qtwebkit |
||||
]; |
||||
|
||||
nativeBuildInputs = [ |
||||
cmake |
||||
pkgconfig |
||||
qttools |
||||
]; |
||||
|
||||
|
||||
meta = with lib; { |
||||
description = "A Qt IMAP e-mail client"; |
||||
homepage = http://trojita.flaska.net/; |
||||
homepage = "http://trojita.flaska.net/"; |
||||
license = with licenses; [ gpl2 gpl3 ]; |
||||
platforms = platforms.linux; |
||||
}; |
||||
|
||||
} |
||||
|
@ -0,0 +1,72 @@
|
||||
--- a/src/VBox/HostDrivers/VBoxNetFlt/linux/VBoxNetFlt-linux.c
|
||||
+++ b/src/VBox/HostDrivers/VBoxNetFlt/linux/VBoxNetFlt-linux.c
|
||||
@@ -2123,7 +2123,9 @@
|
||||
#endif
|
||||
if (in_dev != NULL)
|
||||
{
|
||||
- for_ifa(in_dev) {
|
||||
+ struct in_ifaddr *ifa;
|
||||
+
|
||||
+ for (ifa = in_dev->ifa_list; ifa; ifa = ifa->ifa_next) {
|
||||
if (VBOX_IPV4_IS_LOOPBACK(ifa->ifa_address))
|
||||
return NOTIFY_OK;
|
||||
|
||||
@@ -2137,7 +2139,7 @@
|
||||
|
||||
pThis->pSwitchPort->pfnNotifyHostAddress(pThis->pSwitchPort,
|
||||
/* :fAdded */ true, kIntNetAddrType_IPv4, &ifa->ifa_address);
|
||||
- } endfor_ifa(in_dev);
|
||||
+ }
|
||||
}
|
||||
|
||||
/*
|
||||
--- a/src/VBox/Runtime/r0drv/linux/mp-r0drv-linux.c
|
||||
+++ a/src/VBox/Runtime/r0drv/linux/mp-r0drv-linux.c
|
||||
@@ -283,12 +283,15 @@
|
||||
if (RTCpuSetCount(&OnlineSet) > 1)
|
||||
{
|
||||
/* Fire the function on all other CPUs without waiting for completion. */
|
||||
-# if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
|
||||
+# if LINUX_VERSION_CODE >= KERNEL_VERSION(5, 3, 0)
|
||||
+ smp_call_function(rtmpLinuxAllWrapper, &Args, 0 /* wait */);
|
||||
+# elif LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 27)
|
||||
int rc = smp_call_function(rtmpLinuxAllWrapper, &Args, 0 /* wait */);
|
||||
+ Assert(!rc); NOREF(rc);
|
||||
# else
|
||||
int rc = smp_call_function(rtmpLinuxAllWrapper, &Args, 0 /* retry */, 0 /* wait */);
|
||||
-# endif
|
||||
Assert(!rc); NOREF(r |