<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.nixos.org/w/index.php?action=history&amp;feed=atom&amp;title=Django</id>
	<title>Django - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.nixos.org/w/index.php?action=history&amp;feed=atom&amp;title=Django"/>
	<link rel="alternate" type="text/html" href="https://wiki.nixos.org/w/index.php?title=Django&amp;action=history"/>
	<updated>2026-05-10T06:52:57Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.0</generator>
	<entry>
		<id>https://wiki.nixos.org/w/index.php?title=Django&amp;diff=26235&amp;oldid=prev</id>
		<title>Onny: Add section about development shell</title>
		<link rel="alternate" type="text/html" href="https://wiki.nixos.org/w/index.php?title=Django&amp;diff=26235&amp;oldid=prev"/>
		<updated>2025-08-31T11:06:26Z</updated>

		<summary type="html">&lt;p&gt;Add section about development shell&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 11:06, 31 August 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Django is a high-level Python web framework that encourages rapid development and clean, pragmatic design. It provides built-in components for handling common web-development tasks—such as ORM, templating, authentication, and administration—so developers can focus on writing reusable, maintainable applications.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Django is a high-level Python web framework that encourages rapid development and clean, pragmatic design. It provides built-in components for handling common web-development tasks—such as ORM, templating, authentication, and administration—so developers can focus on writing reusable, maintainable applications.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;== Development shell ==&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;This example &amp;lt;code&amp;gt;flake.nix&amp;lt;/code&amp;gt; can be used for Django web app development on NixOS&amp;lt;syntaxhighlight lang=&quot;nix&quot;&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;  inputs = {&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;    nixpkgs.url = &quot;nixpkgs/nixos-25.05&quot;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;    # Required for multi platform support&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;    flake-utils.url = &quot;github:numtide/flake-utils&quot;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;  };&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;  outputs = { self, nixpkgs, flake-utils }:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;    flake-utils.lib.eachDefaultSystem (system:&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;      let&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        pkgs = import nixpkgs { inherit system; };&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        start =&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;          pkgs.writeShellScriptBin &quot;start&quot; &#039;&#039;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            set -e&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            ${pkgs.python3}/bin/python manage.py makemigrations&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            ${pkgs.python3}/bin/python manage.py migrate&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            ${pkgs.python3}/bin/python manage.py runserver&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;          &#039;&#039;;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;      in&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;      {&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        devShell = pkgs.mkShell {&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;          packages = with pkgs; with python3Packages; [&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            python&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            django&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            requests&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;            beautifulsoup4&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;          ];&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        };&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        packages = { inherit start; };&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;        defaultPackage = start;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;      });&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;Adapt the dependencies in the devShell packages part according to your project needs. Run the web app with&amp;lt;syntaxhighlight lang=&quot;bash&quot;&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;nix develop&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;nix run&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Packaging ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Packaging ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key mediawiki:diff:1.41:old-25152:rev-26235:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Onny</name></author>
	</entry>
	<entry>
		<id>https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25152&amp;oldid=prev</id>
		<title>Onny at 07:18, 25 August 2025</title>
		<link rel="alternate" type="text/html" href="https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25152&amp;oldid=prev"/>
		<updated>2025-08-25T07:18:27Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 07:18, 25 August 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l291&quot;&gt;Line 291:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 291:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Python]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key mediawiki:diff:1.41:old-25151:rev-25152:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Onny</name></author>
	</entry>
	<entry>
		<id>https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25151&amp;oldid=prev</id>
		<title>Onny: Add description</title>
		<link rel="alternate" type="text/html" href="https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25151&amp;oldid=prev"/>
		<updated>2025-08-25T07:14:57Z</updated>

		<summary type="html">&lt;p&gt;Add description&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 07:14, 25 August 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Django is a high-level Python web framework that encourages rapid development and clean, pragmatic design. It provides built-in components for handling common web-development tasks—such as ORM, templating, authentication, and administration—so developers can focus on writing reusable, maintainable applications.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Packaging ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Packaging ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;First we create the package derivation for the Django web app, in this example for Froide-Govplan&amp;lt;syntaxhighlight lang=&quot;nix&quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;First we create the package derivation for the Django web app, in this example for &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Govplan|&lt;/ins&gt;Froide-Govplan&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;]]&lt;/ins&gt;&amp;lt;syntaxhighlight lang=&quot;nix&quot;&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   lib,&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   lib,&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key mediawiki:diff:1.41:old-25150:rev-25151:php=table --&gt;
