This project contains everything to setup yourself a mirror of https://nixos.wiki/
Go to file
Jörg Thalheim 31e229cefc
Merge pull request #141 from NixOS/joerg-ci
fix nix-shell shebang with old nix versions
2024-09-17 11:12:28 +02:00
.github/workflows ci: add broken link checker action 2024-09-17 09:51:24 +02:00
checks fix nix-shell shebang with old nix versions 2024-09-17 11:10:46 +02:00
modules [create-pull-request] automated change 2024-09-13 03:07:15 +00:00
targets let disko set boot.loader.grub.devices 2024-09-17 09:20:17 +02:00
terraform apply treemft 2024-07-06 09:22:02 +00:00
.envrc add envrc 2024-02-09 12:02:11 +01:00
.envrc.private-template apply treemft 2024-07-06 09:22:02 +00:00
.gitignore gitignore .direnv 2024-09-17 09:51:24 +02:00
.mergify.yml ci(Mergify): configuration update 2024-09-13 11:23:38 +02:00
.sops.yaml apply treemft 2024-07-06 09:22:02 +00:00
flake.lock let disko set boot.loader.grub.devices 2024-09-17 09:20:17 +02:00
flake.nix let disko set boot.loader.grub.devices 2024-09-17 09:20:17 +02:00
formatter.nix drop black as formatter since we already use ruff 2024-09-17 10:57:42 +02:00
LICENSE.md apply treemft 2024-07-06 09:22:02 +00:00
oauth-permissions.png add oauth permissions picture 2024-04-02 10:42:00 +02:00
README.md apply treemft 2024-07-06 09:22:02 +00:00
renovate.json renovate: enable nix 2024-04-03 13:02:16 +02:00

nixos-wiki-infra

This project contains the setup of the official NixOS Wiki (wiki.nixos.org).

Additionally, this project's GitHub Issues host a space for coordination and discussion of wiki activities, in tandem with the Matrix channel #wiki:nixos.org.

Examples

Checkout ./targets/nixos-wiki.nixos.org for an example terraform deployment on hetzner cloud.

Downloading a dump of the wiki

This is useful if you want to run your own instance. Every day an XML dump is updated here:

https://wiki.nixos.org/wikidump.xml.zst

Restoring from a backup (wiki admins only)

$ systemctl stop phpfpm-mediawiki.service
$ borg-job-wiki list
$ borg-job-wiki mount u391032-sub1@u391032.your-storagebox.de:wiki.nixos.org/repo::wiki-wiki-2024-04-01T12:40:37 /tmp/restore
$ ls -la /tmp/restore/var/lib/mediawiki/backup/
$ sudo dropdb db
$ sudo -u postgres dropdb mediawiki
$ systemctl restart postgresql.service
$ sudo -u postgres pg_restore -d mediawiki < /tmp/restore/var/lib/mediawiki/backup/db
$ systemctl start phpfpm-mediawiki.service
$ ls -la /tmp/restore/var/lib/mediawiki-uploads/
$ umount /tmp/restore/

FAQ:

When logging in with "GitHub auth", the app shows "Act on your behalf" as a permission.

We created the Oauth app with read-only access and minimal permissions:

Unfortunately, GitHub misrepresents this information. Read more about this issue here: https://github.com/orgs/community/discussions/37117

Roles

Various roles are present on the wiki: