Merge staging-next into staging

This commit is contained in:
github-actions[bot] 2021-04-01 00:15:44 +00:00 committed by GitHub
commit b152812791
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
69 changed files with 7066 additions and 168 deletions

View File

@ -2349,6 +2349,12 @@
githubId = 15774340;
name = "Thomas Depierre";
};
diegolelis = {
email = "diego.o.lelis@gmail.com";
github = "diegolelis";
githubId = 8404455;
name = "Diego Lelis";
};
dipinhora = {
email = "dipinhora+github@gmail.com";
github = "dipinhora";
@ -7479,6 +7485,12 @@
githubId = 627831;
name = "Hoang Xuan Phu";
};
piegames = {
name = "piegames";
email = "nix@piegames.de";
github = "piegamesde";
githubId = 14054505;
};
pierrechevalier83 = {
email = "pierrechevalier83@gmail.com";
github = "pierrechevalier83";

View File

@ -499,6 +499,7 @@
./services/misc/lifecycled.nix
./services/misc/mame.nix
./services/misc/matrix-appservice-discord.nix
./services/misc/matrix-appservice-irc.nix
./services/misc/matrix-synapse.nix
./services/misc/mautrix-telegram.nix
./services/misc/mbpfan.nix
@ -889,6 +890,7 @@
./services/web-apps/atlassian/crowd.nix
./services/web-apps/atlassian/jira.nix
./services/web-apps/bookstack.nix
./services/web-apps/calibre-web.nix
./services/web-apps/convos.nix
./services/web-apps/cryptpad.nix
./services/web-apps/documize.nix

View File

@ -0,0 +1,228 @@
{ config, pkgs, lib, ... }:
with lib;
let
cfg = config.services.matrix-appservice-irc;
pkg = pkgs.matrix-appservice-irc;
bin = "${pkg}/bin/matrix-appservice-irc";
jsonType = (pkgs.formats.json {}).type;
configFile = pkgs.runCommandNoCC "matrix-appservice-irc.yml" {
# Because this program will be run at build time, we need `nativeBuildInputs`
nativeBuildInputs = [ (pkgs.python3.withPackages (ps: [ ps.pyyaml ps.jsonschema ])) ];
preferLocalBuild = true;
config = builtins.toJSON cfg.settings;
passAsFile = [ "config" ];
} ''
# The schema is given as yaml, we need to convert it to json
python -c 'import json; import yaml; import sys; json.dump(yaml.safe_load(sys.stdin), sys.stdout)' \
< ${pkg}/lib/node_modules/matrix-appservice-irc/config.schema.yml \
> config.schema.json
python -m jsonschema config.schema.json -i $configPath
cp "$configPath" "$out"
'';
registrationFile = "/var/lib/matrix-appservice-irc/registration.yml";
in {
options.services.matrix-appservice-irc = with types; {
enable = mkEnableOption "the Matrix/IRC bridge";
port = mkOption {
type = port;
description = "The port to listen on";
default = 8009;
};
needBindingCap = mkOption {
type = bool;
description = "Whether the daemon needs to bind to ports below 1024 (e.g. for the ident service)";
default = false;
};
passwordEncryptionKeyLength = mkOption {
type = ints.unsigned;
description = "Length of the key to encrypt IRC passwords with";
default = 4096;
example = 8192;
};
registrationUrl = mkOption {
type = str;
description = ''
The URL where the application service is listening for homeserver requests,
from the Matrix homeserver perspective.
'';
example = "http://localhost:8009";
};
localpart = mkOption {
type = str;
description = "The user_id localpart to assign to the appservice";
default = "appservice-irc";
};
settings = mkOption {
description = ''
Configuration for the appservice, see
<link xlink:href="https://github.com/matrix-org/matrix-appservice-irc/blob/${pkgs.matrix-appservice-irc.version}/config.sample.yaml"/>
for supported values
'';
default = {};
type = submodule {
freeformType = jsonType;
options = {
homeserver = mkOption {
description = "Homeserver configuration";
default = {};
type = submodule {
freeformType = jsonType;
options = {
url = mkOption {
type = str;
description = "The URL to the home server for client-server API calls";
};
domain = mkOption {
type = str;
description = ''
The 'domain' part for user IDs on this home server. Usually
(but not always) is the "domain name" part of the homeserver URL.
'';
};
};
};
};
database = mkOption {
default = {};
description = "Configuration for the database";
type = submodule {
freeformType = jsonType;
options = {
engine = mkOption {
type = str;
description = "Which database engine to use";
default = "nedb";
example = "postgres";
};
connectionString = mkOption {
type = str;
description = "The database connection string";
default = "nedb://var/lib/matrix-appservice-irc/data";
example = "postgres://username:password@host:port/databasename";
};
};
};
};
ircService = mkOption {
default = {};
description = "IRC bridge configuration";
type = submodule {
freeformType = jsonType;
options = {
passwordEncryptionKeyPath = mkOption {
type = str;
description = ''
Location of the key with which IRC passwords are encrypted
for storage. Will be generated on first run if not present.
'';
default = "/var/lib/matrix-appservice-irc/passkey.pem";
};
servers = mkOption {
type = submodule { freeformType = jsonType; };
description = "IRC servers to connect to";
};
};
};
};
};
};
};
};
config = mkIf cfg.enable {
systemd.services.matrix-appservice-irc = {
description = "Matrix-IRC bridge";
before = [ "matrix-synapse.service" ]; # So the registration can be used by Synapse
wantedBy = [ "multi-user.target" ];
preStart = ''
umask 077
# Generate key for crypting passwords
if ! [ -f "${cfg.settings.ircService.passwordEncryptionKeyPath}" ]; then
${pkgs.openssl}/bin/openssl genpkey \
-out "${cfg.settings.ircService.passwordEncryptionKeyPath}" \
-outform PEM \
-algorithm RSA \
-pkeyopt "rsa_keygen_bits:${toString cfg.passwordEncryptionKeyLength}"
fi
# Generate registration file
if ! [ -f "${registrationFile}" ]; then
# The easy case: the file has not been generated yet
${bin} --generate-registration --file ${registrationFile} --config ${configFile} --url ${cfg.registrationUrl} --localpart ${cfg.localpart}
else
# The tricky case: we already have a generation file. Because the NixOS configuration might have changed, we need to
# regenerate it. But this would give the service a new random ID and tokens, so we need to back up and restore them.
# 1. Backup
id=$(grep "^id:.*$" ${registrationFile})
hs_token=$(grep "^hs_token:.*$" ${registrationFile})
as_token=$(grep "^as_token:.*$" ${registrationFile})
# 2. Regenerate
${bin} --generate-registration --file ${registrationFile} --config ${configFile} --url ${cfg.registrationUrl} --localpart ${cfg.localpart}
# 3. Restore
sed -i "s/^id:.*$/$id/g" ${registrationFile}
sed -i "s/^hs_token:.*$/$hs_token/g" ${registrationFile}
sed -i "s/^as_token:.*$/$as_token/g" ${registrationFile}
fi
# Allow synapse access to the registration
if ${getBin pkgs.glibc}/bin/getent group matrix-synapse > /dev/null; then
chgrp matrix-synapse ${registrationFile}
chmod g+r ${registrationFile}
fi
'';
serviceConfig = rec {
Type = "simple";
ExecStart = "${bin} --config ${configFile} --file ${registrationFile} --port ${toString cfg.port}";
ProtectHome = true;
PrivateDevices = true;
ProtectKernelTunables = true;
ProtectKernelModules = true;
ProtectControlGroups = true;
StateDirectory = "matrix-appservice-irc";
StateDirectoryMode = "755";
User = "matrix-appservice-irc";
Group = "matrix-appservice-irc";
CapabilityBoundingSet = [ "CAP_CHOWN" ] ++ optional (cfg.needBindingCap) "CAP_NET_BIND_SERVICE";
AmbientCapabilities = CapabilityBoundingSet;
NoNewPrivileges = true;
LockPersonality = true;
RestrictRealtime = true;
PrivateMounts = true;
SystemCallFilter = "~@aio @clock @cpu-emulation @debug @keyring @memlock @module @mount @obsolete @raw-io @setuid @swap";
SystemCallArchitectures = "native";
RestrictAddressFamilies = "AF_INET AF_INET6";
};
};
users.groups.matrix-appservice-irc = {};
users.users.matrix-appservice-irc = {
description = "Service user for the Matrix-IRC bridge";
group = "matrix-appservice-irc";
isSystemUser = true;
};
};
}

View File

@ -0,0 +1,165 @@
{ config, lib, pkgs, ... }:
let
cfg = config.services.calibre-web;
inherit (lib) concatStringsSep mkEnableOption mkIf mkOption optional optionalString types;
in
{
options = {
services.calibre-web = {
enable = mkEnableOption "Calibre-Web";
listen = {
ip = mkOption {
type = types.str;
default = "::1";
description = ''
IP address that Calibre-Web should listen on.
'';
};
port = mkOption {
type = types.port;
default = 8083;
description = ''
Listen port for Calibre-Web.
'';
};
};
dataDir = mkOption {
type = types.str;
default = "calibre-web";
description = ''
The directory below <filename>/var/lib</filename> where Calibre-Web stores its data.
'';
};
user = mkOption {
type = types.str;
default = "calibre-web";
description = "User account under which Calibre-Web runs.";
};
group = mkOption {
type = types.str;
default = "calibre-web";
description = "Group account under which Calibre-Web runs.";
};
openFirewall = mkOption {
type = types.bool;
default = false;
description = ''
Open ports in the firewall for the server.
'';
};
options = {
calibreLibrary = mkOption {
type = types.nullOr types.path;
default = null;
description = ''
Path to Calibre library.
'';
};
enableBookConversion = mkOption {
type = types.bool;
default = false;
description = ''
Configure path to the Calibre's ebook-convert in the DB.
'';
};
enableBookUploading = mkOption {
type = types.bool;
default = false;
description = ''
Allow books to be uploaded via Calibre-Web UI.
'';
};
reverseProxyAuth = {
enable = mkOption {
type = types.bool;
default = false;
description = ''
Enable authorization using auth proxy.
'';
};
header = mkOption {
type = types.str;
default = "";
description = ''
Auth proxy header name.
'';
};
};
};
};
};
config = mkIf cfg.enable {
systemd.services.calibre-web = let
appDb = "/var/lib/${cfg.dataDir}/app.db";
gdriveDb = "/var/lib/${cfg.dataDir}/gdrive.db";
calibreWebCmd = "${pkgs.calibre-web}/bin/calibre-web -p ${appDb} -g ${gdriveDb}";
settings = concatStringsSep ", " (
[
"config_port = ${toString cfg.listen.port}"
"config_uploading = ${if cfg.options.enableBookUploading then "1" else "0"}"
"config_allow_reverse_proxy_header_login = ${if cfg.options.reverseProxyAuth.enable then "1" else "0"}"
"config_reverse_proxy_login_header_name = '${cfg.options.reverseProxyAuth.header}'"
]
++ optional (cfg.options.calibreLibrary != null) "config_calibre_dir = '${cfg.options.calibreLibrary}'"
++ optional cfg.options.enableBookConversion "config_converterpath = '${pkgs.calibre}/bin/ebook-convert'"
);
in
{
description = "Web app for browsing, reading and downloading eBooks stored in a Calibre database";
after = [ "network.target" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
Type = "simple";
User = cfg.user;
Group = cfg.group;
StateDirectory = cfg.dataDir;
ExecStartPre = pkgs.writeShellScript "calibre-web-pre-start" (
''
__RUN_MIGRATIONS_AND_EXIT=1 ${calibreWebCmd}
${pkgs.sqlite}/bin/sqlite3 ${appDb} "update settings set ${settings}"
'' + optionalString (cfg.options.calibreLibrary != null) ''
test -f ${cfg.options.calibreLibrary}/metadata.db || { echo "Invalid Calibre library"; exit 1; }
''
);
ExecStart = "${calibreWebCmd} -i ${cfg.listen.ip}";
Restart = "on-failure";
};
};
networking.firewall = mkIf cfg.openFirewall {
allowedTCPPorts = [ cfg.listen.port ];
};
users.users = mkIf (cfg.user == "calibre-web") {
calibre-web = {
isSystemUser = true;
group = cfg.group;
};
};
users.groups = mkIf (cfg.group == "calibre-web") {
calibre-web = {};
};
};
meta.maintainers = with lib.maintainers; [ pborzenkov ];
}

View File

@ -49,6 +49,7 @@ in
cadvisor = handleTestOn ["x86_64-linux"] ./cadvisor.nix {};
cage = handleTest ./cage.nix {};
cagebreak = handleTest ./cagebreak.nix {};
calibre-web = handleTest ./calibre-web.nix {};
cassandra_2_1 = handleTest ./cassandra.nix { testPackage = pkgs.cassandra_2_1; };
cassandra_2_2 = handleTest ./cassandra.nix { testPackage = pkgs.cassandra_2_2; };
cassandra_3_0 = handleTest ./cassandra.nix { testPackage = pkgs.cassandra_3_0; };
@ -226,6 +227,7 @@ in
mariadb-galera-mariabackup = handleTest ./mysql/mariadb-galera-mariabackup.nix {};
mariadb-galera-rsync = handleTest ./mysql/mariadb-galera-rsync.nix {};
matomo = handleTest ./matomo.nix {};
matrix-appservice-irc = handleTest ./matrix-appservice-irc.nix {};
matrix-synapse = handleTest ./matrix-synapse.nix {};
mediawiki = handleTest ./mediawiki.nix {};
memcached = handleTest ./memcached.nix {};

View File

@ -0,0 +1,53 @@
import ./make-test-python.nix (
{ pkgs, lib, ... }:
let
port = 3142;
defaultPort = 8083;
in
with lib;
{
name = "calibre-web";
meta.maintainers = with pkgs.lib.maintainers; [ pborzenkov ];
nodes = {
default = { ... }: {
services.calibre-web.enable = true;
};
customized = { pkgs, ... }: {
services.calibre-web = {
enable = true;
listen.port = port;
options = {
calibreLibrary = "/tmp/books";
reverseProxyAuth = {
enable = true;
header = "X-User";
};
};
};
environment.systemPackages = [ pkgs.calibre ];
};
};
testScript = ''
start_all()
default.wait_for_unit("calibre-web.service")
default.wait_for_open_port(${toString defaultPort})
default.succeed(
"curl --fail 'http://localhost:${toString defaultPort}/basicconfig' | grep -q 'Basic Configuration'"
)
customized.succeed(
"mkdir /tmp/books && calibredb --library-path /tmp/books add -e --title test-book"
)
customized.succeed("systemctl restart calibre-web")
customized.wait_for_unit("calibre-web.service")
customized.wait_for_open_port(${toString port})
customized.succeed(
"curl --fail -H X-User:admin 'http://localhost:${toString port}' | grep -q test-book"
)
'';
}
)

View File

@ -0,0 +1,162 @@
import ./make-test-python.nix ({ pkgs, ... }:
let
homeserverUrl = "http://homeserver:8448";
in
{
name = "matrix-appservice-irc";
meta = {
maintainers = pkgs.matrix-appservice-irc.meta.maintainers;
};
nodes = {
homeserver = { pkgs, ... }: {
# We'll switch to this once the config is copied into place
specialisation.running.configuration = {
services.matrix-synapse = {
enable = true;
database_type = "sqlite3";
app_service_config_files = [ "/registration.yml" ];
enable_registration = true;
listeners = [
# The default but tls=false
{
"bind_address" = "";
"port" = 8448;
"resources" = [
{ "compress" = true; "names" = [ "client" "webclient" ]; }
{ "compress" = false; "names" = [ "federation" ]; }
];
"tls" = false;
"type" = "http";
"x_forwarded" = false;
}
];
};
networking.firewall.allowedTCPPorts = [ 8448 ];
};
};
ircd = { pkgs, ... }: {
services.ngircd = {
enable = true;
config = ''
[Global]
Name = ircd.ircd
Info = Server Info Text
AdminInfo1 = _
[Channel]
Name = #test
Topic = a cool place
[Options]
PAM = no
'';
};
networking.firewall.allowedTCPPorts = [ 6667 ];
};
appservice = { pkgs, ... }: {
services.matrix-appservice-irc = {
enable = true;
registrationUrl = "http://appservice:8009";
settings = {
homeserver.url = homeserverUrl;
homeserver.domain = "homeserver";
ircService.servers."ircd" = {
name = "IRCd";
port = 6667;
dynamicChannels = {
enabled = true;
aliasTemplate = "#irc_$CHANNEL";
};
};
};
};
networking.firewall.allowedTCPPorts = [ 8009 ];
};
client = { pkgs, ... }: {
environment.systemPackages = [
(pkgs.writers.writePython3Bin "do_test"
{ libraries = [ pkgs.python3Packages.matrix-client ]; } ''
import socket
from matrix_client.client import MatrixClient
from time import sleep
matrix = MatrixClient("${homeserverUrl}")
matrix.register_with_password(username="alice", password="foobar")
irc = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
irc.connect(("ircd", 6667))
irc.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
irc.send(b"USER bob bob bob :bob\n")
irc.send(b"NICK bob\n")
m_room = matrix.join_room("#irc_#test:homeserver")
irc.send(b"JOIN #test\n")
# plenty of time for the joins to happen
sleep(10)
m_room.send_text("hi from matrix")
irc.send(b"PRIVMSG #test :hi from irc \r\n")
print("Waiting for irc message...")
while True:
buf = irc.recv(10000)
if b"hi from matrix" in buf:
break
print("Waiting for matrix message...")
def callback(room, e):
if "hi from irc" in e['content']['body']:
exit(0)
m_room.add_listener(callback, "m.room.message")
matrix.listen_forever()
''
)
];
};
};
testScript = ''
start_all()
ircd.wait_for_unit("ngircd.service")
ircd.wait_for_open_port(6667)
with subtest("start the appservice"):
appservice.wait_for_unit("matrix-appservice-irc.service")
appservice.wait_for_open_port(8009)
with subtest("copy the registration file"):
appservice.copy_from_vm("/var/lib/matrix-appservice-irc/registration.yml")
homeserver.copy_from_host(
pathlib.Path(os.environ.get("out", os.getcwd())) / "registration.yml", "/"
)
homeserver.succeed("chmod 444 /registration.yml")
with subtest("start the homeserver"):
homeserver.succeed(
"/run/current-system/specialisation/running/bin/switch-to-configuration test >&2"
)
homeserver.wait_for_unit("matrix-synapse.service")
homeserver.wait_for_open_port(8448)
with subtest("ensure messages can be exchanged"):
client.succeed("do_test")
'';
})

View File

@ -9,13 +9,13 @@
stdenv.mkDerivation rec {
pname = "freac";
version = "1.1.3";
version = "1.1.4";
src = fetchFromGitHub {
owner = "enzo1982";
repo = "freac";
rev = "v${version}";
sha256 = "1sdrsc5pn5901bbds7dj02n71zn5rs4wnv2xxs8ffql4b7jjva0m";
sha256 = "sha256-JwZJOV4mxNKqhhdlfFcX06NwBxmbye2mgMfdM//bHYI=";
};
buildInputs = [

View File

@ -20,11 +20,11 @@ let
in
stdenv.mkDerivation rec {
pname = "clightning";
version = "0.9.3";
version = "0.10.0";
src = fetchurl {
url = "https://github.com/ElementsProject/lightning/releases/download/v${version}/clightning-v${version}.zip";
sha256 = "b4563921ed8bccd59d32b031f81825dc57fbe90882f0ecd5da89e48b59ff18b2";
sha256 = "5154e67780dddbf12f64c4b1994c3ee3834236f05b6462adf25e8a5f3fa407ea";
};
nativeBuildInputs = [ autogen autoconf automake gettext libtool pkg-config py3 unzip which ];

View File

@ -4,18 +4,18 @@
, alsaLib, atk, at-spi2-atk, at-spi2-core, cairo, dbus, cups, expat
, gdk-pixbuf, glib, gtk3, libX11, libXScrnSaver, libXcomposite, libXcursor
, libXdamage, libXext, libXfixes, libXi, libXrandr, libXrender, libXtst
, libxcb, libuuid, nspr, nss, pango
, libxcb, libuuid, libxshmfence, nspr, nss, pango
, systemd
}:
stdenv.mkDerivation rec {
pname = "drawio";
version = "14.4.3";
version = "14.5.1";
src = fetchurl {
url = "https://github.com/jgraph/drawio-desktop/releases/download/v${version}/draw.io-x86_64-${version}.rpm";
hash = "sha256-0wBjZg6IvjVTzAGeXTBBZjIN6s9NxKV0r76YK9h4fFk=";
url = "https://github.com/jgraph/drawio-desktop/releases/download/v${version}/drawio-x86_64-${version}.rpm";
hash = "sha256-ZrEoeeEhHQOLm/L3KA43Ru5fruIPK35CCUsllwpPB58=";
};
nativeBuildInputs = [
@ -46,6 +46,7 @@ stdenv.mkDerivation rec {
libXi
libXrandr
libXrender
libxshmfence
libXtst
libxcb
libuuid
@ -66,7 +67,7 @@ stdenv.mkDerivation rec {
installPhase = ''
mkdir -p $out/share
cp -r opt/draw.io $out/share/
cp -r opt/drawio $out/share/
# Application icon
mkdir -p $out/share/icons/hicolor
@ -77,11 +78,11 @@ stdenv.mkDerivation rec {
# Symlink wrapper
mkdir -p $out/bin
ln -s $out/share/draw.io/drawio $out/bin/drawio
ln -s $out/share/drawio/drawio $out/bin/drawio
# Update binary path
substituteInPlace $out/share/applications/drawio.desktop \
--replace /opt/draw.io/drawio $out/bin/drawio
--replace /opt/drawio/drawio $out/bin/drawio
'';
meta = with lib; {

View File

@ -0,0 +1,31 @@
{ lib, buildGoModule, fetchFromGitHub}:
buildGoModule rec {
name = "kuttl";
pname = "kuttl";
version = "0.9.0";
cli = "kubectl-kuttl";
src = fetchFromGitHub {
owner = "kudobuilder";
repo = "kuttl";
rev = "v${version}";
sha256 = "sha256:1cji0py2340mvcpplwq3licdkzjx7q5f27fdjjxvbhrgksnyw6hs";
};
vendorSha256 = "sha256:1shra42ifa2knxp58fj5hn074jg89f3nqdqk4rqbp3ybir84ahsd";
subPackages = [ "cmd/kubectl-kuttl" ];
buildFlagsArray = ''
-ldflags=-s -w
-X github.com/kudobuilder/kuttl/pkg/version.gitVersion=${version}
'';
meta = with lib; {
description = "The KUbernetes Test TooL (KUTTL) provides a declarative approach to testing production-grade Kubernetes operators";
homepage = "https://github.com/kudobuilder/kuttl";
license = licenses.asl20;
maintainers = with maintainers; [ diegolelis ];
};
}

View File

@ -111,11 +111,6 @@ let
});
in {
subversion19 = common {
version = "1.9.12";
sha256 = "15z33gdnfiqblm5515020wfdwnp2837r3hnparava6m2fgyiafiw";
};
subversion_1_10 = common {
version = "1.10.6";
sha256 = "19zc215mhpnm92mlyl5jbv57r5zqp6cavr3s2g9yglp6j4kfgj0q";

View File

@ -8,12 +8,12 @@
}:
buildPythonApplication rec {
version = "1.28.5";
version = "1.28.6";
pname = "docker-compose";
src = fetchPypi {
inherit pname version;
sha256 = "b3ff8f0352eb4055c4c483cb498aeff7c90195fa679f3caf7098a2d6fa6030e5";
sha256 = "1d44906f7ab738ba2d1785130ed31b16111eee6dc5a1dbd7252091dae48c5281";
};
# lots of networking and other fails

View File

@ -0,0 +1,26 @@
{ lib, rustPlatform, fetchFromGitHub }:
rustPlatform.buildRustPackage rec {
pname = "i3-ratiosplit";
version = "0.1.0";
src = fetchFromGitHub {
owner = "333fred";
repo = pname;
rev = "v${version}";
sha256 = "0yfmr5zk2c2il9d31yjjbr48sqgcq6hp4a99hl5mjm2ajyhy5bz3";
};
cargoSha256 = "0d5qd1wid5l1pl3ckrlfgdb980myi5gxcir39caywb9pkbnfndz6";
# Currently no tests are implemented, so we avoid building the package twice
doCheck = false;
meta = with lib; {
description = "Resize newly created windows";
homepage = "https://github.com/333fred/i3-ratiosplit";
license = licenses.mit;
maintainers = with maintainers; [ svrana ];
platforms = platforms.linux;
};
}

View File

@ -3,10 +3,10 @@
mkXfceDerivation {
category = "apps";
pname = "gigolo";
version = "0.5.1";
version = "0.5.2";
odd-unstable = false;
sha256 = "11a35z5apr26nl6fpmbsvvv3xf5w61sgzcb505plavrchpfbdxjn";
sha256 = "8UDb4H3zxRKx2y+MRsozQoR3es0fs5ooR/5wBIE11bY=";
nativeBuildInputs = [ exo ];
buildInputs = [ gtk3 glib gvfs ];

View File

@ -1,4 +1,5 @@
{ stdenv, lib
{ stdenv
, lib
, abc-verifier
, bash
, bison
@ -33,13 +34,13 @@
stdenv.mkDerivation rec {
pname = "yosys";
version = "0.9+3962";
version = "0.9+4052";
src = fetchFromGitHub {
owner = "YosysHQ";
repo = "yosys";
rev = "5d0cc54f5c36dea1d989438426a321b4554257c8";
sha256 = "1c85kga95lin6rcpr7cf80wr9f1a6irdrld9g23zmqdrxhick8y7";
rev = "687f381b6985d9dda7e11535628e2fafff267af5";
sha256 = "15lcj798ckh9zwvdqb5gnvicilsxjyxv01gcviijg310hq62n7vf";
};
enableParallelBuilding = true;

View File

@ -6,4 +6,5 @@ buildEnv {
indilib
]
++ extraDrivers;
inherit (indilib) meta;
}

View File

@ -0,0 +1,33 @@
{ lib, stdenv, fetchurl, flex }:
stdenv.mkDerivation rec {
pname = "wcslib";
version = "7.5";
src = fetchurl {
url = "ftp://ftp.atnf.csiro.au/pub/software/wcslib/${pname}-${version}.tar.bz2";
sha256 = "1536gmcpm6pckn9xrb6j8s4pm1vryjhzvhfaj9wx3jwxcpbdy0dw";
};
buildInputs = [ flex ];
prePatch = ''
substituteInPlace GNUmakefile --replace 2775 0775
substituteInPlace C/GNUmakefile --replace 2775 0775
'';
enableParallelBuilding = true;
meta = with lib; {
homepage = "https://www.atnf.csiro.au/people/mcalabre/WCS/";
description = "World Coordinate System library for astronomy";
longDescription = ''
Library for world coordinate systems for spherical geometries
and their conversion to image coordinate systems. This is the
standard library for this purpose in astronomy.
'';
maintainers = with maintainers; [ hjones2199 ];
license = licenses.lgpl3Plus;
platforms = platforms.unix;
};
}

View File

@ -1,33 +0,0 @@
{ fetchurl, lib, stdenv, flex }:
stdenv.mkDerivation rec {
version = "7.3.1";
pname = "wcslib";
buildInputs = [ flex ];
src = fetchurl {
url = "ftp://ftp.atnf.csiro.au/pub/software/wcslib/${pname}-${version}.tar.bz2";
sha256 ="0p0bp3jll9v2094a8908vk82m7j7qkjqzkngm1r9qj1v6l6j5z6c";
};
prePatch = ''
substituteInPlace GNUmakefile --replace 2775 0775
substituteInPlace C/GNUmakefile --replace 2775 0775
'';
enableParallelBuilding = true;
meta = {
description = "World Coordinate System Library for Astronomy";
homepage = "https://www.atnf.csiro.au/people/mcalabre/WCS/";
longDescription = ''Library for world coordinate systems for
spherical geometries and their conversion to image coordinate
systems. This is the standard library for this purpose in
astronomy.'';
license = lib.licenses.lgpl3Plus;
platforms = lib.platforms.unix;
};
}

View File

@ -1,17 +1,26 @@
{ lib, buildPythonPackage, fetchFromGitHub, pythonOlder
, voluptuous, aiohttp, async-timeout, python-didl-lite, defusedxml
, pytestCheckHook, pytest-asyncio }:
{ lib
, aiohttp
, async-timeout
, buildPythonPackage
, defusedxml
, fetchFromGitHub
, pytest-asyncio
, pytestCheckHook
, python-didl-lite
, pythonOlder
, voluptuous
}:
buildPythonPackage rec {
pname = "async-upnp-client";
version = "0.14.15";
version = "0.16.0";
disabled = pythonOlder "3.5";
src = fetchFromGitHub {
owner = "StevenLooman";
repo = "async_upnp_client";
rev = version;
sha256 = "1mr65msdc51wq7326z3q41x79yi9dsmcjrmyzkgj9h9vgpxdk2nw";
sha256 = "sha256-vgy/zn1Xm7Fm7u/YMe/nJa3tyRNKx/WHz0AHfhFaVKo=";
};
propagatedBuildInputs = [
@ -27,8 +36,10 @@ buildPythonPackage rec {
pytest-asyncio
];
pythonImportsCheck = [ "async_upnp_client" ];
meta = with lib; {
description = "Asyncio UPnP Client library for Python/asyncio.";
description = "Asyncio UPnP Client library for Python";
homepage = "https://github.com/StevenLooman/async_upnp_client";
license = licenses.asl20;
maintainers = with maintainers; [ hexa ];

View File

@ -0,0 +1,36 @@
{ lib
, aiohttp
, buildPythonPackage
, fetchFromGitHub
, poetry
, pythonOlder
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "freebox-api";
version = "0.0.9";
format = "pyproject";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "hacf-fr";
repo = pname;
rev = "v${version}";
sha256 = "0qn7jqfbp850aqgfsxjfv14myi6idz6sf7024p6wpqpa2xk0vfiq";
};
nativeBuildInputs = [ poetry ];
propagatedBuildInputs = [ aiohttp ];
checkInputs = [ pytestCheckHook ];
pythonImportsCheck = [ "freebox_api" ];
meta = with lib; {
description = "Python module to interact with the Freebox OS API";
homepage = "https://github.com/hacf-fr/freebox-api";
license = with licenses; [ gpl3Only ];
maintainers = with maintainers; [ fab ];
};
}

View File

@ -12,7 +12,7 @@
buildPythonPackage rec {
pname = "pyhaversion";
version = "20.12.1";
version = "21.3.0";
# Only 3.8.0 and beyond are supported
disabled = pythonOlder "3.8";
@ -21,7 +21,7 @@ buildPythonPackage rec {
owner = "ludeeus";
repo = pname;
rev = version;
sha256 = "17yl67dgw75dghljcfwzblm11kqnh6sxf47w62mxz86aq9zrvcxd";
sha256 = "sha256-2vW4BN5qwJZYQ8FU3bpSA2v1dX6TOhcHDbHRMDPoRAs=";
};
propagatedBuildInputs = [
@ -32,7 +32,6 @@ buildPythonPackage rec {
checkInputs = [
aresponses
awesomeversion
pytest-asyncio
pytestCheckHook
];

View File

@ -3,28 +3,35 @@
, buildPythonPackage
, fetchFromGitHub
, httpx
, pytest-asyncio
, pytestCheckHook
, pythonOlder
, pytz
}:
buildPythonPackage rec {
pname = "pylitterbot";
version = "2021.2.5";
version = "2021.3.1";
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "natekspencer";
repo = pname;
rev = version;
sha256 = "0705bxm0rlpgwg8my7z5pp6y362bs2j53zy1yslha0ya6cgx37g8";
sha256 = "sha256-w2iyzCYoma8zQsXGIQnpgijDHNqmlvCnbeyF7PmLz9c=";
};
propagatedBuildInputs = [
authlib
httpx
pytz
];
checkInputs = [
pytest-asyncio
pytestCheckHook
];
# Project has no tests
doCheck = false;
pythonImportsCheck = [ "pylitterbot" ];
meta = with lib; {

View File

@ -1,17 +1,21 @@
{ lib, buildPythonPackage, fetchFromGitHub, pythonOlder
{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, defusedxml
, pytest }:
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "python-didl-lite";
version = "1.2.5";
version = "1.2.6";
disabled = pythonOlder "3.5.3";
src = fetchFromGitHub {
owner = "StevenLooman";
repo = pname;
rev = version;
sha256 = "0wm831g8k9xahw20y0461cvy6lp45sxppicxah1rg9isdc3vy3nh";
sha256 = "sha256-1rr26dnV5As15HeFLWEDBDYPiRDHkGfYOYFhSJi7iyU=";
};
propagatedBuildInputs = [
@ -19,12 +23,10 @@ buildPythonPackage rec {
];
checkInputs = [
pytest
pytestCheckHook
];
checkPhase = ''
py.test
'';
pythonImportsCheck = [ "didl_lite" ];
meta = with lib; {
description = "DIDL-Lite (Digital Item Declaration Language) tools for Python";

View File

@ -11,14 +11,14 @@
buildPythonPackage rec {
pname = "xknx";
version = "0.17.4";
version = "0.17.5";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "XKNX";
repo = pname;
rev = version;
sha256 = "sha256-QMtpGd7JFPGTLHbhyjOsan1Ow32v8B2ss84GpHA0qqs=";
sha256 = "sha256-oLm1Bh58mKwbQf9FloqEnypzANikxgdFpAB99h/Mb9U=";
};
propagatedBuildInputs = [

View File

@ -0,0 +1,46 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, lxml
, poetry-core
, pythonOlder
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "xpath-expressions";
version = "1.1.0";
disabled = pythonOlder "3.5";
format = "pyproject";
src = fetchFromGitHub {
owner = "orf";
repo = pname;
rev = "v${version}";
sha256 = "0l289iw2zmzxyfi3g2z7b917vmsaz47h5jp871zvykpmpigc632h";
};
nativeBuildInputs = [
poetry-core
];
checkInputs = [
lxml
pytestCheckHook
];
postPatch = ''
# Was fixed upstream but not released
substituteInPlace pyproject.toml \
--replace "poetry.masonry.api" "poetry.core.masonry.api"
'';
pythonImportsCheck = [ "xpath" ];
meta = with lib; {
description = "Python module to handle XPath expressions";
homepage = "https://github.com/orf/xpath-expressions";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}

View File

@ -0,0 +1,30 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "yaswfp";
version = "unstable-20210331";
src = fetchFromGitHub {
owner = "facundobatista";
repo = pname;
rev = "2a2cc6ca4c0b4d52bd2e658fb5f80fdc0db4924c";
sha256 = "1dxdz89hlycy1rnn269fwl1f0qxgxqarkc0ivs2m77f8xba2qgj9";
};
checkInputs = [
pytestCheckHook
];
pythonImportsCheck = [ "yaswfp" ];
meta = with lib; {
description = "Python SWF Parser";
homepage = "https://github.com/facundobatista/yaswfp";
license = with licenses; [ gpl3Only ];
maintainers = with maintainers; [ fab ];
};
}

View File

@ -1,7 +1,8 @@
{ lib, fetchFromGitHub, buildGoModule }:
{ lib, fetchFromGitHub, buildGoModule
, enableUnfree ? true }:
buildGoModule rec {
name = "drone.io-${version}";
pname = "drone.io${lib.optionalString (!enableUnfree) "-oss"}";
version = "1.10.0";
vendorSha256 = "sha256-cKHX/GnvGELQBfoo0/1UmDQ4Z66GGnnHG7+1CzjinL0=";
@ -15,9 +16,13 @@ buildGoModule rec {
sha256 = "sha256-12Jac+mXWdUX8gWvmpdO9ROv7Bi0YzvyqnNDVNJOr34=";
};
preBuild = ''
buildFlagsArray+=( "-tags" "${lib.optionalString (!enableUnfree) "oss nolimit"}" )
'';
meta = with lib; {
maintainers = with maintainers; [ elohmeier vdemeester ];
license = licenses.asl20;
license = with licenses; if enableUnfree then unfreeRedistributable else asl20;
description = "Continuous Integration platform built on container technology";
};
}

View File

@ -1,7 +1,7 @@
{ lib, buildGoPackage, fetchFromGitHub, installShellFiles }:
buildGoPackage rec {
pname = "packer";
version = "1.7.0";
version = "1.7.1";
goPackagePath = "github.com/hashicorp/packer";
@ -11,7 +11,7 @@ buildGoPackage rec {
owner = "hashicorp";
repo = "packer";
rev = "v${version}";
sha256 = "sha256-x62C44vTIysk9Lx9HZeTBf8k1+P5hfMIijvTWu3cZrA=";
sha256 = "sha256-PZwKvb43Xf8HaC148Xo076u3sP53nwC4fJ2X7HU0gDo=";
};
buildFlagsArray = [ "-ldflags=-s -w" ];

View File

@ -0,0 +1,24 @@
{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule rec {
pname = "protoc-gen-go";
version = "1.26.0";
src = fetchFromGitHub {
owner = "protocolbuffers";
repo = "protobuf-go";
rev = "v${version}";
sha256 = "sha256-n2LHI8DXQFFWhTPOFCegBgwi/0tFvRE226AZfRW8Bnc=";
};
vendorSha256 = "sha256-yb8l4ooZwqfvenlxDRg95rqiL+hmsn0weS/dPv/oD2Y=";
subPackages = [ "cmd/protoc-gen-go" ];
meta = with lib; {
description = "Go support for Google's protocol buffers";
homepage = "https://google.golang.org/protobuf";
license = licenses.bsd3;
maintainers = with maintainers; [ jojosch ];
};
}

View File

@ -0,0 +1,27 @@
{ lib, buildGoPackage, fetchFromGitHub }:
buildGoPackage rec {
pname = "protoc-gen-twirp";
version = "7.1.1";
src = fetchFromGitHub {
owner = "twitchtv";
repo = "twirp";
rev = "v${version}";
sha256 = "sha256-GN7akAp0zzS8wVhgXlT1ceFUFKH4Sz74XQ8ofIE8T/k=";
};
goPackagePath = "github.com/twitchtv/twirp";
subPackages = [
"protoc-gen-twirp"
"protoc-gen-twirp_python"
];
meta = with lib; {
description = "A simple RPC framework with protobuf service definitions";
homepage = "https://github.com/twitchtv/twirp";
license = licenses.asl20;
maintainers = with maintainers; [ jojosch ];
};
}

View File

@ -0,0 +1,28 @@
{ lib, buildGoModule, fetchgit }:
buildGoModule rec {
pname = "protoc-gen-twirp_php";
version = "0.6.0";
# fetchFromGitHub currently not possible, because go.mod and go.sum are export-ignored
src = fetchgit {
url = "https://github.com/twirphp/twirp.git";
rev = "v${version}";
sha256 = "sha256-WnvCdAJIMA4A+f7H61qcVbKNn23bNVOC15vMCEKc+CI=";
};
vendorSha256 = "sha256-LIMxrWXlK7+JIRmtukdXPqfw8H991FCAOuyEf7ZLSTs=";
subPackages = [ "protoc-gen-twirp_php" ];
preBuild = ''
go generate ./...
'';
meta = with lib; {
description = "PHP port of Twitch's Twirp RPC framework";
homepage = "https://github.com/twirphp/twirp";
license = licenses.mit;
maintainers = with maintainers; [ jojosch ];
};
}

View File

@ -0,0 +1,24 @@
{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule {
pname = "protoc-gen-twirp_swagger";
version = "unstable-2021-03-29";
src = fetchFromGitHub {
owner = "elliots";
repo = "protoc-gen-twirp_swagger";
rev = "f21ef47d69e37c1602a7fb26146de05c092d30b6";
sha256 = "sha256-uHU15NbHK7SYgNS3VK21H/OqDo/JyyTZdXw3i9lsgLY=";
};
vendorSha256 = "sha256-g0+9l83Fc0XPzsZAKjLBrjD+tv2+Fot57hcilqAhOZk=";
subPackages = [ "." ];
meta = with lib; {
description = "Swagger generator for twirp";
homepage = "https://github.com/elliots/protoc-gen-twirp_swagger";
license = licenses.bsd3;
maintainers = with maintainers; [ jojosch ];
};
}

View File

@ -0,0 +1,24 @@
{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule {
pname = "protoc-gen-twirp_typescript";
version = "unstable-2021-03-29";
src = fetchFromGitHub {
owner = "larrymyers";
repo = "protoc-gen-twirp_typescript";
rev = "97fd63e543beb2d9f6a90ff894981affe0f2faf1";
sha256 = "sha256-LfF/n96LwRX8aoPHzCRI/QbDmZR9yMhE5yGhFAqa8nA=";
};
vendorSha256 = "sha256-WISWuq1neVX4xQkoamc6FznZahOQHwgkYmERJF40OFQ=";
subPackages = [ "." ];
meta = with lib; {
description = "Protobuf Plugin for Generating a Twirp Typescript Client";
homepage = "https://github.com/larrymyers/protoc-gen-twirp_typescript";
license = licenses.mit;
maintainers = with maintainers; [ jojosch ];
};
}

View File

@ -0,0 +1,342 @@
From dc7156d8951242231cfd9142b3d5628815dc6589 Mon Sep 17 00:00:00 2001
From: Maximilian Bosch <maximilian@mbosch.me>
Date: Wed, 31 Mar 2021 14:30:01 +0200
Subject: [PATCH] Revert "Merge pull request #12225 from
chrisroberts/resolution-isolation"
This reverts commit 8a69d0c4dae035a4b1aa789bc4ec3db69c210df2, reversing
changes made to 5dd0a8c8acc36b654c13a5102e4327eedf1858f2.
-----
Rationale: NixOS-specific patch. The changes in here break our current
implementation of declarative plugins (only `vagrant-libvirt` atm).
---
bin/vagrant | 28 +--------------
lib/vagrant.rb | 2 +-
lib/vagrant/bundler.rb | 17 +++------
lib/vagrant/errors.rb | 12 -------
lib/vagrant/plugin/manager.rb | 22 ++----------
templates/locales/en.yml | 23 ++----------
test/unit/bin/vagrant_test.rb | 1 -
test/unit/vagrant/bundler_test.rb | 58 ++++++++++++++-----------------
8 files changed, 39 insertions(+), 124 deletions(-)
diff --git a/bin/vagrant b/bin/vagrant
index c019f30ff..ba7e40076 100755
--- a/bin/vagrant
+++ b/bin/vagrant
@@ -23,9 +23,9 @@ if idx = argv.index("--")
argv = argv.slice(0, idx)
end
-require_relative "../lib/vagrant/version"
# Fast path the version of Vagrant
if argv.include?("-v") || argv.include?("--version")
+ require_relative "../lib/vagrant/version"
puts "Vagrant #{Vagrant::VERSION}"
exit 0
end
@@ -82,29 +82,6 @@ end
$stdout.sync = true
$stderr.sync = true
-# Before we start activate all our dependencies
-# so we can provide correct resolutions later
-builtin_specs = []
-
-vagrant_spec = Gem::Specification.find_all_by_name("vagrant").detect do |spec|
- spec.version == Gem::Version.new(Vagrant::VERSION)
-end
-
-dep_activator = proc do |spec|
- spec.runtime_dependencies.each do |dep|
- gem(dep.name, *dep.requirement.as_list)
- dep_spec = Gem::Specification.find_all_by_name(dep.name).detect(&:activated?)
- if dep_spec
- builtin_specs << dep_spec
- dep_activator.call(dep_spec)
- end
- end
-end
-
-if vagrant_spec
- dep_activator.call(vagrant_spec)
-end
-
env = nil
begin
require 'log4r'
@@ -114,9 +91,6 @@ begin
require 'vagrant/util/platform'
require 'vagrant/util/experimental'
- # Set our list of builtin specs
- Vagrant::Bundler.instance.builtin_specs = builtin_specs
-
# Schedule the cleanup of things
at_exit(&Vagrant::Bundler.instance.method(:deinit))
diff --git a/lib/vagrant.rb b/lib/vagrant.rb
index f3dcba0bc..d696bdff8 100644
--- a/lib/vagrant.rb
+++ b/lib/vagrant.rb
@@ -81,7 +81,7 @@ if ENV["VAGRANT_LOG"] && ENV["VAGRANT_LOG"] != ""
# See https://github.com/rest-client/rest-client/issues/34#issuecomment-290858
# for more information
class VagrantLogger < Log4r::Logger
- def << msg
+ def << (msg)
debug(msg.strip)
end
end
diff --git a/lib/vagrant/bundler.rb b/lib/vagrant/bundler.rb
index eb2caabb0..d75f54362 100644
--- a/lib/vagrant/bundler.rb
+++ b/lib/vagrant/bundler.rb
@@ -189,11 +189,8 @@ module Vagrant
attr_reader :env_plugin_gem_path
# @return [Pathname] Vagrant environment data path
attr_reader :environment_data_path
- # @return [Array<Gem::Specification>, nil] List of builtin specs
- attr_accessor :builtin_specs
def initialize
- @builtin_specs = []
@plugin_gem_path = Vagrant.user_data_path.join("gems", RUBY_VERSION).freeze
@logger = Log4r::Logger.new("vagrant::bundler")
end
@@ -290,6 +287,7 @@ module Vagrant
# Never allow dependencies to be remotely satisfied during init
request_set.remote = false
+ repair_result = nil
begin
@logger.debug("resolving solution from available specification set")
# Resolve the request set to ensure proper activation order
@@ -652,6 +650,7 @@ module Vagrant
self_spec.activate
@logger.info("Activated vagrant specification version - #{self_spec.version}")
end
+ self_spec.runtime_dependencies.each { |d| gem d.name, *d.requirement.as_list }
# discover all the gems we have available
list = {}
if Gem.respond_to?(:default_specifications_dir)
@@ -660,16 +659,10 @@ module Vagrant
spec_dir = Gem::Specification.default_specifications_dir
end
directories = [spec_dir]
- if Vagrant.in_bundler?
- Gem::Specification.find_all{true}.each do |spec|
- list[spec.full_name] = spec
- end
- else
- builtin_specs.each do |spec|
- list[spec.full_name] = spec
- end
+ Gem::Specification.find_all{true}.each do |spec|
+ list[spec.full_name] = spec
end
- if Vagrant.in_installer?
+ if(!Object.const_defined?(:Bundler))
directories += Gem::Specification.dirs.find_all do |path|
!path.start_with?(Gem.user_dir)
end
diff --git a/lib/vagrant/errors.rb b/lib/vagrant/errors.rb
index 5cb861c06..782615bc4 100644
--- a/lib/vagrant/errors.rb
+++ b/lib/vagrant/errors.rb
@@ -636,18 +636,6 @@ module Vagrant
error_key(:provisioner_winrm_unsupported)
end
- class PluginNeedsDeveloperTools < VagrantError
- error_key(:plugin_needs_developer_tools)
- end
-
- class PluginMissingLibrary < VagrantError
- error_key(:plugin_missing_library)
- end
-
- class PluginMissingRubyDev < VagrantError
- error_key(:plugin_missing_ruby_dev)
- end
-
class PluginGemNotFound < VagrantError
error_key(:plugin_gem_not_found)
end
diff --git a/lib/vagrant/plugin/manager.rb b/lib/vagrant/plugin/manager.rb
index b73f07f9c..9058e68b3 100644
--- a/lib/vagrant/plugin/manager.rb
+++ b/lib/vagrant/plugin/manager.rb
@@ -179,26 +179,8 @@ module Vagrant
result
rescue Gem::GemNotFoundException
raise Errors::PluginGemNotFound, name: name
- rescue Gem::Exception => err
- @logger.warn("Failed to install plugin: #{err}")
- @logger.debug("#{err.class}: #{err}\n#{err.backtrace.join("\n")}")
- # Try and determine a cause for the failure
- case err.message
- when /install development tools first/
- raise Errors::PluginNeedsDeveloperTools
- when /library not found in default locations/
- lib = err.message.match(/(\w+) library not found in default locations/)
- if lib.nil?
- raise Errors::BundlerError, message: err.message
- end
- raise Errors::PluginMissingLibrary,
- library: lib.captures.first,
- name: name
- when /find header files for ruby/
- raise Errors::PluginMissingRubyDev
- else
- raise Errors::BundlerError, message: err.message
- end
+ rescue Gem::Exception => e
+ raise Errors::BundlerError, message: e.to_s
end
# Uninstalls the plugin with the given name.
diff --git a/templates/locales/en.yml b/templates/locales/en.yml
index edae9b477..782904f49 100644
--- a/templates/locales/en.yml
+++ b/templates/locales/en.yml
@@ -794,9 +794,9 @@ en:
matching this provider. For example, if you're using VirtualBox,
the clone environment must also be using VirtualBox.
cloud_init_not_found: |-
- cloud-init is not found. Please ensure that cloud-init is installed and
+ cloud-init is not found. Please ensure that cloud-init is installed and
available on path for guest '%{guest_name}'.
- cloud_init_command_failed: |-
+ cloud_init_command_failed: |-
cloud init command '%{cmd}' failed on guest '%{guest_name}'.
command_deprecated: |-
The command 'vagrant %{name}' has been deprecated and is no longer functional
@@ -1238,23 +1238,6 @@ en:
following command:
vagrant plugin install --local
- plugin_needs_developer_tools: |-
- Vagrant failed to install the requested plugin because development tools
- are required for installation but are not currently installed on this
- machine. Please install development tools and then try this command
- again.
- plugin_missing_library: |-
- Vagrant failed to install the requested plugin because it depends
- on a library which is not currently installed on this system. The
- following library is required by the '%{name}' plugin:
-
- %{library}
-
- Please install the library and then run the command again.
- plugin_missing_ruby_dev: |-
- Vagrant failed to install the requested plugin because the Ruby header
- files could not be found. Install the ruby development package for your
- system and then run this command again.
powershell_not_found: |-
Failed to locate the powershell executable on the available PATH. Please
ensure powershell is installed and available on the local PATH, then
@@ -3015,7 +2998,7 @@ en:
pushes:
file:
no_destination: "File destination must be specified."
-
+
autocomplete:
installed: |-
Autocomplete installed at paths:
diff --git a/test/unit/bin/vagrant_test.rb b/test/unit/bin/vagrant_test.rb
index dbbd52112..bc11309aa 100644
--- a/test/unit/bin/vagrant_test.rb
+++ b/test/unit/bin/vagrant_test.rb
@@ -30,7 +30,6 @@ describe "vagrant bin" do
allow(Kernel).to receive(:exit)
allow(Vagrant::Environment).to receive(:new).and_return(env)
allow(Vagrant).to receive(:in_installer?).and_return(true)
- allow(self).to receive(:require_relative)
end
after { expect(run_vagrant).to eq(exit_code) }
diff --git a/test/unit/vagrant/bundler_test.rb b/test/unit/vagrant/bundler_test.rb
index 69f425c66..00cedc021 100644
--- a/test/unit/vagrant/bundler_test.rb
+++ b/test/unit/vagrant/bundler_test.rb
@@ -778,46 +778,42 @@ describe Vagrant::Bundler do
end
end
- context "when bundler is not defined" do
- before { expect(Vagrant).to receive(:in_bundler?).and_return(false) }
+ context "when run time dependencies are defined" do
+ let(:vagrant_dep_specs) { [double("spec", name: "vagrant-dep", requirement: double("spec-req", as_list: []))] }
- context "when running inside the installer" do
- before { expect(Vagrant).to receive(:in_installer?).and_return(true) }
+ it "should call #gem to activate the dependencies" do
+ expect(subject).to receive(:gem).with("vagrant-dep", any_args)
+ subject.send(:vagrant_internal_specs)
+ end
+ end
- it "should load gem specification directories" do
- expect(Gem::Specification).to receive(:dirs).and_return(spec_dirs)
- subject.send(:vagrant_internal_specs)
- end
+ context "when bundler is not defined" do
+ before { expect(Object).to receive(:const_defined?).with(:Bundler).and_return(false) }
- context "when checking paths" do
- let(:spec_dirs) { [double("spec-dir", start_with?: in_user_dir)] }
- let(:in_user_dir) { true }
- let(:user_dir) { double("user-dir") }
+ it "should load gem specification directories" do
+ expect(Gem::Specification).to receive(:dirs).and_return(spec_dirs)
+ subject.send(:vagrant_internal_specs)
+ end
- before { allow(Gem).to receive(:user_dir).and_return(user_dir) }
+ context "when checking paths" do
+ let(:spec_dirs) { [double("spec-dir", start_with?: in_user_dir)] }
+ let(:in_user_dir) { true }
+ let(:user_dir) { double("user-dir") }
- it "should check if path is within local user directory" do
- expect(spec_dirs.first).to receive(:start_with?).with(user_dir).and_return(false)
- subject.send(:vagrant_internal_specs)
- end
-
- context "when path is not within user directory" do
- let(:in_user_dir) { false }
+ before { allow(Gem).to receive(:user_dir).and_return(user_dir) }
- it "should use path when loading specs" do
- expect(Gem::Specification).to receive(:each_spec) { |arg| expect(arg).to include(spec_dirs.first) }
- subject.send(:vagrant_internal_specs)
- end
- end
+ it "should check if path is within local user directory" do
+ expect(spec_dirs.first).to receive(:start_with?).with(user_dir).and_return(false)
+ subject.send(:vagrant_internal_specs)
end
- end
- context "when running outside the installer" do
- before { expect(Vagrant).to receive(:in_installer?).and_return(false) }
+ context "when path is not within user directory" do
+ let(:in_user_dir) { false }
- it "should not load gem specification directories" do
- expect(Gem::Specification).not_to receive(:dirs)
- subject.send(:vagrant_internal_specs)
+ it "should use path when loading specs" do
+ expect(Gem::Specification).to receive(:each_spec) { |arg| expect(arg).to include(spec_dirs.first) }
+ subject.send(:vagrant_internal_specs)
+ end
end
end
end
--
2.29.3

View File

@ -5,9 +5,9 @@
let
# NOTE: bumping the version and updating the hash is insufficient;
# you must use bundix to generate a new gemset.nix in the Vagrant source.
version = "2.2.14";
version = "2.2.15";
url = "https://github.com/hashicorp/vagrant/archive/v${version}.tar.gz";
sha256 = "sha256-vsb7RFjT9l4N6BzwIvVLcRtA4n/c8jk20B6RUMkyhJs=";
sha256 = "sha256-mMnHJtXLfkZ5O0UF89kHsqBnPg9uQ5l8IYoL5TMMyD8=";
deps = bundlerEnv rec {
name = "${pname}-${version}";
@ -54,6 +54,7 @@ in buildRubyGem rec {
./unofficial-installation-nowarn.patch
./use-system-bundler-version.patch
./0004-Support-system-installed-plugins.patch
./0001-Revert-Merge-pull-request-12225-from-chrisroberts-re.patch
];
postPatch = ''

View File

@ -4,10 +4,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "02vssr285m7kpsr47jdmzbar1h1d0mnkmyrpr1zg828isfmwii35";
sha256 = "0ndamfaivnkhc6hy0yqyk2gkwr6f3bz6216lh74hsiiyk3axz445";
type = "gem";
};
version = "1.0.1";
version = "1.1.0";
};
builder = {
groups = ["default"];
@ -34,10 +34,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1vnxrbhi7cq3p4y2v9iwd10v1c7l15is4var14hwnb2jip4fyjzz";
sha256 = "0mr23wq0szj52xnj0zcn1k0c7j4v79wlwbijkpfcscqww3l6jlg3";
type = "gem";
};
version = "1.1.7";
version = "1.1.8";
};
ed25519 = {
groups = ["default"];
@ -64,20 +64,20 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1hi89v53pm2abfv9j8lgqdd7hgkr7fr0gwrczr940iwbb3xv7rrs";
sha256 = "1759s0rz6qgsw86dds1z4jzb3fvizqsk11j5q6z7lc5n404w6i23";
type = "gem";
};
version = "0.78.0";
version = "0.79.0";
};
ffi = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "12lpwaw82bb0rm9f52v1498bpba8aj2l2q359mkwbxsswhpga5af";
sha256 = "0nq1fb3vbfylccwba64zblxy96qznxbys5900wd7gm9bpplmf432";
type = "gem";
};
version = "1.13.1";
version = "1.15.0";
};
gssapi = {
dependencies = ["ffi"];
@ -85,10 +85,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "13l6pqbfrx3vv7cw26nq9p8rnyp9br31gaz85q32wx6hnzfcriwh";
sha256 = "1qdfhj12aq8v0y961v4xv96a1y2z80h3xhvzrs9vsfgf884g6765";
type = "gem";
};
version = "1.3.0";
version = "1.3.1";
};
gyoku = {
dependencies = ["builder"];
@ -127,10 +127,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "153sx77p16vawrs4qpkv7qlzf9v5fks4g7xqcj1dwk40i6g7rfzk";
sha256 = "0g2fnag935zn2ggm5cn6k4s4xvv53v2givj1j90szmvavlpya96a";
type = "gem";
};
version = "1.8.5";
version = "1.8.10";
};
listen = {
dependencies = ["rb-fsevent" "rb-inotify"];
@ -138,10 +138,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0028p1fss6pvw4mlpjqdmxfzsm8ww79irsadbibrr7f23qfn8ykr";
sha256 = "0h2v34xhi30w0d9gfzds2w6v89grq2gkpgvmdj9m8x1ld1845xnj";
type = "gem";
};
version = "3.3.1";
version = "3.5.1";
};
little-plugger = {
groups = ["default"];
@ -190,10 +190,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0ipjyfwn9nlvpcl8knq3jk4g5f12cflwdbaiqxcq1s7vwfwfxcag";
sha256 = "1phcq7z0zpipwd7y4fbqmlaqghv07fjjgrx99mwq3z3n0yvy7fmi";
type = "gem";
};
version = "3.2020.1104";
version = "3.2021.0225";
};
multi_json = {
groups = ["default"];
@ -232,10 +232,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1hlyp6z3ffwdcnzq9khrkz6waxggn4hnzsczbp3mz61lhx4qiri3";
sha256 = "0jp3jgcn8cij407xx9ldb5h9c6jv13jc4cf6kk2idclz43ww21c9";
type = "gem";
};
version = "6.2.0.rc1";
version = "6.1.0";
};
nori = {
groups = ["default"];
@ -279,25 +279,15 @@
};
version = "0.2.5";
};
ruby_dep = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0v0qznxz999lx4vs76mr590r90i0cm5m76wwvgis7sq4y21l308l";
type = "gem";
};
version = "1.3.1";
};
rubyntlm = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1p6bxsklkbcqni4bcq6jajc2n57g0w5rzn4r49c3lb04wz5xg0dy";
sha256 = "0b8hczk8hysv53ncsqzx4q6kma5gy5lqc7s5yx8h64x3vdb18cjv";
type = "gem";
};
version = "0.6.2";
version = "0.6.3";
};
rubyzip = {
groups = ["default"];
@ -315,10 +305,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0b3b9ybd6mskfz2vffb6li2y6njdc9xqhik9c4mvzq9dchxpbxlj";
sha256 = "1rwfw014fbvaxshf8abi87srfaiirb7cr93s61qm177jm8q86h57";
type = "gem";
};
version = "3.0.2";
version = "3.0.4";
};
wdm = {
groups = ["default"];
@ -336,10 +326,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0k9i86v805gpya3pyqahjykljbdwpjsrk7hsdqrl05j2rpidvk4v";
sha256 = "0nxf6a47d1xf1nvi7rbfbzjyyjhz0iakrnrsr2hj6y24a381sd8i";
type = "gem";
};
version = "2.3.5";
version = "2.3.6";
};
winrm-elevated = {
dependencies = ["erubi" "winrm" "winrm-fs"];

View File

@ -14,10 +14,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1hi89v53pm2abfv9j8lgqdd7hgkr7fr0gwrczr940iwbb3xv7rrs";
sha256 = "1759s0rz6qgsw86dds1z4jzb3fvizqsk11j5q6z7lc5n404w6i23";
type = "gem";
};
version = "0.78.0";
version = "0.79.0";
};
fog-core = {
dependencies = ["builder" "excon" "formatador" "mime-types"];
@ -47,10 +47,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0by97bx0szdz47kdy0fqvx6j2kzy5yhrwbvvsfbh27dm9c0vfwgr";
sha256 = "1s62ihwxlwgp84xw32wg6hwcx4422v20c7g7azd0xslb91y1ln1r";
type = "gem";
};
version = "0.7.0";
version = "0.8.0";
};
fog-xml = {
dependencies = ["fog-core" "nokogiri"];
@ -78,10 +78,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "158fawfwmv2sq4whqqaksfykkiad2xxrrj0nmpnc6vnlzi1bp7iz";
sha256 = "0lrirj0gw420kw71bjjlqkqhqbrplla61gbv1jzgsz6bv90qr3ci";
type = "gem";
};
version = "2.3.1";
version = "2.5.1";
};
mime-types = {
dependencies = ["mime-types-data"];
@ -99,20 +99,20 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0ipjyfwn9nlvpcl8knq3jk4g5f12cflwdbaiqxcq1s7vwfwfxcag";
sha256 = "1phcq7z0zpipwd7y4fbqmlaqghv07fjjgrx99mwq3z3n0yvy7fmi";
type = "gem";
};
version = "3.2020.1104";
version = "3.2021.0225";
};
mini_portile2 = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy";
sha256 = "1hdbpmamx8js53yk3h8cqy12kgv6ca06k0c9n3pxh6b6cjfs19x7";
type = "gem";
};
version = "2.4.0";
version = "2.5.0";
};
multi_json = {
groups = ["default"];
@ -125,15 +125,25 @@
version = "1.15.0";
};
nokogiri = {
dependencies = ["mini_portile2"];
dependencies = ["mini_portile2" "racc"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0xmf60nj5kg9vaj5bysy308687sgmkasgx06vbbnf94p52ih7si2";
sha256 = "0b51df8fwadak075cvi17w0nch6qz1r66564qp29qwfj67j9qp0p";
type = "gem";
};
version = "1.10.10";
version = "1.11.2";
};
racc = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "178k7r0xn689spviqzhvazzvxfq6fyjldxb3ywjbgipbfi4s8j1g";
type = "gem";
};
version = "1.5.2";
};
ruby-libvirt = {
groups = ["default"];
@ -151,9 +161,9 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1b1m8fg1rin6ps15ykqhwz6qm7isadb83r22b733dkw2gvvj91jv";
sha256 = "07j30w23syvzrhznad9dkh1ks4lzxzi7ak2966b7i7wr4kz8x1hp";
type = "gem";
};
version = "0.2.1";
version = "0.4.0";
};
}

View File

@ -0,0 +1,53 @@
{ stdenv, lib, fetchFromGitHub, fetchpatch, kernel, kernelAtLeast }:
stdenv.mkDerivation rec {
name = "isgx-${version}-${kernel.version}";
version = "2.11";
src = fetchFromGitHub {
owner = "intel";
repo = "linux-sgx-driver";
rev = "sgx_driver_${version}";
hash = "sha256-zZ0FgCx63LCNmvQ909O27v/o4+93gefhgEE/oDr/bHw=";
};
patches = [
# Fixes build with kernel >= 5.8
(fetchpatch {
url = "https://github.com/intel/linux-sgx-driver/commit/276c5c6a064d22358542f5e0aa96b1c0ace5d695.patch";
sha256 = "sha256-PmchqYENIbnJ51G/tkdap/g20LUrJEoQ4rDtqy6hj24=";
})
];
hardeningDisable = [ "pic" ];
nativeBuildInputs = kernel.moduleBuildDependencies;
makeFlags = [
"KDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
];
installPhase = ''
runHook preInstall
install -D isgx.ko -t $out/lib/modules/${kernel.modDirVersion}/kernel/drivers/intel/sgx
runHook postInstall
'';
meta = with lib; {
description = "Intel SGX Linux Driver";
longDescription = ''
The linux-sgx-driver project (isgx) hosts an out-of-tree driver
for the Linux* Intel(R) SGX software stack, which would be used
until the driver upstreaming process is complete (before 5.11.0).
It is used to support Enhanced Privacy Identification (EPID)
based attestation on the platforms without Flexible Launch Control.
'';
homepage = "https://github.com/intel/linux-sgx-driver";
license = with licenses; [ bsd3 /* OR */ gpl2Only ];
maintainers = with maintainers; [ oxalica ];
platforms = platforms.linux;
# The driver is already in kernel >= 5.11.0.
broken = kernelAtLeast "5.11.0";
};
}