&lt;/table&gt;</summary>
		<author><name>Onny</name></author>
	</entry>
	<entry>
		<id>https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25150&amp;oldid=prev</id>
		<title>Onny: Initial page</title>
		<link rel="alternate" type="text/html" href="https://wiki.nixos.org/w/index.php?title=Django&amp;diff=25150&amp;oldid=prev"/>
		<updated>2025-08-25T07:13:18Z</updated>

		<summary type="html">&lt;p&gt;Initial page&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Packaging ==&lt;br /&gt;
First we create the package derivation for the Django web app, in this example for Froide-Govplan&amp;lt;syntaxhighlight lang=&amp;quot;nix&amp;quot;&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
  lib,&lt;br /&gt;
  python3Packages,&lt;br /&gt;
  fetchFromGitHub,&lt;br /&gt;
  makeBinaryWrapper,&lt;br /&gt;
  froide-govplan,&lt;br /&gt;
  gettext,&lt;br /&gt;
}:&lt;br /&gt;
let&lt;br /&gt;
  # Use Django 5 instead of 4&lt;br /&gt;
  python = python3Packages.python.override {&lt;br /&gt;
    packageOverrides = self: super: {&lt;br /&gt;
      django = super.django_5;&lt;br /&gt;
    };&lt;br /&gt;
  };&lt;br /&gt;
