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

python3Pakcages.pid: remove nose dependency #327372

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
170 commits
Select commit Hold shift + click to select a range
bdec5a3
librime-lua: init at 0-unstable-2024-05-19
jian-lin Jul 13, 2024
7974e46
librime: add librime-lua plugin by default following Arch Linux
jian-lin Jul 13, 2024
4168846
conan: 2.0.17 -> 2.5.0
jhol Jul 13, 2024
23d5aa1
tcpreplay: 4.4.4 -> 4.5.1
r-ryantm Jul 12, 2024
e56e425
stackit-cli: 0.8.1 -> 0.9.0
DerRockWolf Jul 12, 2024
1529e1f
quarto: 1.5.53 -> 1.5.54
b-rodrigues Jul 9, 2024
d70b7d1
blendfarm: init at 1.1.6
gador Apr 22, 2024
6814763
nixos/blendfarm: init
gador Apr 23, 2024
8950ac6
python312Packages.pylink-square: 1.2.0 -> 1.2.1
r-ryantm Jul 12, 2024
03d5e61
python312Packages.pylink-square: switch to pypa build
natsukium Jul 14, 2024
76bebd5
bdf2psf: 1.228 -> 1.229
rnhmjoj Jul 14, 2024
7a88683
teamspeak5_client: add mesa dependency
K900 Jul 14, 2024
b3d2232
python312Packages.twitchapi: 4.2.0 -> 4.2.1
r-ryantm Jul 15, 2024
a12ef44
tuifimanager: 4.0.6 -> 4.1.7 (#326616)
Sigmanificient Jul 15, 2024
db6314d
maintainers: add liammurphy14
liam-murphy14 Feb 13, 2024
a37ba3b
electron-chromedriver: init at 29.4.4, 30.2.0, 31.2.0
liam-murphy14 Apr 29, 2024
f054325
electron: support updating chromedriver with update.py
yayayayaka Jul 14, 2024
8513b8b
tinymist: 0.11.14 -> 0.11.15
r-ryantm Jul 15, 2024
dc4953e
kyverno: 1.12.4 -> 1.12.5 (#326612)
r-ryantm Jul 15, 2024
0070c21
nomad-driver-podman: 0.5.2 -> 0.6.0
r-ryantm Jul 12, 2024
c817c48
xcbeautify: 1.4.0 -> 2.4.1
siddarthkay Jul 12, 2024
f9559a7
emuflight-configurator: 0.4.1 -> 0.4.3
r-ryantm Jul 12, 2024
107b58c
unison-ucm: 0.5.22 -> 0.5.24
ereslibre Jul 12, 2024
a6df471
pacman: 6.1.0 -> 7.0.0
SamLukeYes Jul 14, 2024
19b97fb
oboete: 0.1.4 -> 0.1.5
r-ryantm Jul 15, 2024
b41e053
vnote: 3.18.0 -> 3.18.1
Limosine Jul 14, 2024
6de1e2d
thunderbird: refactor (prepare for version 128)
vcunat Jul 13, 2024
8ecdea6
thunderbird-128: init at 128.0esr
vcunat Jul 13, 2024
7f0ad3f
thunderbird: cleanup patch filenames
vcunat Jul 15, 2024
bbfdcf9
h5dump: use finalAttrs, hash instead of sha256, remove with lib
SFrijters Jul 14, 2024
546bc41
h5utils: reformat for RFC166
SFrijters Jul 14, 2024
07350cf
h5utils: move to by-name
SFrijters Jul 14, 2024
8f0b09d
h5utils: remove more 'with lib'
SFrijters Jul 14, 2024
1f5aa47
proton-pass: 1.19.2 -> 1.20.1
r-ryantm Jul 14, 2024
c647f5e
k3s: document onboarding maintainer
superherointj Jul 14, 2024
ce35c72
k3s_1_29: 1.29.6+k3s1 -> 1.29.6+k3s2
r-ryantm Jul 15, 2024
7d8dd96
tandoor-recipes: pin to python311
ipetkov Jul 14, 2024
820ac16
tandoor-recipes: pin lxml to 5.1.0
ipetkov Jul 14, 2024
c63553e
libjpeg: add sigmanificient to maintainers
Sigmanificient Jul 14, 2024
c8cac1e
libjpeg: format with nixfmt, change sha56 -> hash
Sigmanificient Jul 14, 2024
9c2ad8a
osquery: restore tests in passthru
squalus Jul 14, 2024
982c942
obconf: use finalAttrs, hash instead of sha256
SFrijters Jul 14, 2024
d2d1b3e
obconf: reformat for RFC166
SFrijters Jul 14, 2024
d423a6a
obconf: move to by-name
SFrijters Jul 14, 2024
ee6f16c
organicmaps: 2024.06.19-3 -> 2024.07.08-3
r-ryantm Jul 14, 2024
4f11590
spot: migrate to by-name
getchoo Jun 26, 2024
d1b483f
spot: format with nixfmt
getchoo Jun 26, 2024
b83efb0
spot: adopt
getchoo Jun 26, 2024
cd98cb8
spot: refactor
getchoo Jun 26, 2024
e0a945f
spot: add `appstream-glib` to nativeBuildInputs
getchoo Jun 26, 2024
f2a1e40
fetchCrate: sha256 -> hash
pyrox0 Jul 12, 2024
3678e78
rure: sha256 -> hash, update Cargo.lock
pyrox0 Jul 14, 2024
a09b462
python3Packages.twitter-common-collections: remove
natsukium Jul 14, 2024
005a9af
python3Packages.twitter-common-confluence: remove
natsukium Jul 14, 2024
f4f8f54
python3Packages.twitter-common-dirutil: remove
natsukium Jul 14, 2024
845616e
python3Packages.twitter-common-lang: remove
natsukium Jul 14, 2024
4ee3a04
python3Packages.twitter-common-log: remove
natsukium Jul 14, 2024
2f2f2ca
python3Packages.twitter-common-options: remove
natsukium Jul 14, 2024
6717e1b
nixos-alsa: remove `with lib;`, fix undefined references
K900 Jul 15, 2024
297bdc2
tabula: remove
Mic92 Jul 15, 2024
d802dc5
mdt: init at 0.8.1
0x61nas May 30, 2024
2c85d7d
starspace: remove
Mic92 Jul 15, 2024
3f74bd2
greetd.dlm: remove
Aleksanaa Jul 15, 2024
6400b9e
vimPluginsUpdater: make development easier
teto Jun 17, 2024
6377072
{bitcoin-unlimited, bitcoind-unlimited}: remove
Mic92 Jul 15, 2024
9baebdb
aeon: remove
Mic92 Jul 15, 2024
9e83ffa
pivxd: remove
Mic92 Jul 15, 2024
4410c35
tumpa: remove
Mic92 Jul 15, 2024
534083c
python312Packages.pykeepass: 4.0.7 -> 4.1.0
dotlambda Jul 8, 2024
edba923
maintainers: add camcalaquian
camcalaquian Jul 5, 2024
a2843fc
oathkeeper: init at 0.40.7
camcalaquian Jul 5, 2024
a788461
warp-terminal: 0.2024.06.25.08.02.stable_01 -> 0.2024.07.09.08.01.sta…
r-ryantm Jul 15, 2024
84c8fe8
linux_6_10: init at 6.10
K900 Jul 15, 2024
3f7f353
linuxPackages_6_10.perf: fix build
K900 Jul 15, 2024
5257395
linux_6_6: 6.6.39 -> 6.6.40
K900 Jul 15, 2024
adb0d15
linux_6_1: 6.1.98 -> 6.1.99
K900 Jul 15, 2024
962cdc4
linux-rt_5_10: 5.10.220-rt112 -> 5.10.221-rt113
K900 Jul 15, 2024
917388d
linux_latest-libre: 19597 -> 19607
K900 Jul 15, 2024
dcedbbb
displaylink: update the help message
drupol Jul 15, 2024
54ca486
python311Packages.approvaltests: 12.2.1 -> 14.0.0
dotlambda Jul 8, 2024
a71841d
python311Packages.robotframework-pythonlibcore: 4.4.0 -> 4.4.1
dotlambda Jul 8, 2024
b2f5e83
python311Packages.robotframework-seleniumlibrary: 6.4.0 -> 6.5.0
dotlambda Jul 8, 2024
f651a74
qutebrowser: don't use distutils
dotlambda Jul 12, 2024
04eb7f0
qutebrowser: update dependencies
dotlambda Jul 12, 2024
e457cc5
nextcloud-client: only update after official release
dotlambda Jul 11, 2024
daaa743
abracadabra: 2.5.0 -> 2.5.1
r-ryantm Jul 15, 2024
f38f2fa
doc/vim.section.md: fix references to the old update.py script
thiagokokada Jul 14, 2024
e0b7ead
vimPlugins.url-open: init at 2024-02-03
Jul 14, 2024
5bd83c7
vimPlugins: update on 2024-07-14
Jul 14, 2024
32d6a84
vimPlugins: resolve github repository redirects
Jul 14, 2024
d7a9bed
vimPlugins.nvim-treesitter: update grammars
Jul 14, 2024
639669e
vimPlugins.nvim-spectre: update cargoHash
thiagokokada Jul 15, 2024
3aa062d
vimPlugins.LeaderF: add missing setuptools
thiagokokada Jul 15, 2024
7274c98
vimPlugins.codeium-nvim: 1.8.25 -> 1.8.80
thiagokokada Jul 15, 2024
f2e2fdc
cot: mark as broken on Python 3.12 or superior
AndersonTorres Jul 13, 2024
e168aaf
networkd-notify: fix gobject-introspection typelib lookup (#327285)
danc86 Jul 15, 2024
fc7a87d
{ib-tws,ib-controller}: remove
Mic92 Jul 15, 2024
9210cd6
py-spy: pin python311
kirillrdy Jul 8, 2024
40d0299
py-spy: 0.3.14 -> 0.3.14-unstable-2024-02-27
kirillrdy Jul 11, 2024
79507b8
python311Packages.lightning-utilities: 0.11.3.post0 -> 0.11.5
GaetanLepage Jul 14, 2024
d412a86
bibata-extra-cursors: remove
Mic92 Jul 15, 2024
e068166
frankenphp: 1.2.1 -> 1.2.2
r-ryantm Jul 13, 2024
ef705c1
osv-scanner: 1.8.1 -> 1.8.2
r-ryantm Jul 13, 2024
8dd9784
regclient: 0.6.1 -> 0.7.0
r-ryantm Jul 13, 2024
1ba65ad
reposilite: 3.5.13 -> 3.5.14
r-ryantm Jul 15, 2024
1e2f647
php81Extensions.blackfire: 1.92.18 -> 1.92.19
r-ryantm Jul 14, 2024
674fcd6
ascii-draw: 0.3.4 -> 0.4.0
Aleksanaa Jul 15, 2024
c0f6a6f
goreleaser: 2.0.1 -> 2.1.0
r-ryantm Jul 14, 2024
cc37331
containerlab: 0.55.1 -> 0.56.0
r-ryantm Jul 10, 2024
4ae3d18
mainsail: 2.11.2 -> 2.12.0
r-ryantm Jul 14, 2024
18e9f4c
neovide: 0.13.1 -> 0.13.2
ck3d Jul 13, 2024
00f1873
bruno: fix css issue with patch file
Jul 10, 2024
2bca574
granted: 0.29.0 -> 0.29.1
r-ryantm Jul 15, 2024
a56744c
stevenblack-blocklist: 3.14.84 -> 3.14.87
Frontear Jul 15, 2024
20ebc49
feed2imap-go: 1.7.0 -> 1.7.2
r-ryantm Jul 12, 2024
bbbb4a9
jenkins: 2.452.2 -> 2.452.3
r-ryantm Jul 14, 2024
bb4ecbf
ardugotools: 0.5.2 -> 0.6.0
r-ryantm Jul 15, 2024
97a99ee
nerdfix: 0.4.0 -> 0.4.1
r-ryantm Jul 14, 2024
413750a
pscale: 0.197.0 -> 0.204.0
r-ryantm Jul 13, 2024
b5404dc
retrospy: 6.4.8 -> 6.5
JamieMagee Jul 12, 2024
3feaf8f
fastfetch: 2.17.2-> 2.18.1
ubbabeck Jul 11, 2024
0cc038b
monetdb: 11.49.9 -> 11.49.11
r-ryantm Jul 10, 2024
58ad7ff
pocketbase: 0.22.15 -> 0.22.17
robsliwi Jul 11, 2024
80b30bd
ocis-bin: support more architectures and add update script
Ramblurr Jun 24, 2024
b705a81
ossia-score: 3.2.3-3 -> 3.2.4
jcelerier Jul 9, 2024
d68ae8a
saxon-he: 12.4 -> 12.5
r-ryantm Jul 8, 2024
ab13d14
pysqlrecon: 0.1.4 -> 0.2.0
r-ryantm Jul 15, 2024
39e84ac
python3Packages.kserve: relax psutil
kirillrdy Jul 8, 2024
254b23d
python312Packages.homematicip: 1.1.1 -> 1.1.2
r-ryantm Jul 15, 2024
67972b4
adguardhome: 0.107.51 -> 0.107.52
r-ryantm Jul 7, 2024
dcfd7a6
python312Packages.webdav4: 0.9.8 -> 0.10.0
r-ryantm Jul 14, 2024
c1f8fc8
python312Packages.aiolifx-themes: 0.4.18 -> 0.4.21
r-ryantm Jul 15, 2024
22df7ec
python312Packages.binance-connector: 3.7.0 -> 3.8.0
r-ryantm Jul 14, 2024
7933fbd
ngrok: 3.9.0 -> 3.10.1
bobvanderlinden Jun 28, 2024
bbc4537
python312Packages.python-lsp-server: avoid qt dependencies
SuperSandro2000 Jul 12, 2024
30d11fd
workout-tracker: 1.15.2 -> 1.16.1
r-ryantm Jul 15, 2024
1534a9f
cloud-hypervisor: move openssl to checkInputs
alyssais Jul 15, 2024
a3869f1
llama-cpp: 3260 -> 3328
r-ryantm Jul 7, 2024
42adc68
treewide: remove unused args
eclairevoyant Jul 9, 2024
49759ae
treewide: replace python3 with python within python package set
eclairevoyant Jul 9, 2024
efa6f36
python311Packages.llm: fix build
eclairevoyant Jul 9, 2024
b0def54
python311Packages.python-secp256k1-cardano: fix build
eclairevoyant Jul 9, 2024
d0d3192
python311Packages.tabcmd: use correct interpreter version
eclairevoyant Jul 9, 2024
a2e1d48
python311Packages.tabcmd: mark broken
eclairevoyant Jul 10, 2024
6b4c26a
wireshark: 4.2.5 -> 4.2.6
r-ryantm Jul 12, 2024
342a7dd
python3Packages.python-fedora: remove nose (#327169)
pyrox0 Jul 15, 2024
6076f6d
python312Packages.huawei-lte-api: 1.8.1 -> 1.9.3
dotlambda Jul 3, 2024
6a5073e
python312Packages.krakenex: 2.2.1 -> 2.2.2
dotlambda Jul 3, 2024
543a65d
siyuan: 3.0.11 -> 3.1.0
TomaSajt Jun 4, 2024
d72548d
tilt: 0.33.10 -> 0.33.13
szlend Apr 28, 2024
e1b1b30
tilt: 0.33.13 -> 0.33.17
likeon Jul 11, 2024
0a3c35b
yaml-filter: init at 0.2.0
Tochiaha Jul 14, 2024
085769f
python312Packages.igraph: 0.11.5 -> 0.11.6
dotlambda Jul 8, 2024
c64436c
python312Packages.gbulb: fix build
dotlambda Jul 13, 2024
c78c46a
python312Packages.skytemple-files: 1.6.5 -> 1.7.0
dotlambda Jul 13, 2024
9be3ce8
python312Packages.skytemple-dtef: fix build
dotlambda Jul 13, 2024
ae75bd2
python312Packages.skytemple-ssb-debugger: 1.6.4 -> 1.7.0
dotlambda Jul 13, 2024
10aaa12
skytemple: fix build
dotlambda Jul 13, 2024
5e52378
ios-webkit-debug-proxy: move to `pkgs/by-name`
paveloom Jul 13, 2024
f46a934
ios-webkit-debug-proxy: reformat
paveloom Jul 13, 2024
052f084
ios-webkit-debug-proxy: add the `updateScript` and the version test
paveloom Jul 13, 2024
2c9b357
ios-webkit-debug-proxy: 1.9.0 -> 1.9.1
paveloom Jul 13, 2024
46584b1
imageworsener: move to `pkgs/by-name`
emilazy Jul 6, 2024
ce2b6c3
imageworsener: format with `nixfmt-rfc-style`
emilazy Jul 6, 2024
b2a42dd
imageworsener: modernize
emilazy Jul 6, 2024
eadf51c
imageworsener: add `longDescription`
emilazy Jul 6, 2024
970cac1
imageworsener: fetch source from GitHub
emilazy Jul 6, 2024
8deeff1
imageworsener: fix tests
emilazy Jul 6, 2024
23492fd
python312Packages.opensearch-py: fix build
wegank Jul 10, 2024
c39f6cd
python3Packages.pid: remove nose dependency
mindstorms6 Jul 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions doc/languages-frameworks/vim.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -226,18 +226,18 @@ Some plugins require overrides in order to function properly. Overrides are plac
}
```

Sometimes plugins require an override that must be changed when the plugin is updated. This can cause issues when Vim plugins are auto-updated but the associated override isn't updated. For these plugins, the override should be written so that it specifies all information required to install the plugin, and running `./update.py` doesn't change the derivation for the plugin. Manually updating the override is required to update these types of plugins. An example of such a plugin is `LanguageClient-neovim`.
Sometimes plugins require an override that must be changed when the plugin is updated. This can cause issues when Vim plugins are auto-updated but the associated override isn't updated. For these plugins, the override should be written so that it specifies all information required to install the plugin, and running `nix-shell -p vimPluginsUpdater --run vim-plugins-updater` doesn't change the derivation for the plugin. Manually updating the override is required to update these types of plugins. An example of such a plugin is `LanguageClient-neovim`.

To add a new plugin, run `./update.py add "[owner]/[name]"`. **NOTE**: This script automatically commits to your git repository. Be sure to check out a fresh branch before running.
To add a new plugin, run `nix-shell -p vimPluginsUpdater --run 'vim-plugins-updater add "[owner]/[name]"'`. **NOTE**: This script automatically commits to your git repository. Be sure to check out a fresh branch before running.

Finally, there are some plugins that are also packaged in nodePackages because they have Javascript-related build steps, such as running webpack. Those plugins are not listed in `vim-plugin-names` or managed by `update.py` at all, and are included separately in `overrides.nix`. Currently, all these plugins are related to the `coc.nvim` ecosystem of the Language Server Protocol integration with Vim/Neovim.
Finally, there are some plugins that are also packaged in nodePackages because they have Javascript-related build steps, such as running webpack. Those plugins are not listed in `vim-plugin-names` or managed by `vimPluginsUpdater` at all, and are included separately in `overrides.nix`. Currently, all these plugins are related to the `coc.nvim` ecosystem of the Language Server Protocol integration with Vim/Neovim.

## Updating plugins in nixpkgs {#updating-plugins-in-nixpkgs}

Run the update script with a GitHub API token that has at least `public_repo` access. Running the script without the token is likely to result in rate-limiting (429 errors). For steps on creating an API token, please refer to [GitHub's token documentation](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/creating-a-personal-access-token).

```sh
GITHUB_API_TOKEN=my_token ./pkgs/applications/editors/vim/plugins/update.py
nix-shell -p vimPluginsUpdater --run 'vim-plugins-updater --github-token=mytoken' # or set GITHUB_API_TOKEN environment variable
```

Alternatively, set the number of processes to a lower count to avoid rate-limiting.
Expand Down
12 changes: 12 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3137,6 +3137,12 @@
githubId = 7435854;
name = "Victor Calvert";
};
camcalaquian = {
email = "[email protected]";
github = "camcalaquian";
githubId = 36902555;
name = "Carl Calaquian";
};
camelpunch = {
email = "[email protected]";
github = "camelpunch";
Expand Down Expand Up @@ -11426,6 +11432,12 @@
githubId = 1769386;
name = "Liam Diprose";
};
liammurphy14 = {
email = "[email protected]";
github = "liam-murphy14";
githubId = 54590679;
name = "Liam Murphy";
};
liarokapisv = {
email = "[email protected]";
github = "liarokapisv";
Expand Down
Empty file added maintainers/scripts/__init__.py
Empty file.
14 changes: 10 additions & 4 deletions maintainers/scripts/pluginupdate.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def _prefetch(self, ref: Optional[str]):
return loaded

def prefetch(self, ref: Optional[str]) -> str:
print("Prefetching")
print("Prefetching %s", self.uri)
loaded = self._prefetch(ref)
return loaded["sha256"]

Expand Down Expand Up @@ -266,6 +266,7 @@ def __lt__(self, other):

@staticmethod
def load_from_csv(config: FetchConfig, row: Dict[str, str]) -> "PluginDesc":
log.debug("Loading row %s", row)
branch = row["branch"]
repo = make_repo(row["repo"], branch.strip())
repo.token = config.github_token
Expand Down Expand Up @@ -328,7 +329,7 @@ def load_plugins_from_csv(



def run_nix_expr(expr, nixpkgs: str):
def run_nix_expr(expr, nixpkgs: str, **args):
'''
:param expr nix expression to fetch current plugins
:param nixpkgs Path towards a nixpkgs checkout
Expand All @@ -347,7 +348,7 @@ def run_nix_expr(expr, nixpkgs: str):
nix_path,
]
log.debug("Running command: %s", " ".join(cmd))
out = subprocess.check_output(cmd, timeout=90)
out = subprocess.check_output(cmd, **args)
data = json.loads(out)
return data

Expand Down Expand Up @@ -736,6 +737,7 @@ def rewrite_input(
redirects: Redirects = {},
append: List[PluginDesc] = [],
):
log.info("Rewriting input file %s", input_file)
plugins = load_plugins_from_csv(
config,
input_file,
Expand All @@ -744,10 +746,14 @@ def rewrite_input(
plugins.extend(append)

if redirects:
log.debug("Dealing with deprecated plugins listed in %s", deprecated)

cur_date_iso = datetime.now().strftime("%Y-%m-%d")
with open(deprecated, "r") as f:
deprecations = json.load(f)
# TODO parallelize this step
for pdesc, new_repo in redirects.items():
log.info("Rewriting input file %s", input_file)
new_pdesc = PluginDesc(new_repo, pdesc.branch, pdesc.alias)
old_plugin, _ = prefetch_plugin(pdesc)
new_plugin, _ = prefetch_plugin(new_pdesc)
Expand Down Expand Up @@ -791,7 +797,7 @@ def update_plugins(editor: Editor, args):
start_time = time.time()
redirects = update()
duration = time.time() - start_time
print(f"The plugin update took {duration}s.")
print(f"The plugin update took {duration:.2f}s.")
editor.rewrite_input(fetch_config, args.input_file, editor.deprecated, redirects)

autocommit = not args.no_commit
Expand Down
1 change: 1 addition & 0 deletions nixos/modules/module-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -705,6 +705,7 @@
./services/misc/beanstalkd.nix
./services/misc/bees.nix
./services/misc/bepasty.nix
./services/misc/blenderfarm.nix
./services/misc/calibre-server.nix
./services/misc/canto-daemon.nix
./services/misc/cfdyndns.nix
Expand Down
16 changes: 7 additions & 9 deletions nixos/modules/services/audio/alsa.nix
Original file line number Diff line number Diff line change
@@ -1,25 +1,23 @@
# ALSA sound support.
{ config, lib, pkgs, ... }:

with lib;

{
imports = [
(mkRemovedOptionModule [ "sound" ] "The option was heavily overloaded and can be removed from most configurations.")
(lib.mkRemovedOptionModule [ "sound" ] "The option was heavily overloaded and can be removed from most configurations.")
];

options.hardware.alsa.enablePersistence = mkOption {
type = types.bool;
options.hardware.alsa.enablePersistence = lib.mkOption {
type = lib.types.bool;
default = false;
description = ''
Whether to enable ALSA sound card state saving on shutdown.
This is generally not necessary if you're using an external sound server.
'';
};

config = mkIf config.hardware.alsa.enablePersistence {
config = lib.mkIf config.hardware.alsa.enablePersistence {
# ALSA provides a udev rule for restoring volume settings.
services.udev.packages = [ alsa-utils ];
services.udev.packages = [ pkgs.alsa-utils ];

systemd.services.alsa-store = {
description = "Store Sound Card State";
Expand All @@ -32,8 +30,8 @@ with lib;
Type = "oneshot";
RemainAfterExit = true;
ExecStartPre = "${pkgs.coreutils}/bin/mkdir -p /var/lib/alsa";
ExecStart = "${alsa-utils}/sbin/alsactl restore --ignore";
ExecStop = "${alsa-utils}/sbin/alsactl store --ignore";
ExecStart = "${pkgs.alsa-utils}/sbin/alsactl restore --ignore";
ExecStop = "${pkgs.alsa-utils}/sbin/alsactl store --ignore";
};
};
};
Expand Down
141 changes: 141 additions & 0 deletions nixos/modules/services/misc/blenderfarm.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
{ config
, lib
, pkgs
, ...
}:
let
cfg = config.services.blendfarm;
json = pkgs.formats.json { };
configFile = json.generate "ServerSettings" (defaultConfig // cfg.serverConfig);
defaultConfig = {
Port = 15000;
BroadcastPort = 16342;
BypassScriptUpdate = false;
BasicSecurityPassword = null;
};
in
{
meta.maintainers = with lib.maintainers; [ gador ];

options.services.blendfarm = with lib.types; {
enable = lib.mkEnableOption "Blendfarm, a render farm management software for Blender.";
package = lib.mkPackageOption pkgs "blendfarm" { };
openFirewall = lib.mkEnableOption "Allow blendfarm network access through the firewall.";

user = lib.mkOption {
description = "User under which blendfarm runs.";
default = "blendfarm";
type = str;
};

group = lib.mkOption {
description = "Group under which blendfarm runs.";
default = "blendfarm";
type = str;
};

basicSecurityPasswordFile = lib.mkOption {
description = ''Path to the password file the client needs to connect to the server.
The password must not contain a forward slash.'';
default = null;
type = nullOr str;
};

blenderPackage = lib.mkPackageOption pkgs "blender" { };

serverConfig = lib.mkOption {
description = "Server configuration";
default = defaultConfig;
type = submodule {
freeformType = attrsOf anything;
options = {
Port = lib.mkOption {
description = "Default port blendfarm server listens on.";
default = 15000;
type = types.port;
};
BroadcastPort = lib.mkOption {
description = "Default port blendfarm server advertises itself on.";
default = 16342;
type = types.port;
};

BypassScriptUpdate = lib.mkOption {
description = "Prevents blendfarm from replacing the .py self-generated scripts.";
default = false;
type = bool;
};
};
};
};
};

config = lib.mkIf cfg.enable {
environment.systemPackages = [ cfg.package ];
networking.firewall = lib.optionalAttrs (cfg.openFirewall) {
allowedTCPPorts = [ cfg.serverConfig.Port ];
allowedUDPPorts = [ cfg.serverConfig.BroadcastPort ];
};

systemd.services.blendfarm-server = {
wantedBy = [ "multi-user.target" ];
after = [ "network-online.target" ];
wants = [ "network-online.target" ];
description = "blendfarm server";
path = [ cfg.blenderPackage ];
preStart = ''
rm -f ServerSettings
install -m640 ${configFile} ServerSettings
if [ ! -d "BlenderData/nix-blender-linux64" ]; then
mkdir -p BlenderData/nix-blender-linux64
echo "nix-blender" > VersionCustom
fi
rm -f BlenderData/nix-blender-linux64/blender
ln -s ${lib.getExe cfg.blenderPackage} BlenderData/nix-blender-linux64/blender
'' +
lib.optionalString (cfg.basicSecurityPasswordFile != null) ''
BLENDFARM_PASSWORD=$(${pkgs.systemd}/bin/systemd-creds cat BLENDFARM_PASS_FILE)
sed -i "s/null/\"$BLENDFARM_PASSWORD\"/g" ServerSettings
'';
serviceConfig = {
ExecStart = "${cfg.package}/bin/LogicReinc.BlendFarm.Server";
DynamicUser = true;
LogsDirectory = "blendfarm";
StateDirectory = "blendfarm";
WorkingDirectory = "/var/lib/blendfarm";
User = cfg.user;
Group = cfg.group;
StateDirectoryMode = "0755";
LoadCredential = lib.optional (cfg.basicSecurityPasswordFile != null) "BLENDFARM_PASS_FILE:${cfg.basicSecurityPasswordFile}";
ReadWritePaths = "";
CapabilityBoundingSet = "";
RestrictAddressFamilies = [ "AF_UNIX" "AF_INET" "AF_INET6" ];
RestrictNamespaces = true;
PrivateDevices = true;
PrivateUsers = true;
ProtectClock = true;
ProtectControlGroups = true;
ProtectHome = true;
ProtectKernelLogs = true;
ProtectKernelModules = true;
ProtectKernelTunables = true;
SystemCallArchitectures = "native";
SystemCallFilter = [
"@system-service"
"~@privileged"
"@chown"
];
RestrictRealtime = true;
LockPersonality = true;
UMask = "0066";
ProtectHostname = true;
};
};

users.users.blendfarm = {
isSystemUser = true;
group = "blendfarm";
};
users.groups.blendfarm = { };
};
}
45 changes: 0 additions & 45 deletions pkgs/applications/blockchains/aeon/default.nix

This file was deleted.

Loading
Loading