View File

@ -20,16 +20,20 @@ stdenv.mkDerivation rec {
makeFlags = [
"PREFIX=${placeholder "out"}"
"ETCDIR=${placeholder "out"}/etc"
"CC=${stdenv.cc.targetPrefix}cc"
"AR=${stdenv.cc.targetPrefix}ar"
] ++ lib.optional sensord "PROG_EXTRA=sensord";
installFlags = [
"ETCDIR=${placeholder "out"}/etc"
];
meta = with lib; {
homepage = "https://hwmon.wiki.kernel.org/lm_sensors";
changelog = "https://raw.githubusercontent.com/lm-sensors/lm-sensors/V${dashedVersion}/CHANGES";
description = "Tools for reading hardware sensors";
license = with licenses; [ lgpl21Plus gpl2Plus ];
maintainers = with maintainers; [ pengmeiyu ];
platforms = platforms.linux;
};
}

View File

@ -0,0 +1,14 @@
diff --git a/cps/__init__.py b/cps/__init__.py
index 627cca0b..233bb2dd 100644
--- a/cps/__init__.py
+++ b/cps/__init__.py
@@ -87,6 +87,9 @@ db.CalibreDB.setup_db(config, cli.settingspath)
calibre_db = db.CalibreDB()
+if os.environ.get('__RUN_MIGRATIONS_AND_EXIT'):
+ sys.exit(0)
+
def create_app():
app.wsgi_app = ReverseProxied(app.wsgi_app)
# For python2 convert path to unicode

View File

@ -0,0 +1,17 @@
diff --git a/cps/logger.py b/cps/logger.py
index b204de31..3206e2bf 100644
--- a/cps/logger.py
+++ b/cps/logger.py
@@ -32,10 +32,10 @@ ACCESS_FORMATTER_TORNADO = Formatter("[%(asctime)s] %(message)s")
FORMATTER = Formatter("[%(asctime)s] %(levelname)5s {%(name)s:%(lineno)d} %(message)s")
DEFAULT_LOG_LEVEL = logging.INFO
-DEFAULT_LOG_FILE = os.path.join(_CONFIG_DIR, "calibre-web.log")
-DEFAULT_ACCESS_LOG = os.path.join(_CONFIG_DIR, "access.log")
LOG_TO_STDERR = '/dev/stderr'
LOG_TO_STDOUT = '/dev/stdout'
+DEFAULT_LOG_FILE = LOG_TO_STDOUT
+DEFAULT_ACCESS_LOG = LOG_TO_STDOUT
logging.addLevelName(logging.WARNING, "WARN")
logging.addLevelName(logging.CRITICAL, "CRIT")

View File

@ -0,0 +1,72 @@
{ lib
, fetchFromGitHub
, nixosTests
, python3
, python3Packages
}:
python3.pkgs.buildPythonApplication rec {
pname = "calibre-web";
version = "0.6.11";
src = fetchFromGitHub {
owner = "janeczku";
repo = "calibre-web";
rev = version;
sha256 = "10sjllhhcamswpa1wlim4mbm2zl4g804bwly5p4nmklg7n1v226g";
};
prePatch = ''
substituteInPlace setup.cfg \
--replace "requests>=2.11.1,<2.25.0" "requests>=2.11.1,<2.26.0" \
--replace "cps = calibreweb:main" "calibre-web = calibreweb:main"
'';
patches = [
# default-logger.patch switches default logger to /dev/stdout. Otherwise calibre-web tries to open a file relative
# to its location, which can't be done as the store is read-only. Log file location can later be configured using UI
# if needed.
./default-logger.patch
# DB migrations adds an env var __RUN_MIGRATIONS_ANDEXIT that, when set, instructs calibre-web to run DB migrations
# and exit. This is gonna be used to configure calibre-web declaratively, as most of its configuration parameters
# are stored in the DB.
./db-migrations.patch
];
# calibre-web doesn't follow setuptools directory structure. The following is taken from the script
# that calibre-web's maintainer is using to package it:
# https://github.com/OzzieIsaacs/calibre-web-test/blob/master/build/make_release.py
postPatch = ''
mkdir -p src/calibreweb
mv cps.py src/calibreweb/__init__.py
mv cps src/calibreweb
'';
# Upstream repo doesn't provide any tests.
doCheck = false;
propagatedBuildInputs = with python3Packages; [
backports_abc
flask-babel
flask_login
flask_principal
iso-639
pypdf2
requests
singledispatch
sqlalchemy
tornado
unidecode
Wand
];
passthru.tests.calibre-web = nixosTests.calibre-web;
meta = with lib; {
description = "Web app for browsing, reading and downloading eBooks stored in a Calibre database";
maintainers = with maintainers; [ pborzenkov ];
homepage = "https://github.com/janeczku/calibre-web";
license = licenses.gpl3Plus;
platforms = platforms.all;
};
}