in&lt;br /&gt;
python.pkgs.buildPythonApplication rec {&lt;br /&gt;
  pname = &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
  version = &amp;quot;0-unstable-2025-06-25&amp;quot;;&lt;br /&gt;
  pyproject = true;&lt;br /&gt;
&lt;br /&gt;
  src = fetchFromGitHub {&lt;br /&gt;
    owner = &amp;quot;okfde&amp;quot;;&lt;br /&gt;
    repo = &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
    rev = &amp;quot;9c325e70a84f26fea37b5a34f24d19fd82ea62ff&amp;quot;;&lt;br /&gt;
    hash = &amp;quot;sha256-OD4vvKt0FLuiAVGwpspWLB2ZuM1UJkZdv2YcbKKYk9A=&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
  build-system = [ python.pkgs.setuptools ];&lt;br /&gt;
&lt;br /&gt;
  nativeBuildInputs = [&lt;br /&gt;
    gettext&lt;br /&gt;
    makeBinaryWrapper&lt;br /&gt;
  ];&lt;br /&gt;
&lt;br /&gt;
  dependencies = with python.pkgs; [&lt;br /&gt;
    django&lt;br /&gt;
    [...]&lt;br /&gt;
  ];&lt;br /&gt;
&lt;br /&gt;
  preBuild = &amp;quot;${python.interpreter} -m django compilemessages&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
  postInstall = &amp;#039;&amp;#039;&lt;br /&gt;
    cp manage.py $out/${python.sitePackages}/froide_govplan/&lt;br /&gt;
    cp -r project $out/${python.sitePackages}/froide_govplan/&lt;br /&gt;
    cp -r froide_govplan/locale $out/${python.sitePackages}/froide_govplan/&lt;br /&gt;
    makeWrapper $out/${python.sitePackages}/froide_govplan/manage.py $out/bin/froide-govplan \&lt;br /&gt;
      --prefix PYTHONPATH : ${passthru.pythonPath}:$out/${python.sitePackages}&lt;br /&gt;
  &amp;#039;&amp;#039;;&lt;br /&gt;
&lt;br /&gt;
  # Make used Python version and Python path available to the module&lt;br /&gt;
  passthru = {&lt;br /&gt;
    inherit python;&lt;br /&gt;
    pythonPath = &amp;quot;${python.pkgs.makePythonPath dependencies}&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
  meta = {&lt;br /&gt;
    [...]&lt;br /&gt;
    mainProgram = &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;An example module derivation would look like this&amp;lt;syntaxhighlight lang=&amp;quot;nix&amp;quot;&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
  config,&lt;br /&gt;
  lib,&lt;br /&gt;
  pkgs,&lt;br /&gt;
  ...&lt;br /&gt;
}:&lt;br /&gt;
let&lt;br /&gt;
&lt;br /&gt;
  cfg = config.services.froide-govplan;&lt;br /&gt;
  pythonFmt = pkgs.formats.pythonVars { };&lt;br /&gt;
  settingsFile = pythonFmt.generate &amp;quot;extra_settings.py&amp;quot; cfg.settings;&lt;br /&gt;
&lt;br /&gt;
  # For this project we supply the extra settings as a Python file&lt;br /&gt;
  # to a specific path&lt;br /&gt;
  pkg = cfg.package.overridePythonAttrs (old: {&lt;br /&gt;
    postInstall = old.postInstall + &amp;#039;&amp;#039;&lt;br /&gt;
      ln -s ${settingsFile} $out/${pkg.python.sitePackages}/froide_govplan/project/extra_settings.py&lt;br /&gt;
    &amp;#039;&amp;#039;;&lt;br /&gt;
  });&lt;br /&gt;
&lt;br /&gt;
  # Make a wrapper for the main binary (manage.py) to run it&lt;br /&gt;
  # for the specific user&lt;br /&gt;
  froide-govplan = pkgs.writeShellApplication {&lt;br /&gt;
    name = &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
    runtimeInputs = [ pkgs.coreutils ];&lt;br /&gt;
    text = &amp;#039;&amp;#039;&lt;br /&gt;
      SUDO=&amp;quot;exec&amp;quot;&lt;br /&gt;
      if [[ &amp;quot;$USER&amp;quot; != govplan ]]; then&lt;br /&gt;
        SUDO=&amp;quot;exec /run/wrappers/bin/sudo -u govplan&amp;quot;&lt;br /&gt;
      fi&lt;br /&gt;
      $SUDO env ${lib.getExe pkg} &amp;quot;$@&amp;quot;&lt;br /&gt;
    &amp;#039;&amp;#039;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
  # Service hardening&lt;br /&gt;
  defaultServiceConfig = {&lt;br /&gt;
    # Secure the services&lt;br /&gt;
    ReadWritePaths = [ cfg.dataDir ];&lt;br /&gt;
    CacheDirectory = &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
    CapabilityBoundingSet = &amp;quot;&amp;quot;;&lt;br /&gt;
    # ProtectClock adds DeviceAllow=char-rtc r&lt;br /&gt;
    DeviceAllow = &amp;quot;&amp;quot;;&lt;br /&gt;
    LockPersonality = true;&lt;br /&gt;
    MemoryDenyWriteExecute = true;&lt;br /&gt;
    NoNewPrivileges = true;&lt;br /&gt;
    PrivateDevices = true;&lt;br /&gt;
    PrivateMounts = true;&lt;br /&gt;
    PrivateTmp = true;&lt;br /&gt;
    PrivateUsers = true;&lt;br /&gt;
    ProtectClock = true;&lt;br /&gt;
    ProtectHome = true;&lt;br /&gt;
    ProtectHostname = true;&lt;br /&gt;
    ProtectSystem = &amp;quot;strict&amp;quot;;&lt;br /&gt;
    ProtectControlGroups = true;&lt;br /&gt;
    ProtectKernelLogs = true;&lt;br /&gt;
    ProtectKernelModules = true;&lt;br /&gt;
    ProtectKernelTunables = true;&lt;br /&gt;
    ProtectProc = &amp;quot;invisible&amp;quot;;&lt;br /&gt;
    ProcSubset = &amp;quot;pid&amp;quot;;&lt;br /&gt;
    RestrictAddressFamilies = [&lt;br /&gt;
      &amp;quot;AF_UNIX&amp;quot;&lt;br /&gt;
      &amp;quot;AF_INET&amp;quot;&lt;br /&gt;
      &amp;quot;AF_INET6&amp;quot;&lt;br /&gt;
    ];&lt;br /&gt;
    RestrictNamespaces = true;&lt;br /&gt;
    RestrictRealtime = true;&lt;br /&gt;
    RestrictSUIDSGID = true;&lt;br /&gt;
    SystemCallArchitectures = &amp;quot;native&amp;quot;;&lt;br /&gt;
    SystemCallFilter = [&lt;br /&gt;
      &amp;quot;@system-service&amp;quot;&lt;br /&gt;
      &amp;quot;~@privileged @setuid @keyring&amp;quot;&lt;br /&gt;
    ];&lt;br /&gt;
    UMask = &amp;quot;0066&amp;quot;;&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
in&lt;br /&gt;
{&lt;br /&gt;
  options.services.froide-govplan = {&lt;br /&gt;
&lt;br /&gt;
    enable = lib.mkEnableOption &amp;quot;Gouvernment planer web app Govplan&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
    package = lib.mkPackageOption pkgs &amp;quot;froide-govplan&amp;quot; { };&lt;br /&gt;
&lt;br /&gt;
    hostName = lib.mkOption {&lt;br /&gt;
      type = lib.types.str;&lt;br /&gt;
      default = &amp;quot;localhost&amp;quot;;&lt;br /&gt;
      description = &amp;quot;FQDN for the froide-govplan instance.&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    dataDir = lib.mkOption {&lt;br /&gt;
      type = lib.types.str;&lt;br /&gt;
      default = &amp;quot;/var/lib/froide-govplan&amp;quot;;&lt;br /&gt;
      description = &amp;quot;Directory to store the Froide-Govplan server data.&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    secretKeyFile = lib.mkOption {&lt;br /&gt;
      type = lib.types.nullOr lib.types.path;&lt;br /&gt;
      default = null;&lt;br /&gt;
      description = &amp;#039;&amp;#039;&lt;br /&gt;
        Path to a file containing the secret key.&lt;br /&gt;
      &amp;#039;&amp;#039;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    settings = lib.mkOption {&lt;br /&gt;
      description = &amp;#039;&amp;#039;&lt;br /&gt;
        Configuration options to set in `extra_settings.py`.&lt;br /&gt;
      &amp;#039;&amp;#039;;&lt;br /&gt;
&lt;br /&gt;
      default = { };&lt;br /&gt;
&lt;br /&gt;
      type = lib.types.submodule {&lt;br /&gt;
        freeformType = pythonFmt.type;&lt;br /&gt;
&lt;br /&gt;
        options = {&lt;br /&gt;
          ALLOWED_HOSTS = lib.mkOption {&lt;br /&gt;
            type = with lib.types; listOf str;&lt;br /&gt;
            default = [ &amp;quot;*&amp;quot; ];&lt;br /&gt;
            description = &amp;#039;&amp;#039;&lt;br /&gt;
              A list of valid fully-qualified domain names (FQDNs) and/or IP&lt;br /&gt;
              addresses that can be used to reach the Froide-Govplan service.&lt;br /&gt;
            &amp;#039;&amp;#039;;&lt;br /&gt;
          };&lt;br /&gt;
        };&lt;br /&gt;
      };&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
  config = lib.mkIf cfg.enable {&lt;br /&gt;
&lt;br /&gt;
    services.froide-govplan = {&lt;br /&gt;
      settings = {&lt;br /&gt;
        STATIC_ROOT = &amp;quot;${cfg.dataDir}/static&amp;quot;;&lt;br /&gt;
        DEBUG = false;&lt;br /&gt;
        DATABASES.default = {&lt;br /&gt;
          ENGINE = &amp;quot;django.contrib.gis.db.backends.postgis&amp;quot;;&lt;br /&gt;
          NAME = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
          USER = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
          HOST = &amp;quot;/run/postgresql&amp;quot;;&lt;br /&gt;
        };&lt;br /&gt;
      };&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    services.postgresql = {&lt;br /&gt;
      enable = true;&lt;br /&gt;
      ensureDatabases = [ &amp;quot;govplan&amp;quot; ];&lt;br /&gt;
      ensureUsers = [&lt;br /&gt;
        {&lt;br /&gt;
          name = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
          ensureDBOwnership = true;&lt;br /&gt;
        }&lt;br /&gt;
      ];&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    services.nginx = {&lt;br /&gt;
      enable = lib.mkDefault true;&lt;br /&gt;
      virtualHosts.&amp;quot;${cfg.hostName}&amp;quot;.locations = {&lt;br /&gt;
        &amp;quot;/&amp;quot;.extraConfig = &amp;quot;proxy_pass http://unix:/run/froide-govplan/froide-govplan.socket;&amp;quot;;&lt;br /&gt;
        &amp;quot;/static/&amp;quot;.alias = &amp;quot;${cfg.dataDir}/static/&amp;quot;;&lt;br /&gt;
      };&lt;br /&gt;
      proxyTimeout = lib.mkDefault &amp;quot;120s&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    systemd = {&lt;br /&gt;
      services = {&lt;br /&gt;
&lt;br /&gt;
        froide-govplan = {&lt;br /&gt;
          description = &amp;quot;Gouvernment planer Govplan&amp;quot;;&lt;br /&gt;
          serviceConfig = defaultServiceConfig // {&lt;br /&gt;
            WorkingDirectory = cfg.dataDir;&lt;br /&gt;
            StateDirectory = lib.mkIf (cfg.dataDir == &amp;quot;/var/lib/froide-govplan&amp;quot;) &amp;quot;froide-govplan&amp;quot;;&lt;br /&gt;
            User = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
            Group = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
            TimeoutStartSec = &amp;quot;5m&amp;quot;;&lt;br /&gt;
          };&lt;br /&gt;
          after = [&lt;br /&gt;
            &amp;quot;postgresql.target&amp;quot;&lt;br /&gt;
            &amp;quot;network.target&amp;quot;&lt;br /&gt;
            &amp;quot;systemd-tmpfiles-setup.service&amp;quot;&lt;br /&gt;
          ];&lt;br /&gt;
          wantedBy = [ &amp;quot;multi-user.target&amp;quot; ];&lt;br /&gt;
          environment = {&lt;br /&gt;
            PYTHONPATH = &amp;quot;${pkg.pythonPath}:${pkg}/${pkg.python.sitePackages}&amp;quot;;&lt;br /&gt;
          }&lt;br /&gt;
          // lib.optionalAttrs (cfg.secretKeyFile != null) {&lt;br /&gt;
            SECRET_KEY_FILE = cfg.secretKeyFile;&lt;br /&gt;
          };&lt;br /&gt;
          preStart = &amp;#039;&amp;#039;&lt;br /&gt;
            # Auto-migrate on first run or if the package has changed&lt;br /&gt;
            versionFile=&amp;quot;${cfg.dataDir}/src-version&amp;quot;&lt;br /&gt;
            version=$(cat &amp;quot;$versionFile&amp;quot; 2&amp;gt;/dev/null || echo 0)&lt;br /&gt;
&lt;br /&gt;
            if [[ $version != ${pkg.version} ]]; then&lt;br /&gt;
              ${lib.getExe pkg} migrate --no-input&lt;br /&gt;
              ${lib.getExe pkg} collectstatic --no-input --clear&lt;br /&gt;
              echo ${pkg.version} &amp;gt; &amp;quot;$versionFile&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
          &amp;#039;&amp;#039;;&lt;br /&gt;
          script = &amp;#039;&amp;#039;&lt;br /&gt;
            ${pkg.python.pkgs.uvicorn}/bin/uvicorn --uds /run/froide-govplan/froide-govplan.socket \&lt;br /&gt;
              --app-dir ${pkg}/${pkg.python.sitePackages}/froide_govplan \&lt;br /&gt;
              project.asgi:application&lt;br /&gt;
          &amp;#039;&amp;#039;;&lt;br /&gt;
        };&lt;br /&gt;
      };&lt;br /&gt;
&lt;br /&gt;
    };&lt;br /&gt;
&lt;br /&gt;
    systemd.tmpfiles.rules = [ &amp;quot;d /run/froide-govplan - govplan govplan - -&amp;quot; ];&lt;br /&gt;
&lt;br /&gt;
    environment.systemPackages = [ froide-govplan ];&lt;br /&gt;
&lt;br /&gt;
    users.users.govplan = {&lt;br /&gt;
      home = &amp;quot;${cfg.dataDir}&amp;quot;;&lt;br /&gt;
      isSystemUser = true;&lt;br /&gt;
      group = &amp;quot;govplan&amp;quot;;&lt;br /&gt;
    };&lt;br /&gt;
    users.groups.govplan = { };&lt;br /&gt;
&lt;br /&gt;
  };&lt;br /&gt;
&lt;br /&gt;
  meta.maintainers = with lib.maintainers; [ onny ];&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Onny</name></author>
	</entry>
</feed>