Skip to content

Comments

nixos/cgit: use alias option for assets#390448

Merged
Aleksanaa merged 1 commit intoNixOS:masterfrom
axelkar:cgit-robots-alias
Aug 1, 2025
Merged

nixos/cgit: use alias option for assets#390448
Aleksanaa merged 1 commit intoNixOS:masterfrom
axelkar:cgit-robots-alias

Conversation

@axelkar
Copy link
Member

@axelkar axelkar commented Mar 16, 2025

This makes it easier to replace an asset by just setting the Nginx virtual host's locations."= robots.txt".alias. Previously you had to either replace the extraConfig with mkForce or clear it and use the alias option.

Does this need a release notes entry? Should they be set with mkDefault?

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Mar 16, 2025
@axelkar axelkar requested a review from pacien March 29, 2025 15:25
@axelkar axelkar requested a review from bendlas April 6, 2025 09:52
@axelkar axelkar requested a review from Stunkymonkey May 22, 2025 16:12
@axelkar axelkar requested a review from Aleksanaa June 10, 2025 13:01
@sternenseemann
Copy link
Member

Does this need a release notes entry? Should they be set with mkDefault?

I'd say no on both.

@nixpkgs-ci nixpkgs-ci bot added the 12.approvals: 1 This PR was reviewed and approved by one person. label Jul 28, 2025
@alyssais
Copy link
Member

I think mkDefault might be nice — not too out there to want to use custom CSS, for example.

This makes it easier to replace an asset by just setting the Nginx
virtual host's `locations."= robots.txt".alias`. Previously you had to
either replace the extraConfig with mkForce or clear it and use the
`alias` option.
@axelkar axelkar force-pushed the cgit-robots-alias branch from 79c39ed to d634694 Compare July 29, 2025 12:21
@alyssais
Copy link
Member

@ofborg test cgit

@Aleksanaa Aleksanaa merged commit 5f4f85b into NixOS:master Aug 1, 2025
27 of 31 checks passed
@axelkar axelkar deleted the cgit-robots-alias branch August 2, 2025 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 12.approvals: 1 This PR was reviewed and approved by one person.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants