Skip to content
  • Niklāvs Koļesņikovs's avatar
    RLIMITs: add support for generating limits.d files · 5e0bfa0b
    Niklāvs Koļesņikovs authored
    
    
    This commit implements generating /etc/security/limits.d/20-pw-defaults.conf and
    /etc/security/limits.d/25-pw-rlimits.conf files. The numbering is arbitrary and
    may very well warrant being in the reverse order, however `man 5 limits.conf`
    does not appear to specify the parsing order or even say exactly how multiples
    matches will resolve, so the value can be adjusted later, if required.
    
    The actual limit values, the match rule and even whether each file is to be
    installed can be changed via the build system before compilation. Likewise
    the files can be modified or (re)moved during distro package building phase.
    
    The 20-pw-defaults.conf should only be installed on legacy systems lacking both
    a modern kernel and up to date systemd, because all it does is set the current
    Linux default. Accordingly its not installed by default.
    
    Signed-off-by: default avatarNiklāvs Koļesņikovs <89q1r14hd@relay.firefox.com>
    5e0bfa0b