View File

@ -9,7 +9,7 @@
stdenv.mkDerivation rec {
pname = "slurm";
version = "20.11.4.1";
version = "20.11.5.1";
# N.B. We use github release tags instead of https://www.schedmd.com/downloads.php
# because the latter does not keep older releases.
@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
repo = "slurm";
# The release tags use - instead of .
rev = "${pname}-${builtins.replaceStrings ["."] ["-"] version}";
sha256 = "sha256-rJCIV+dQaC6kCenp4fyPUYBztOlleZtNzCaaKkDHafg=";
sha256 = "1anzjv9sdl1a3j6sxsy2q8dy4dax1a4yqc9rnprlzymjkgb8hy75";
};
outputs = [ "out" "dev" ];

View File

@ -17,11 +17,11 @@ lua = luajitPackages;
unwrapped = stdenv.mkDerivation rec {
pname = "knot-resolver";
version = "5.3.0";
version = "5.3.1";
src = fetchurl {
url = "https://secure.nic.cz/files/knot-resolver/${pname}-${version}.tar.xz";
sha256 = "fb6cb2c03f4fffbdd8a0098127383d03b14cf7d6abf3a0cd229fb13ff68ee33e";
sha256 = "9d4d6b7bcdf114acc948e5ee68c83fcbb3944f48a13b9751dbbbc190cdd729c9";
};
outputs = [ "out" "dev" ];

View File

@ -0,0 +1,28 @@
{ pkgs, nodePackages, makeWrapper, nixosTests, nodejs, stdenv, lib, ... }:
let
packageName = with lib; concatStrings (map (entry: (concatStrings (mapAttrsToList (key: value: "${key}-${value}") entry))) (importJSON ./package.json));
ourNodePackages = import ./node-composition.nix {
inherit pkgs nodejs;
inherit (stdenv.hostPlatform) system;
};
in
ourNodePackages."${packageName}".override {
nativeBuildInputs = [ makeWrapper nodePackages.node-gyp-build ];
postInstall = ''
makeWrapper '${nodejs}/bin/node' "$out/bin/matrix-appservice-irc" \
--add-flags "$out/lib/node_modules/matrix-appservice-irc/app.js"
'';
passthru.tests.matrix-appservice-irc = nixosTests.matrix-appservice-irc;
meta = with lib; {
description = "Node.js IRC bridge for Matrix";
maintainers = with maintainers; [ piegames ];
homepage = "https://github.com/matrix-org/matrix-appservice-irc";
license = licenses.asl20;
};
}

View File

@ -0,0 +1,11 @@
#!/usr/bin/env bash
ROOT="$(realpath "$(dirname -- "$(readlink -f -- "${BASH_SOURCE[0]}")")"/../../../..)"
$(nix-build $ROOT -A nodePackages.node2nix --no-out-link)/bin/node2nix \
--nodejs-12 \
--node-env ../../../development/node-packages/node-env.nix \
--development \
--input package.json \
--output node-packages.nix \
--composition node-composition.nix

View File

@ -0,0 +1,17 @@
# This file has been generated by node2nix 1.9.0. Do not edit!
{pkgs ? import <nixpkgs> {
inherit system;
}, system ? builtins.currentSystem, nodejs ? pkgs."nodejs-12_x"}:
let
nodeEnv = import ../../../development/node-packages/node-env.nix {
inherit (pkgs) stdenv lib python2 runCommand writeTextFile;
inherit pkgs nodejs;
libtool = if pkgs.stdenv.isDarwin then pkgs.darwin.cctools else null;
};
in
import ./node-packages.nix {
inherit (pkgs) fetchurl nix-gitignore stdenv lib fetchgit;
inherit nodeEnv;
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,3 @@
[
{"matrix-appservice-irc": "git+https://github.com/matrix-org/matrix-appservice-irc.git#0.25.0" }
]

View File

@ -2,8 +2,8 @@
grafanaPlugin rec {
pname = "grafana-polystat-panel";
version = "1.2.2";
zipHash = "sha256-HWQdhstnrDuXPithZ8kOG2ZtSeAT215MJ1ftMCt6/tc=";
version = "1.2.3";
zipHash = "sha256-Eu3dTPfJxAWwqqGT6l4El4MqviBbzERarU30OXU+eEM=";
meta = with lib; {
description = "Hexagonal multi-stat panel for Grafana";
license = licenses.asl20;

View File

@ -1,18 +1,18 @@
{ lib, buildGoPackage, fetchFromGitHub, nixosTests }:
{ lib, buildGoModule, fetchFromGitHub, nixosTests }:
buildGoPackage rec {
buildGoModule rec {
pname = "postgres_exporter";
version = "0.8.0";
goPackagePath = "github.com/wrouesnel/postgres_exporter";
version = "0.9.0";
src = fetchFromGitHub {
owner = "wrouesnel";
repo = "postgres_exporter";
rev = "v${version}";
sha256 = "0mid2kvskab3a32jscygg5jh0741nr7dvxzj4v029yiiqcx55nrc";
sha256 = "sha256-Kv+sjqhlmH36L4YvDuGYODR/eTHA2TKQ6IUCXAiItyo=";
};
vendorSha256 = "sha256-yMcoUl9NsiiZQyEHlLu79DzIyl6BbhLZ/xNFavaGrEs=";
doCheck = true;
passthru.tests = { inherit (nixosTests.prometheus-exporters) postgres; };
@ -21,6 +21,6 @@ buildGoPackage rec {
inherit (src.meta) homepage;
description = "A Prometheus exporter for PostgreSQL";
license = licenses.asl20;
maintainers = with maintainers; [ fpletz globin willibutz ];
maintainers = with maintainers; [ fpletz globin willibutz ma27 ];
};
}

View File

@ -2,16 +2,16 @@
buildGoModule rec {
pname = "unifi-poller";
version = "2.0.1";
version = "2.1.0";
src = fetchFromGitHub {
owner = "unifi-poller";
repo = "unifi-poller";
rev = "v${version}";
sha256 = "16q9hrbl9qgilj3vb7865l1yx0xhm7m4sx5j1ys5vi63drq59g93";
sha256 = "sha256-C7QjMzmy2CMCk2oqRiThUQBKgltT0PzZArvZ+gOmJ2I=";
};
vendorSha256 = "1fgcbg34g0a0f85qv7bjanv2lpnnszcrspfppp2lnj9kv52j4c1w";
vendorSha256 = "sha256-LOBkdyfsw7ua6TsLglO5jdR9NWo5Df8rnQ8MH+eIz4g=";
buildFlagsArray = ''
-ldflags=-w -s

View File

@ -2,15 +2,15 @@
stdenv.mkDerivation rec {
pname = "pg_cron";
version = "1.3.0";
version = "1.3.1";
buildInputs = [ postgresql ];
src = fetchFromGitHub {
owner = "citusdata";
repo = pname;
rev = "refs/tags/v${version}";
sha256 = "1hvd0nfaq5q9yfxfcb0fbrjbdal06adjplvmaag88a0msdlirl7z";
rev = "v${version}";
sha256 = "0vhqm9xi84v21ijlbi3fznj799j81mmc9kaawhwn0djhxcs2symd";
};
installPhase = ''
@ -24,6 +24,7 @@ stdenv.mkDerivation rec {
meta = with lib; {
description = "Run Cron jobs through PostgreSQL";
homepage = "https://github.com/citusdata/pg_cron";
changelog = "https://github.com/citusdata/pg_cron/raw/v${version}/CHANGELOG.md";
maintainers = with maintainers; [ thoughtpolice ];
platforms = postgresql.meta.platforms;
license = licenses.postgresql;

View File

@ -2,7 +2,7 @@
buildPythonApplication rec {
pname = "Tautulli";
version = "2.6.1";
version = "2.6.8";
format = "other";
pythonPath = [ setuptools ];
@ -12,7 +12,7 @@ buildPythonApplication rec {
owner = "Tautulli";
repo = pname;
rev = "v${version}";
sha256 = "QHpVIOtGFzNqAEcBCv48YWO4pYatbTe/CWwcwjbj+34=";
sha256 = "0pkki72maxnrp3frninw2qbxyf76rvkza23k3s8fppandkr7qpvj";
};
installPhase = ''

View File

@ -1,12 +1,12 @@
{ lib, stdenv, fetchurl, makeWrapper, jre, graphviz }:
stdenv.mkDerivation rec {
version = "1.2021.2";
version = "1.2021.3";
pname = "plantuml";
src = fetchurl {
url = "mirror://sourceforge/project/plantuml/${version}/plantuml.${version}.jar";
sha256 = "sha256-06PrqYf1Cc4FZPr0K2xUc83t+/qGbwMXe/BOV81Fuxc=";
sha256 = "sha256-Kx2fTx71oVkAgsytl1OFBcENMnJ1ZHmg8qvYDFTSS2M=";
};
nativeBuildInputs = [ makeWrapper ];

View File

@ -0,0 +1,34 @@
{ lib, python3Packages }:
python3Packages.buildPythonApplication rec {
pname = "moodle-dl";
version = "2.1.2.5";
src = python3Packages.fetchPypi {
inherit pname version;
sha256 = "1gc4037dwyi48h4vi0bam23rr7pfyn6jrz334radz0r6rk94y8lz";
};
# nixpkgs (and the GitHub upstream for readchar) are missing 2.0.1
postPatch = ''
substituteInPlace setup.py --replace 'readchar>=2.0.1' 'readchar>=2.0.0'
'';
propagatedBuildInputs = with python3Packages; [
sentry-sdk
colorama
readchar
youtube-dl
certifi
html2text
requests
slixmpp
];
meta = with lib; {
homepage = "https://github.com/C0D3D3V/Moodle-Downloader-2";
maintainers = [ maintainers.kmein ];
description = "A Moodle downloader that downloads course content fast from Moodle";
license = licenses.gpl3Plus;
};
}

View File

@ -0,0 +1,106 @@
{ lib
, fetchFromGitHub
, python3
}:
python3.pkgs.buildPythonApplication rec {
pname = "wapiti";
version = "3.0.4";
src = fetchFromGitHub {
owner = "wapiti-scanner";
repo = pname;
rev = version;
sha256 = "0wnz4nq1q5y74ksb1kcss9vdih0kbrmnkfbyc2ngd9id1ixfamxb";
};
nativeBuildInputs = with python3.pkgs; [
pytest-runner
];
propagatedBuildInputs = with python3.pkgs; [
beautifulsoup4
browser-cookie3
Mako
markupsafe
pysocks
requests
six
tld
yaswfp
] ++ lib.optionals (python3.pythonOlder "3.8") [ importlib-metadata ];
checkInputs = with python3.pkgs; [
responses
pytestCheckHook
];
postPatch = ''
# Is already fixed in the repo. Will be part of the next release
substituteInPlace setup.py \
--replace "importlib_metadata==2.0.0" "importlib_metadata"
'';
disabledTests = [
# Tests requires network access
"test_attr"
"test_bad_separator_used"
"test_blind"
"test_chunked_timeout"
"test_cookies_detection"
"test_csrf_cases"
"test_detection"
"test_direct"
"test_escape_with_style"
"test_explorer_filtering"
"test_false"
"test_frame"
"test_headers_detection"
"test_html_detection"
"test_implies_detection"
"test_inclusion_detection"
"test_meta_detection"
"test_no_crash"
"test_options"
"test_out_of_band"
"test_partial_tag_name_escape"
"test_prefix_and_suffix_detection"
"test_qs_limit"
"test_rare_tag_and_event"
"test_redirect_detection"
"test_request_object"
"test_script"
"test_ssrf"
"test_tag_name_escape"
"test_timeout"
"test_title_false_positive"
"test_title_positive"
"test_true_positive_request_count"
"test_url_detection"
"test_warning"
"test_whole"
"test_xss_inside_tag_input"
"test_xss_inside_tag_link"
"test_xss_uppercase_no_script"
"test_xss_with_strong_csp"
"test_xss_with_weak_csp"
"test_xxe"
];
pythonImportsCheck = [ "wapitiCore" ];
meta = with lib; {
description = "Web application vulnerability scanner";
longDescription = ''
Wapiti allows you to audit the security of your websites or web applications.
It performs "black-box" scans (it does not study the source code) of the web
application by crawling the webpages of the deployed webapp, looking for
scripts and forms where it can inject data. Once it gets the list of URLs,
forms and their inputs, Wapiti acts like a fuzzer, injecting payloads to see
if a script is vulnerable.
'';
homepage = "https://wapiti-scanner.github.io/";
license = with licenses; [ gpl2Only ];
maintainers = with maintainers; [ fab ];
};
}

View File

@ -0,0 +1,50 @@
{ lib
, fetchFromGitHub
, python3
}:
python3.pkgs.buildPythonApplication rec {
pname = "xcat";
version = "1.2.0";
disabled = python3.pythonOlder "3.7";
format = "pyproject";
src = fetchFromGitHub {
owner = "orf";
repo = pname;
rev = "v${version}";
sha256 = "01r5998gdvqjdrahpk0ci27lx9yghbddlanqcspr3qp5y5930i0s";
};
nativeBuildInputs = with python3.pkgs; [
poetry-core
];
propagatedBuildInputs = with python3.pkgs; [
aiodns
aiohttp
appdirs
cchardet
click
colorama
prompt_toolkit
xpath-expressions
];
# Project has no tests
doCheck = false;
pythonImportsCheck = [ "xcat" ];
meta = with lib; {
description = "XPath injection tool";
longDescription = ''
xcat is an advanced tool for exploiting XPath injection vulnerabilities,
featuring a comprehensive set of features to read the entire file being
queried as well as other files on the filesystem, environment variables
and directories.
'';
homepage = "https://github.com/orf/xcat";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}

View File

@ -628,6 +628,7 @@ mapAliases ({
rubyMinimal = throw "rubyMinimal was removed due to being unused";
rxvt_unicode-with-plugins = rxvt-unicode; # added 2020-02-02
rxvt_unicode = rxvt-unicode-unwrapped; # added 2020-02-02
subversion19 = throw "subversion19 has been removed as it has reached its end of life"; # added 2021-03-31
urxvt_autocomplete_all_the_things = rxvt-unicode-plugins.autocomplete-all-the-things; # added 2020-02-02
urxvt_perl = rxvt-unicode-plugins.perl; # added 2020-02-02
urxvt_perls = rxvt-unicode-plugins.perls; # added 2020-02-02

View File

@ -259,6 +259,16 @@ in
protoc-gen-doc = callPackage ../development/tools/protoc-gen-doc {};
protoc-gen-go = callPackage ../development/tools/protoc-gen-go { };
protoc-gen-twirp = callPackage ../development/tools/protoc-gen-twirp { };
protoc-gen-twirp_php = callPackage ../development/tools/protoc-gen-twirp_php { };
protoc-gen-twirp_swagger = callPackage ../development/tools/protoc-gen-twirp_swagger { };
protoc-gen-twirp_typescript = callPackage ../development/tools/protoc-gen-twirp_typescript { };
ptags = callPackage ../development/tools/misc/ptags { };
ptouch-print = callPackage ../misc/ptouch-print { };
@ -2728,6 +2738,8 @@ in
monsoon = callPackage ../tools/security/monsoon {};
moodle-dl = callPackage ../tools/networking/moodle-dl { };
mousetweaks = callPackage ../applications/accessibility/mousetweaks {
inherit (pkgs.xorg) libX11 libXtst libXfixes;
};
@ -3869,6 +3881,9 @@ in
};
drone = callPackage ../development/tools/continuous-integration/drone { };
drone-oss = callPackage ../development/tools/continuous-integration/drone {
enableUnfree = false;
};
drone-cli = callPackage ../development/tools/continuous-integration/drone-cli { };
@ -5921,6 +5936,8 @@ in
matrix-synapse-tools = recurseIntoAttrs matrix-synapse.tools;
matrix-appservice-irc = callPackage ../servers/matrix-synapse/matrix-appservice-irc { };
matrix-appservice-slack = callPackage ../servers/matrix-synapse/matrix-appservice-slack {};
matrix-appservice-discord = callPackage ../servers/matrix-appservice-discord { };
@ -14085,7 +14102,7 @@ in
fstrm = callPackage ../development/libraries/fstrm { };
cfitsio = callPackage ../development/libraries/cfitsio { };
cfitsio = callPackage ../development/libraries/science/astronomy/cfitsio { };
fontconfig = callPackage ../development/libraries/fontconfig {
inherit (darwin.apple_sdk.frameworks) CoreFoundation;
@ -14785,9 +14802,9 @@ in
indicator-application-gtk2 = callPackage ../development/libraries/indicator-application/gtk2.nix { };
indicator-application-gtk3 = callPackage ../development/libraries/indicator-application/gtk3.nix { };
indilib = callPackage ../development/libraries/indilib { };
indi-3rdparty = callPackage ../development/libraries/indilib/indi-3rdparty.nix { };
indi-full = callPackage ../development/libraries/indilib/indi-full.nix { };
indilib = callPackage ../development/libraries/science/astronomy/indilib { };
indi-3rdparty = callPackage ../development/libraries/science/astronomy/indilib/indi-3rdparty.nix { };
indi-full = callPackage ../development/libraries/science/astronomy/indilib/indi-full.nix { };
inih = callPackage ../development/libraries/inih { };
@ -15746,7 +15763,7 @@ in
libnih = callPackage ../development/libraries/libnih { };
libnova = callPackage ../development/libraries/libnova { };
libnova = callPackage ../development/libraries/science/astronomy/libnova { };
libnxml = callPackage ../development/libraries/libnxml { };
@ -17621,7 +17638,7 @@ in
waylandpp = callPackage ../development/libraries/waylandpp { };
wcslib = callPackage ../development/libraries/wcslib { };
wcslib = callPackage ../development/libraries/science/astronomy/wcslib { };
webkitgtk = callPackage ../development/libraries/webkitgtk {
harfbuzz = harfbuzzFull;
@ -19850,6 +19867,8 @@ in
sch_cake = callPackage ../os-specific/linux/sch_cake { };
isgx = callPackage ../os-specific/linux/isgx { };
sysdig = callPackage ../os-specific/linux/sysdig {};
systemtap = callPackage ../development/tools/profiling/systemtap { };
@ -21924,6 +21943,8 @@ in
calibre = libsForQt5.callPackage ../applications/misc/calibre { };
calibre-web = callPackage ../servers/calibre-web { };
calligra = libsForQt5.callPackage ../applications/office/calligra {
# Must use the same Qt version as Calligra itself:
poppler = libsForQt5.poppler_0_61;
@ -23386,6 +23407,8 @@ in
i3-layout-manager = callPackage ../applications/window-managers/i3/layout-manager.nix { };
i3-ratiosplit = callPackage ../applications/window-managers/i3/i3-ratiosplit.nix { };
i3-resurrect = python3Packages.callPackage ../applications/window-managers/i3/i3-resurrect.nix { };
i3blocks = callPackage ../applications/window-managers/i3/blocks.nix { };
@ -23759,6 +23782,10 @@ in
kubectl = callPackage ../applications/networking/cluster/kubectl { };
kuttl = callPackage ../applications/networking/cluster/kuttl {
buildGoModule = buildGo115Module;
};
kubectl-doctor = callPackage ../applications/networking/cluster/kubectl-doctor { };
kubectl-example = callPackage ../applications/networking/cluster/kubectl-example { };
@ -25645,7 +25672,7 @@ in
sublime-merge-dev;
inherit (callPackages ../applications/version-management/subversion { sasl = cyrus_sasl; })
subversion19 subversion_1_10 subversion;
subversion_1_10 subversion;
subversionClient = appendToName "client" (pkgs.subversion.override {
bdbSupport = false;
@ -26278,6 +26305,8 @@ in
pythonPackages = python3Packages;
};
wapiti = callPackage ../tools/security/wapiti { };
way-cooler = throw ("way-cooler is abandoned by its author: " +
"https://way-cooler.org/blog/2020/01/09/way-cooler-post-mortem.html");
@ -26551,6 +26580,8 @@ in
xcape = callPackage ../tools/X11/xcape { };
xcat = callPackage ../tools/security/xcat { };
xchainkeys = callPackage ../tools/X11/xchainkeys { };
xchm = callPackage ../applications/misc/xchm { };
@ -29047,7 +29078,7 @@ in
stellarium = libsForQt5.callPackage ../applications/science/astronomy/stellarium { };
stellarsolver = libsForQt5.callPackage ../development/libraries/stellarsolver { };
stellarsolver = libsForQt5.callPackage ../development/libraries/science/astronomy/stellarsolver { };
astrolabe-generator = callPackage ../applications/science/astronomy/astrolabe-generator { };

View File

@ -2546,6 +2546,8 @@ in {
fpylll = callPackage ../development/python-modules/fpylll { };
freebox-api = callPackage ../development/python-modules/freebox-api { };
freetype-py = callPackage ../development/python-modules/freetype-py { };
freezegun = if isPy27 then
@ -8990,6 +8992,8 @@ in {
xnd = callPackage ../development/python-modules/xnd { };
xpath-expressions = callPackage ../development/python-modules/xpath-expressions { };
xpybutil = callPackage ../development/python-modules/xpybutil { };
xstatic-bootbox = callPackage ../development/python-modules/xstatic-bootbox { };
@ -9036,6 +9040,8 @@ in {
yarl = callPackage ../development/python-modules/yarl { };
yaswfp = callPackage ../development/python-modules/yaswfp { };
yattag = callPackage ../development/python-modules/yattag { };
ydiff = callPackage ../development/python-modules/ydiff { };