16 Nov 2021 |
ultranix | In reply to @ultranix:matrix.org it wont evaluate if i try to read a string from builtins.readFile /run/secrets/* since its a impure path ah well i suppose I can specify a relative directory to the repo with agenix on a per secret basis. | 20:50:30 |
Pacman99 | I just came across this method to import modules from other channels:
{ lib, config, latestModulesPath, channels, ... }:
let
domain = "files.${config.networking.domain}";
seafileModule = import
"${latestModulesPath}/services/networking/seafile.nix"
{ inherit config lib; pkgs = channels.latest; };
in
{
imports = [ seafileModule ];
services.seafile = {
channels is a module arg I added in my flake.nix, its just self.pkgs.${system}
| 23:08:25 |
22 Nov 2021 |
@gytis-ivaskevicius:matrix.org | https://github.com/rust-lang/team/pull/671
| 15:10:00 |
@gytis-ivaskevicius:matrix.org | 🤔 | 15:10:03 |
23 Nov 2021 |
| @server_stats:nordgedanken.dev left the room. | 02:21:09 |
@teutat3s:pub.solar | I'd like to add this to an overlay for element-desktop (from unstable, I added it to the inherit list in overrides.nix )
fixupPhase = ''
sed -i "s#exec#LD_PRELOAD=${pkgs.sqlcipher}/lib/libsqlcipher.so exec#g" "$out/bin/element-desktop"
'';
| 16:45:55 |
@teutat3s:pub.solar | But I can't manage to do it, does someone have an idea for a proper overlay? | 16:46:21 |
@teutat3s:pub.solar | I thought adding a overlays/element-desktop.nix file could be the solution, looking similar to this:
self: super: {
element-desktop = super.element-desktop.overrideAttrs (old: {
fixupPhase = ''
sed -i "s#exec#LD_PRELOAD=${pkgs.sqlcipher}/lib/libsqlcipher.so exec#g" "$out/bin/element-desktop"
'';
});
}
but ofc I get: error: undefined variable 'pkgs'
| 16:47:55 |
b12f | pkgs is self or super here | 16:48:10 |
@teutat3s:pub.solar | Ah nice that helped! Now it's building version 1.9.2 from the wrong channel though... hmmm | 16:51:42 |
@danielphan.2003:matrix.org | I suppose you want to use the unstable element-desktop, in that case change self: super: to channels: final: prev: , and super.element-desktop to channels.latest.element-desktop (assuming you use the base DevOS) | 17:11:08 |
@teutat3s:pub.solar | you're assuming correctly, the file I'd like to add the fixup phase to is probably this one:
https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/applications/networking/instant-messengers/element/element-desktop.nix | 17:13:52 |
@teutat3s:pub.solar | so I guess I'll have to take mkYarnPackage into that overlay somewhere? | 17:14:44 |
@teutat3s:pub.solar | * so I guess I'll have to integrate mkYarnPackage into that overlay somewhere? | 17:14:51 |
@teutat3s:pub.solar | Daniel Phan: I don't get any errors with that change, but the resulting $out/bin/element-desktop wrapper doesn't include the change from the defined fixupPhase | 17:21:57 |
@danielphan.2003:matrix.org | You should use makeWrapper for this
wrapProgram $out/bin/element-desktop \
--prefix LD_PRELOAD : ${prev.sqlcipher}/lib/libsqlcipher
so
| 17:48:25 |
@danielphan.2003:matrix.org | Also why do you need to wrap element with this? I normally would wrap it with ozone flags so it behaves well on Wayland | 17:49:39 |
@danielphan.2003:matrix.org | * You should use makeWrapper for this
```
wrapProgram $out/bin/element-desktop \
--prefix LD_PRELOAD : ${prev.sqlcipher}/lib/libsqlcipher.so
``` | 17:52:14 |
@teutat3s:pub.solar | ah thanks, I'll try that next. I'm trying to make search in encrypted rooms work, following this conversation: https://github.com/NixOS/nixpkgs/pull/132633#issuecomment-943316734 | 18:18:34 |
@teutat3s:pub.solar | Wow search in encrypted rooms really works with that change
channels: final: prev: {
element-desktop-search-fixed = channels.latest.element-desktop-wayland.overrideAttrs (oldAttrs: {
fixupPhase = ''
sed -i "s#exec#LD_PRELOAD=${channels.latest.sqlcipher}/lib/libsqlcipher.so exec#g" "$out/bin/element-desktop"
'';
});
}
| 18:46:32 |
@teutat3s:pub.solar | I'll try wrapProgram next | 18:46:40 |
@teutat3s:pub.solar | * I'll try wrapProgram next | 18:46:45 |
@teutat3s:pub.solar | Daniel Phan: b12f thanks for the help | 18:51:22 |
@teutat3s:pub.solar | ...but rendering is really laggy somehow. 😀 great - one bug fixed, a new one to fix. | 18:53:10 |
26 Nov 2021 |
@teutat3s:pub.solar | new PR: follow release-21.11, use nix 2.4 https://github.com/divnix/digga/pull/114 | 11:23:40 |
David Arnold (blaggacao) | Alex Zero: Hi Alex, might you have the chance to have a look at https://github.com/divnix/digga/pull/114#discussion_r757439471 ? I really don't know what to do, here. I remember I reviewed that codepath in nix in connection with your follows patch. Maybe you've got an idea, here. | 12:04:32 |
30 Nov 2021 |
@teutat3s:pub.solar | David Arnold (blaggacao): maybe nixFlakes is an even better alias than nixUnstable , as it's pinned to nix 2.4? Or do we want to follow nix development more closely? | 00:24:43 |
@teutat3s:pub.solar | Thanks for merging btw ( : | 00:25:02 |
@teutat3s:pub.solar | * David Arnold (blaggacao): maybe nixFlakes is an even better alias than nixUnstable , as it's pinned to nix 2.4? Or do we want to follow nix development more closely? | 00:30:30 |
David Arnold (blaggacao) | I think we should finally do the complete switch to deploy-rs for all deployment task. One-size fits all is just too tempting. | 03:09:05 |