NixOS Installation
Dux Search
NixOS Installation
Dux Search can be installed on NixOS using the NixOS module. This guide covers the native nixpkgs installation method.
Dux Search is available in nixpkgs stable (26.05).
Installation
1. Enable Dux Search
In your NixOS configuration, enable Dux Search:
programs.dsearch.enable = true;
That's it! Rebuild your system and Dux Search will be installed with sensible defaults.
Configuration Options
Dux Search provides configuration options to customize your installation:
Basic Configuration
programs.dsearch = {
enable = true;
# Use a custom package (optional)
package = pkgs.dsearch;
# Systemd service configuration
systemd = {
enable = true; # Enable systemd user service
target = "default.target"; # Start with user session
};
};
Systemd Service Options
The NixOS module configures a systemd user service. You can customize when it starts:
programs.dsearch = {
enable = true;
systemd = {
enable = true;
target = "graphical-session.target"; # Only start in graphical sessions
};
};
Using Flake Package with NixOS Module
You can use the package from the Dux Search flake while still using the native NixOS module. This allows you to get quicker updates while keeping the module configuration:
First, add the flake input to your flake.nix:
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-26.05";
dsearch = {
url = "github:duxlabs-dev/dux-search";
inputs.nixpkgs.follows = "nixpkgs";
};
};
}
Then use the flake package with the native module:
programs.dsearch = {
enable = true;
package = inputs.danksearch.packages.${pkgs.stdenv.hostPlatform.system}.default;
};
When using the flake package with the native nixpkgs module, some dependencies may not be automatically enabled by default, and certain configurations might be missing. You may need to manually install optional dependencies or adjust feature toggles to match your needs.
For per-user installation with more flexibility, consider using the home-manager flake installation method instead.
Rebuilding
After making configuration changes, rebuild your system:
sudo nixos-rebuild switch
Troubleshooting
Service doesn't start automatically
Make sure you have systemd.enable = true set:
programs.dsearch = {
enable = true;
systemd.enable = true;
};
Binary not found
Ensure Dux Search is properly installed:
programs.dsearch.enable = true;
Next Steps
- Learn more about Configuration options
- Explore Usage guide for CLI and API usage
- Check out Dux Shell integration