Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

earlyoom service: init #23135

Merged
merged 1 commit into from Apr 6, 2017
Merged

Conversation

ljli
Copy link
Contributor

@ljli ljli commented Feb 24, 2017

Motivation for this change
Things done
  • Tested using sandboxing
    (nix.useSandbox on NixOS,
    or option build-use-sandbox in nix.conf
    on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • Linux
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@mention-bot
Copy link

@ljli, thanks for your PR! By analyzing the history of the files in this pull request, we identified @edolstra, @bjornfor and @offlinehacker to be potential reviewers.

{ lib, stdenv, fetchFromGitHub }:

stdenv.mkDerivation {
name = "earlyoom";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Name should include the version. Like this:

stdenv.mkDerivation rec {
  name = "earlyoom-${version}";
  version = ...
...

${pkgs.earlyoom}/bin/earlyoom \
-m ${toString ecfg.freeMemThreshold} \
-s ${toString ecfg.freeSwapThreshold} \
${if ecfg.useKernelOOMKiller then "-k" else ""} \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if cond then str else "" = optionalString cond str.

homepage = https://github.com/rfjakob/earlyoom;
license = lib.licenses.mit;
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ ];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maintainers is empty by default; perhaps you'd consider adding yourself?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not for now. But I'll keep an eye on it, if that's ok.

@ljli ljli force-pushed the earlyoom-service-init branch 2 times, most recently from 9470969 to 8a6dcf5 Compare February 24, 2017 18:11
@ljli
Copy link
Contributor Author

ljli commented Mar 24, 2017

The underlying program got merged in the meantime. I'm not using this service anymore, so I'll probably won't maintain this. It should still work, though. Maybe we want this anyway, otherwise feel free to close.

@joachifm joachifm closed this Apr 6, 2017
@offlinehacker
Copy link
Contributor

Wat, why we didn't merge this pull request. I might want to use it.

@offlinehacker offlinehacker reopened this Apr 6, 2017
@joachifm
Copy link
Contributor

joachifm commented Apr 6, 2017

@offlinehacker ah, I interpreted the lack of a response to the last comment as a lack of interest. If you want it, please go ahead and integrate it :)

@offlinehacker
Copy link
Contributor

Linux oom killer is so bad, I will use this in my dev environments, so I'm merging this.

@offlinehacker offlinehacker merged commit 43880af into NixOS:master Apr 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants